Browse Source

Merge remote-tracking branch 'origin/master' into libArachne_rebased

Jelle Spijker 4 years ago
parent
commit
30293fb3b4
2 changed files with 5 additions and 3 deletions
  1. 2 2
      cura/CuraApplication.py
  2. 3 1
      plugins/PostProcessingPlugin/PostProcessingPlugin.py

+ 2 - 2
cura/CuraApplication.py

@@ -894,14 +894,14 @@ class CuraApplication(QtApplication):
         diagonal = self.getBuildVolume().getDiagonalSize()
         diagonal = self.getBuildVolume().getDiagonalSize()
         if diagonal < 1: #No printer added yet. Set a default camera distance for normal-sized printers.
         if diagonal < 1: #No printer added yet. Set a default camera distance for normal-sized printers.
             diagonal = 375
             diagonal = 375
-        camera.setPosition(Vector(-80, 250, 700) * diagonal / 375)
+        camera.setPosition(Vector(-80, 180, 700) * diagonal / 375)
         camera.lookAt(Vector(0, 0, 0))
         camera.lookAt(Vector(0, 0, 0))
         controller.getScene().setActiveCamera("3d")
         controller.getScene().setActiveCamera("3d")
 
 
         # Initialize camera tool
         # Initialize camera tool
         camera_tool = controller.getTool("CameraTool")
         camera_tool = controller.getTool("CameraTool")
         if camera_tool:
         if camera_tool:
-            camera_tool.setOrigin(Vector(0, 100, 0))
+            camera_tool.setOrigin(Vector(0, 30, 0))
             camera_tool.setZoomRange(0.1, 2000)
             camera_tool.setZoomRange(0.1, 2000)
 
 
         # Initialize camera animations
         # Initialize camera animations

+ 3 - 1
plugins/PostProcessingPlugin/PostProcessingPlugin.py

@@ -142,7 +142,9 @@ class PostProcessingPlugin(QObject, Extension):
         # The PostProcessingPlugin path is for built-in scripts.
         # The PostProcessingPlugin path is for built-in scripts.
         # The Resources path is where the user should store custom scripts.
         # The Resources path is where the user should store custom scripts.
         # The Preferences path is legacy, where the user may previously have stored scripts.
         # The Preferences path is legacy, where the user may previously have stored scripts.
-        for root in [PluginRegistry.getInstance().getPluginPath("PostProcessingPlugin"), Resources.getStoragePath(Resources.Resources), Resources.getStoragePath(Resources.Preferences)]:
+        resource_folders = [PluginRegistry.getInstance().getPluginPath("PostProcessingPlugin"), Resources.getStoragePath(Resources.Preferences)]
+        resource_folders.extend(Resources.getAllPathsForType(Resources.Resources))
+        for root in resource_folders:
             if root is None:
             if root is None:
                 continue
                 continue
             path = os.path.join(root, "scripts")
             path = os.path.join(root, "scripts")