[Bf-committers] [Bf-blender-cvs] SVN commit: /data/svn/bf-blender [44178] trunk/blender: Camera tracking: animation datablock for MovieClip
Sergey Sharybin
sergey.vfx at gmail.com
Fri Feb 17 11:38:16 CET 2012
Ah, indeed. Easy to miss some of changes when they need to be done in
several places. Will fix it soon.
On Fri, Feb 17, 2012 at 4:25 PM, Joshua Leung <aligorith at gmail.com> wrote:
> Looks like you're missing a few things:
> - an entry in expand_movieclips() or whatever that is called. This is
> done for all lib-linked stuff
> - BKE_animdata_main_cb(), and BKE_all_animdata_fix_paths_rename()
>
> On Fri, Feb 17, 2012 at 9:13 PM, Sergey Sharybin <sergey.vfx at gmail.com>
> wrote:
> > Revision: 44178
> >
> http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=44178
> > Author: nazgul
> > Date: 2012-02-17 08:13:45 +0000 (Fri, 17 Feb 2012)
> > Log Message:
> > -----------
> > Camera tracking: animation datablock for MovieClip
> >
> > Added AnimData block to MovieClip datablock which allows to animate
> different properties in clip.
> > Currently supports animation of stabilization influence only.
> >
> > --
> > svn merge -r44129:44130 ^/branches/soc-2011-tomato
> >
> > Revision Links:
> > --------------
> >
> http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=44129
> >
> > Modified Paths:
> > --------------
> > trunk/blender/source/blender/blenkernel/intern/anim_sys.c
> > trunk/blender/source/blender/blenkernel/intern/movieclip.c
> > trunk/blender/source/blender/blenloader/intern/readfile.c
> > trunk/blender/source/blender/blenloader/intern/writefile.c
> > trunk/blender/source/blender/makesdna/DNA_movieclip_types.h
> > trunk/blender/source/blender/makesrna/intern/rna_movieclip.c
> > trunk/blender/source/blender/makesrna/intern/rna_tracking.c
> >
> > Property Changed:
> > ----------------
> > trunk/blender/
> > trunk/blender/source/blender/editors/space_outliner/
> >
> >
> > Property changes on: trunk/blender
> > ___________________________________________________________________
> > Modified: svn:mergeinfo
> > -
> /branches/soc-2011-cucumber:37517,38166-38167,38177,38179-38180,38187,38242,38384,38387,38403-38404,38407,38968,38970,38973,39045,40845,42997-42998,43439
> >
> /branches/soc-2011-tomato:42376,42378-42379,42383,42385,42395,42397-42400,42407,42411,42418,42443-42444,42446,42467,42472,42486,42650-42652,42654-42655,42709-42710,42733-42734,42801,43872
> > +
> /branches/soc-2011-cucumber:37517,38166-38167,38177,38179-38180,38187,38242,38384,38387,38403-38404,38407,38968,38970,38973,39045,40845,42997-42998,43439
> >
> /branches/soc-2011-tomato:42376,42378-42379,42383,42385,42395,42397-42400,42407,42411,42418,42443-42444,42446,42467,42472,42486,42650-42652,42654-42655,42709-42710,42733-42734,42801,43872,44130
> >
> > Modified: trunk/blender/source/blender/blenkernel/intern/anim_sys.c
> > ===================================================================
> > --- trunk/blender/source/blender/blenkernel/intern/anim_sys.c
> 2012-02-17 07:32:18 UTC (rev 44177)
> > +++ trunk/blender/source/blender/blenkernel/intern/anim_sys.c
> 2012-02-17 08:13:45 UTC (rev 44178)
> > @@ -88,6 +88,7 @@
> > case ID_LA: case ID_CA: case ID_WO:
> > case ID_SPK:
> > case ID_SCE:
> > + case ID_MC:
> > {
> > return 1;
> > }
> > @@ -2335,6 +2336,9 @@
> > /* speakers */
> > EVAL_ANIM_IDS(main->speaker.first, ADT_RECALC_ANIM);
> >
> > + /* movie clips */
> > + EVAL_ANIM_IDS(main->movieclip.first, ADT_RECALC_ANIM);
> > +
> > /* objects */
> > /* ADT_RECALC_ANIM doesn't need to be supplied here,
> since object AnimData gets
> > * this tagged by Depsgraph on framechange. This
> optimisation means that objects
> >
> > Modified: trunk/blender/source/blender/blenkernel/intern/movieclip.c
> > ===================================================================
> > --- trunk/blender/source/blender/blenkernel/intern/movieclip.c
> 2012-02-17 07:32:18 UTC (rev 44177)
> > +++ trunk/blender/source/blender/blenkernel/intern/movieclip.c
> 2012-02-17 08:13:45 UTC (rev 44178)
> > @@ -64,6 +64,7 @@
> > #include "BLI_mempool.h"
> > #include "BLI_threads.h"
> >
> > +#include "BKE_animsys.h"
> > #include "BKE_constraint.h"
> > #include "BKE_library.h"
> > #include "BKE_global.h"
> > @@ -889,6 +890,8 @@
> > IMB_free_anim(clip->anim);
> > clip->anim= FALSE;
> > }
> > +
> > + BKE_free_animdata((ID *) clip);
> > }
> >
> > void BKE_movieclip_reload(MovieClip *clip)
> >
> > Modified: trunk/blender/source/blender/blenloader/intern/readfile.c
> > ===================================================================
> > --- trunk/blender/source/blender/blenloader/intern/readfile.c
> 2012-02-17 07:32:18 UTC (rev 44177)
> > +++ trunk/blender/source/blender/blenloader/intern/readfile.c
> 2012-02-17 08:13:45 UTC (rev 44178)
> > @@ -6050,6 +6050,8 @@
> > MovieTracking *tracking= &clip->tracking;
> > MovieTrackingObject *object;
> >
> > + clip->adt= newdataadr(fd, clip->adt);
> > +
> > if(fd->movieclipmap) clip->cache= newmclipadr(fd, clip->cache);
> > else clip->cache= NULL;
> >
> > @@ -6087,6 +6089,9 @@
> > clip= main->movieclip.first;
> > while(clip) {
> > if(clip->id.flag & LIB_NEEDLINK) {
> > + if (clip->adt)
> > + lib_link_animdata(fd, &clip->id,
> clip->adt);
> > +
> > clip->gpd= newlibadr_us(fd, clip->id.lib,
> clip->gpd);
> >
> > clip->id.flag -= LIB_NEEDLINK;
> >
> > Modified: trunk/blender/source/blender/blenloader/intern/writefile.c
> > ===================================================================
> > --- trunk/blender/source/blender/blenloader/intern/writefile.c
> 2012-02-17 07:32:18 UTC (rev 44177)
> > +++ trunk/blender/source/blender/blenloader/intern/writefile.c
> 2012-02-17 08:13:45 UTC (rev 44178)
> > @@ -2564,6 +2564,9 @@
> > MovieTrackingObject *object;
> > writestruct(wd, ID_MC, "MovieClip", 1, clip);
> >
> > + if(clip->adt)
> > + write_animdata(wd, clip->adt);
> > +
> > write_movieTracks(wd, &tracking->tracks);
> > write_movieReconstruction(wd,
> &tracking->reconstruction);
> >
> >
> >
> > Property changes on: trunk/blender/source/blender/editors/space_outliner
> > ___________________________________________________________________
> > Modified: svn:mergeinfo
> > -
> /branches/soc-2011-cucumber/source/blender/editors/space_outliner:38968,38970,38973,39045,40845
> >
> /branches/soc-2011-pepper/source/blender/editors/space_outliner:36831-38987
> >
> /branches/soc-2011-tomato/source/blender/editors/space_outliner:42376,42378-42379,42383,42385,42395,42397-42400,42407,42411,42418,42443-42444,42446,42467,42472,42486,42650-42652,42654-42655,42709-42710,42733-42734,42801,43872
> > +
> /branches/soc-2011-cucumber/source/blender/editors/space_outliner:38968,38970,38973,39045,40845
> >
> /branches/soc-2011-pepper/source/blender/editors/space_outliner:36831-38987
> >
> /branches/soc-2011-tomato/source/blender/editors/space_outliner:42376,42378-42379,42383,42385,42395,42397-42400,42407,42411,42418,42443-42444,42446,42467,42472,42486,42650-42652,42654-42655,42709-42710,42733-42734,42801,43872,44130
> >
> > Modified: trunk/blender/source/blender/makesdna/DNA_movieclip_types.h
> > ===================================================================
> > --- trunk/blender/source/blender/makesdna/DNA_movieclip_types.h
> 2012-02-17 07:32:18 UTC (rev 44177)
> > +++ trunk/blender/source/blender/makesdna/DNA_movieclip_types.h
> 2012-02-17 08:13:45 UTC (rev 44178)
> > @@ -39,6 +39,7 @@
> > #include "DNA_tracking_types.h"
> >
> > struct anim;
> > +struct AnimData;
> > struct bGPdata;
> > struct ImBuf;
> > struct MovieClipProxy;
> > @@ -61,6 +62,7 @@
> >
> > typedef struct MovieClip {
> > ID id;
> > + struct AnimData *adt; /* animation data (must be immediately
> after id for utilities to use it) */
> >
> > char name[1024]; /* file path, 1024 = FILE_MAX */
> >
> >
> > Modified: trunk/blender/source/blender/makesrna/intern/rna_movieclip.c
> > ===================================================================
> > --- trunk/blender/source/blender/makesrna/intern/rna_movieclip.c
> 2012-02-17 07:32:18 UTC (rev 44177)
> > +++ trunk/blender/source/blender/makesrna/intern/rna_movieclip.c
> 2012-02-17 08:13:45 UTC (rev 44178)
> > @@ -88,57 +88,70 @@
> > /* build proxy sized */
> > prop= RNA_def_property(srna, "build_25", PROP_BOOLEAN, PROP_NONE);
> > RNA_def_property_boolean_sdna(prop, NULL, "build_size_flag",
> MCLIP_PROXY_SIZE_25);
> > + RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
> > RNA_def_property_ui_text(prop, "25%", "Build proxy resolution 25%
> of the original footage dimension");
> >
> > prop= RNA_def_property(srna, "build_50", PROP_BOOLEAN, PROP_NONE);
> > RNA_def_property_boolean_sdna(prop, NULL, "build_size_flag",
> MCLIP_PROXY_SIZE_50);
> > + RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
> > RNA_def_property_ui_text(prop, "50%", "Build proxy resolution 50%
> of the original footage dimension");
> >
> > prop= RNA_def_property(srna, "build_75", PROP_BOOLEAN, PROP_NONE);
> > RNA_def_property_boolean_sdna(prop, NULL, "build_size_flag",
> MCLIP_PROXY_SIZE_75);
> > + RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
> > RNA_def_property_ui_text(prop, "75%", "Build proxy resolution 75%
> of the original footage dimension");
> >
> > prop= RNA_def_property(srna, "build_100", PROP_BOOLEAN,
> PROP_NONE);
> > RNA_def_property_boolean_sdna(prop, NULL, "build_size_flag",
> MCLIP_PROXY_SIZE_100);
> > + RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
> > RNA_def_property_ui_text(prop, "100%", "Build proxy resolution
> 100% of the original footage dimension");
> >
> > prop= RNA_def_property(srna, "build_undistorted_25",
> PROP_BOOLEAN, PROP_NONE);
> > RNA_def_property_boolean_sdna(prop, NULL, "build_size_flag",
> MCLIP_PROXY_UNDISTORTED_SIZE_25);
> > + RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
> > RNA_def_property_ui_text(prop, "25%", "Build proxy resolution 25%
> of the original undistorted footage dimension");
> >
> > prop= RNA_def_property(srna, "build_undistorted_50",
> PROP_BOOLEAN, PROP_NONE);
> > RNA_def_property_boolean_sdna(prop, NULL, "build_size_flag",
> MCLIP_PROXY_UNDISTORTED_SIZE_50);
> > + RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
> > RNA_def_property_ui_text(prop, "50%", "Build proxy resolution 50%
> of the original undistorted footage dimension");
> >
> > prop= RNA_def_property(srna, "build_undistorted_75",
> PROP_BOOLEAN, PROP_NONE);
> > RNA_def_property_boolean_sdna(prop, NULL, "build_size_flag",
> MCLIP_PROXY_UNDISTORTED_SIZE_75);
> > + RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
> > RNA_def_property_ui_text(prop, "75%", "Build proxy resolution 75%
> of the original undistorted footage dimension");
> >
> > prop= RNA_def_property(srna, "build_undistorted_100",
> PROP_BOOLEAN, PROP_NONE);
> > RNA_def_property_boolean_sdna(prop, NULL, "build_size_flag",
> MCLIP_PROXY_UNDISTORTED_SIZE_100);
> > + RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
> > RNA_def_property_ui_text(prop, "100%", "Build proxy resolution
> 100% of the original undistorted footage dimension");
> >
> > /* build timecodes */
> > prop= RNA_def_property(srna, "build_record_run", PROP_BOOLEAN,
> PROP_NONE);
> > RNA_def_property_boolean_sdna(prop, NULL, "build_tc_flag",
> IMB_TC_RECORD_RUN);
> > + RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
> > RNA_def_property_ui_text(prop, "Rec Run", "Build record run time
> code index");
> >
> > prop= RNA_def_property(srna, "build_free_run", PROP_BOOLEAN,
> PROP_NONE);
> > RNA_def_property_boolean_sdna(prop, NULL, "build_tc_flag",
> IMB_TC_FREE_RUN);
> > + RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
> > RNA_def_property_ui_text(prop, "Free Run", "Build free run time
> code index");
> >
> > prop= RNA_def_property(srna, "build_free_run_rec_date",
> PROP_BOOLEAN, PROP_NONE);
> > RNA_def_property_boolean_sdna(prop, NULL, "build_tc_flag",
> IMB_TC_INTERPOLATED_REC_DATE_FREE_RUN);
> > + RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
> > RNA_def_property_ui_text(prop, "Free Run (Rec Date)", "Build free
> run time code index using Record Date/Time");
> >
> > /* quality of proxied image */
> > prop= RNA_def_property(srna, "quality", PROP_INT, PROP_UNSIGNED);
> > RNA_def_property_int_sdna(prop, NULL, "quality");
> > + RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
> > RNA_def_property_ui_text(prop, "Quality", "JPEG quality of proxy
> images");
> > RNA_def_property_ui_range(prop, 1, 100, 1, 0);
> >
> > prop= RNA_def_property(srna, "timecode", PROP_ENUM, PROP_NONE);
> > RNA_def_property_enum_sdna(prop, NULL, "tc");
> > + RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
> > RNA_def_property_enum_items(prop, clip_tc_items);
> > RNA_def_property_ui_text(prop, "Timecode", "");
> > RNA_def_property_update(prop, NC_MOVIECLIP|ND_DISPLAY, NULL);
> > @@ -146,6 +159,7 @@
> > /* directory */
> > prop= RNA_def_property(srna, "directory", PROP_STRING,
> PROP_DIRPATH);
> > RNA_def_property_string_sdna(prop, NULL, "dir");
> > + RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
> > RNA_def_property_ui_text(prop, "Directory", "Location to store
> the proxy files");
> >
> > @@ Diff output truncated at 10240 characters. @@
> > _______________________________________________
> > Bf-blender-cvs mailing list
> > Bf-blender-cvs at blender.org
> > http://lists.blender.org/mailman/listinfo/bf-blender-cvs
> _______________________________________________
> Bf-committers mailing list
> Bf-committers at blender.org
> http://lists.blender.org/mailman/listinfo/bf-committers
>
--
With best regards, Sergey Sharybin
More information about the Bf-committers
mailing list