Blender internal is using camera focal length when panorama rendering is used
authorSergey Sharybin <sergey.vfx@gmail.com>
Mon, 5 Nov 2012 08:19:58 +0000 (08:19 +0000)
committerSergey Sharybin <sergey.vfx@gmail.com>
Mon, 5 Nov 2012 08:19:58 +0000 (08:19 +0000)
This means it doesn't make sense hiding focal length settings for panorama
camera if blender internal renderer is used.

release/scripts/startup/bl_ui/properties_data_camera.py

index c8d3bf65ef60e89b2cf3b1c3dda0198d3d8a4804..5f6036c8945bedef40e65ddd7d36785be5ac19bf 100644 (file)
@@ -88,7 +88,8 @@ class DATA_PT_lens(CameraButtonsPanel, Panel):
             col.prop(cam, "ortho_scale")
 
         elif cam.type == 'PANO':
-            if context.scene.render.engine == 'CYCLES':
+            engine = context.scene.render.engine
+            if engine == 'CYCLES':
                 ccam = cam.cycles
                 col.prop(ccam, "panorama_type", text="Type")
                 if ccam.panorama_type == 'FISHEYE_EQUIDISTANT':
@@ -97,6 +98,13 @@ class DATA_PT_lens(CameraButtonsPanel, Panel):
                     row = layout.row()
                     row.prop(ccam, "fisheye_lens", text="Lens")
                     row.prop(ccam, "fisheye_fov")
+            elif engine == 'BLENDER_RENDER':
+                row = col.row()
+                if cam.lens_unit == 'MILLIMETERS':
+                    row.prop(cam, "lens")
+                elif cam.lens_unit == 'DEGREES':
+                    row.prop(cam, "angle")
+                row.prop(cam, "lens_unit", text="")
 
         split = layout.split()