From: lilo_booter Date: Wed, 20 Jul 2005 06:32:10 +0000 (+0000) Subject: mlt_filter.c X-Git-Url: http://research.m1stereo.tv/gitweb?a=commitdiff_plain;h=df833610f58161f108b0c1f98c1e3705731e42ff;p=melted mlt_filter.c mlt_service.c + Filter disable property git-svn-id: https://mlt.svn.sourceforge.net/svnroot/mlt/trunk/mlt@772 d19143bc-622f-0410-bfdd-b5b2a6649095 --- diff --git a/src/framework/mlt_filter.c b/src/framework/mlt_filter.c index 6ca7afb..e97d6e0 100644 --- a/src/framework/mlt_filter.c +++ b/src/framework/mlt_filter.c @@ -147,7 +147,8 @@ mlt_position mlt_filter_get_out( mlt_filter this ) mlt_frame mlt_filter_process( mlt_filter this, mlt_frame frame ) { - if ( this->process == NULL ) + int disable = mlt_properties_get_int( MLT_FILTER_PROPERTIES( this ), "disable" ); + if ( disable || this->process == NULL ) return frame; else return this->process( this, frame ); diff --git a/src/framework/mlt_service.c b/src/framework/mlt_service.c index 1301fd2..75e598c 100644 --- a/src/framework/mlt_service.c +++ b/src/framework/mlt_service.c @@ -338,7 +338,8 @@ void mlt_service_apply_filters( mlt_service this, mlt_frame frame, int index ) { mlt_position in = mlt_filter_get_in( base->filters[ i ] ); mlt_position out = mlt_filter_get_out( base->filters[ i ] ); - if ( ( in == 0 && out == 0 ) || ( position >= in && ( position <= out || out == 0 ) ) ) + int disable = mlt_properties_get_int( MLT_FILTER_PROPERTIES( base->filters[ i ] ), "disable" ); + if ( !disable && ( in == 0 && out == 0 ) || ( position >= in && ( position <= out || out == 0 ) ) ) { mlt_properties_set_position( frame_properties, "in", in == 0 ? this_in : in ); mlt_properties_set_position( frame_properties, "out", out == 0 ? this_out : out );