X-Git-Url: http://research.m1stereo.tv/gitweb?a=blobdiff_plain;f=src%2Fmodules%2Fcore%2Ffilter_region.c;h=db69b661f193004dc1e2d48cbb12c746206ffce6;hb=dcec48366f9349da4bab349a2945bdd8cca18b81;hp=b47eb37c183fedb35b544f8e995eede4c1d0a3b6;hpb=9ab18ed63c37a9ef65e06697ae25f5c198d788bb;p=melted diff --git a/src/modules/core/filter_region.c b/src/modules/core/filter_region.c index b47eb37..db69b66 100644 --- a/src/modules/core/filter_region.c +++ b/src/modules/core/filter_region.c @@ -44,13 +44,16 @@ static mlt_frame filter_process( mlt_filter this, mlt_frame frame ) // Create the transition transition = mlt_factory_transition( "region", NULL ); - // Pass all properties down - mlt_properties_pass( mlt_transition_properties( transition ), properties, "" ); - // Register with the filter mlt_properties_set_data( properties, "_transition", transition, 0, ( mlt_destructor )mlt_transition_close, NULL ); + + // Pass a reference to this filter down + mlt_properties_set_data( mlt_transition_properties( transition ), "_region_filter", this, 0, NULL, NULL ); } + // Pass all properties down + mlt_properties_pass( mlt_transition_properties( transition ), properties, "" ); + // Process the frame return mlt_transition_process( transition, frame, NULL ); } @@ -74,6 +77,9 @@ mlt_filter filter_region_init( void *arg ) // Resource defines the shape of the region mlt_properties_set( properties, "resource", arg == NULL ? "rectangle" : arg ); + + // Ensure that attached filters are handled privately + mlt_properties_set_int( properties, "_filter_private", 1 ); } // Return the filter