]> git.sesse.net Git - mlt/blobdiff - src/modules/core/filter_obscure.c
fix producer noise indicating its audio format
[mlt] / src / modules / core / filter_obscure.c
index 882b85e5d3a7b4cc7a797e4d781983ee2612dd30..97376bae9bb266911d9c2f2ab73b3e6ae6d1e7f8 100644 (file)
@@ -54,7 +54,7 @@ static inline float parse_value( char **ptr, int normalisation, char delim, floa
                {
                        if ( *end == '%' )
                                value = ( value / 100.0 ) * normalisation;
-                       while ( *end == delim || *end == '%' )
+                       while ( *end == delim || *end == '%' || ( delim == ',' && *end == '/' ) )
                                end ++;
                }
                *ptr = end;
@@ -241,7 +241,7 @@ static int filter_get_image( mlt_frame frame, uint8_t **image, mlt_image_format
                        struct geometry_s end;
 
                        // Retrieve the position
-                       float position = mlt_properties_get_double(frame_properties, "filter_position");
+                       float position = mlt_filter_get_progress( this, frame );
 
                        // Now parse the geometries
                        geometry_parse( &start, NULL, mlt_properties_get( properties, "start" ), normalised_width, normalised_height );
@@ -266,10 +266,6 @@ static mlt_frame filter_process( mlt_filter this, mlt_frame frame )
        // Push this on to the service stack
        mlt_frame_push_service( frame, this );
        
-       // Calculate the position for the filter effect
-       double position = mlt_filter_get_progress( this, frame );
-       mlt_properties_set_double( MLT_FRAME_PROPERTIES( frame ), "filter_position", position );
-
        // Push the get image call
        mlt_frame_push_get_image( frame, filter_get_image );
 
@@ -286,7 +282,7 @@ mlt_filter filter_obscure_init( mlt_profile profile, mlt_service_type type, cons
        {
                mlt_properties properties = MLT_FILTER_PROPERTIES( this );
                this->process = filter_process;
-               mlt_properties_set( properties, "start", arg != NULL ? arg : "0%,0%:100%x100%" );
+               mlt_properties_set( properties, "start", arg != NULL ? arg : "0%/0%:100%x100%" );
                mlt_properties_set( properties, "end", "" );
        }
        return this;