Commit: 5358026368ac0dc9020728de7972d409760440dc
Author: Bastien Montagne
Date:   Tue Sep 30 15:07:44 2014 +0200
Branches: blender-v2.72-release
https://developer.blender.org/rB5358026368ac0dc9020728de7972d409760440dc

Fix T42026: Unit scale affects camera focal length.

Not a regression, yet maybe simple/safe enough for 2.72?

===================================================================

M       source/blender/blenkernel/intern/scene.c

===================================================================

diff --git a/source/blender/blenkernel/intern/scene.c 
b/source/blender/blenkernel/intern/scene.c
index b6fc44e..67b00a8 100644
--- a/source/blender/blenkernel/intern/scene.c
+++ b/source/blender/blenkernel/intern/scene.c
@@ -1994,14 +1994,13 @@ double BKE_scene_unit_scale(const UnitSettings *unit, 
const int unit_type, doubl
        switch (unit_type) {
                case B_UNIT_LENGTH:
                        return value * (double)unit->scale_length;
-               case B_UNIT_CAMERA:
-                       return value * (double)unit->scale_length;
                case B_UNIT_AREA:
                        return value * pow(unit->scale_length, 2);
                case B_UNIT_VOLUME:
                        return value * pow(unit->scale_length, 3);
                case B_UNIT_MASS:
                        return value * pow(unit->scale_length, 3);
+               case B_UNIT_CAMERA:  /* *Do not* use scene's unit scale for 
camera focal lens! See T42026. */
                default:
                        return value;
        }

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to