]> git.sesse.net Git - mlt/commitdiff
+ SMP fix - geometry modifications need explicit locking
authorlilo_booter <lilo_booter@d19143bc-622f-0410-bfdd-b5b2a6649095>
Wed, 24 Aug 2005 06:22:37 +0000 (06:22 +0000)
committerlilo_booter <lilo_booter@d19143bc-622f-0410-bfdd-b5b2a6649095>
Wed, 24 Aug 2005 06:22:37 +0000 (06:22 +0000)
git-svn-id: https://mlt.svn.sourceforge.net/svnroot/mlt/trunk/mlt@808 d19143bc-622f-0410-bfdd-b5b2a6649095

src/modules/core/transition_composite.c

index 4cbf324a4e0a4e8bec37947c01af1912068ad1f7..fa12b1556f3657b5ffebaf5ed1263d4a6f103d80 100644 (file)
@@ -1023,7 +1023,10 @@ static int transition_get_image( mlt_frame a_frame, uint8_t **image, mlt_image_f
                mlt_properties_set( b_props, "rescale.interp", rescale );
 
                // Do the calculation
+               // NB: Locks needed here since the properties are being modified
+               mlt_service_lock( MLT_TRANSITION_SERVICE( this ) );
                composite_calculate( this, &result, a_frame, position );
+               mlt_service_unlock( MLT_TRANSITION_SERVICE( this ) );
 
                // Since we are the consumer of the b_frame, we must pass along these
                // consumer properties from the a_frame
@@ -1129,7 +1132,10 @@ static int transition_get_image( mlt_frame a_frame, uint8_t **image, mlt_image_f
                                double field_position = position + field * delta;
                                
                                // Do the calculation if we need to
+                               // NB: Locks needed here since the properties are being modified
+                               mlt_service_lock( MLT_TRANSITION_SERVICE( this ) );
                                composite_calculate( this, &result, a_frame, field_position );
+                               mlt_service_unlock( MLT_TRANSITION_SERVICE( this ) );
 
                                if ( mlt_properties_get_int( properties, "titles" ) )
                                {