[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [48051] trunk/blender/source/blender/ blenkernel/intern/movieclip.c: DO not reset clip' s focal length when changing path to footage

Sergey Sharybin sergey.vfx at gmail.com
Mon Jun 18 20:22:49 CEST 2012


Revision: 48051
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=48051
Author:   nazgul
Date:     2012-06-18 18:22:49 +0000 (Mon, 18 Jun 2012)
Log Message:
-----------
DO not reset clip's focal length when changing path to footage

Modified Paths:
--------------
    trunk/blender/source/blender/blenkernel/intern/movieclip.c

Modified: trunk/blender/source/blender/blenkernel/intern/movieclip.c
===================================================================
--- trunk/blender/source/blender/blenkernel/intern/movieclip.c	2012-06-18 18:12:18 UTC (rev 48050)
+++ trunk/blender/source/blender/blenkernel/intern/movieclip.c	2012-06-18 18:22:49 UTC (rev 48051)
@@ -463,7 +463,6 @@
 		clip->tracking.camera.principal[0] = ((float)width) / 2.0f;
 		clip->tracking.camera.principal[1] = ((float)height) / 2.0f;
 
-		clip->tracking.camera.focal = 24.0f * width / clip->tracking.camera.sensor_width;
 	}
 }
 
@@ -518,7 +517,12 @@
 		clip->source = MCLIP_SRC_SEQUENCE;
 
 	movieclip_load_get_szie(clip);
+	if (clip->lastsize[0]) {
+		int width = clip->lastsize[0];
 
+		clip->tracking.camera.focal = 24.0f * width / clip->tracking.camera.sensor_width;
+	}
+
 	movieclip_calc_length(clip);
 
 	return clip;




More information about the Bf-blender-cvs mailing list