// Service locks are for concurrency control
mlt_service_lock( MLT_FILTER_SERVICE( filter ) );
+ // Handle signal from app to re-init data
+ if ( mlt_properties_get_int( MLT_FILTER_PROPERTIES(filter) , "refresh" ) )
+ {
+ mlt_properties_set( MLT_FILTER_PROPERTIES(filter) , "refresh", NULL );
+ data->initialized = 0;
+ }
+
if ( !vectors) {
if ( !data->initialized )
{
// Load analysis results from property
data->initialized = 2;
- int interp = 2;
+ int interp = 2; // default to bilinear
float scale_zoom=1.0;
if ( *width != mlt_properties_get_int( MLT_FRAME_PROPERTIES( frame ), "meta.media.width" ) )
scale_zoom = (float) *width / (float) mlt_properties_get_int( MLT_FRAME_PROPERTIES( frame ), "meta.media.width" );
interp = 0;
else if ( strcmp( interps, "tiles" ) == 0 || strcmp( interps, "fast_bilinear" ) == 0 )
interp = 1;
- else if ( strcmp( interps, "bilinear" ) == 0 )
- interp = 2;
- else if ( strcmp( interps, "bicubic" ) == 0 )
- interp = 3;
- else if ( strcmp( interps, "bicublin" ) == 0 )
- interp = 4;
data->trans->interpoltype = interp;
data->trans->smoothing = mlt_properties_get_int( MLT_FILTER_PROPERTIES(filter), "smoothing" );
data->trans->maxshift = mlt_properties_get_int( MLT_FILTER_PROPERTIES(filter), "maxshift" );
- data->trans->maxangle = mlt_properties_get_int( MLT_FILTER_PROPERTIES(filter), "maxangle" );
+ data->trans->maxangle = mlt_properties_get_double( MLT_FILTER_PROPERTIES(filter), "maxangle" );
data->trans->crop = mlt_properties_get_int( MLT_FILTER_PROPERTIES(filter), "crop" );
data->trans->invert = mlt_properties_get_int( MLT_FILTER_PROPERTIES(filter), "invert" );
data->trans->relative = mlt_properties_get_int( MLT_FILTER_PROPERTIES(filter), "relative" );