Producer::Producer( Service &producer ) :
instance( NULL )
{
- service_type type = producer.type( );
+ mlt_service_type type = producer.type( );
if ( type == producer_type || type == playlist_type ||
type == tractor_type || type == multitrack_type )
{
return instance;
}
+mlt_producer Producer::get_parent( )
+{
+ return get_producer( ) != NULL && mlt_producer_cut_parent( get_producer( ) ) != NULL ? mlt_producer_cut_parent( get_producer( ) ) : get_producer( );
+}
+
mlt_service Producer::get_service( )
{
return mlt_producer_service( get_producer( ) );
return result;
}
+bool Producer::is_cut( )
+{
+ return mlt_producer_is_cut( get_producer( ) );
+}
+
+bool Producer::same_clip( Producer &that )
+{
+ return mlt_producer_cut_parent( get_producer( ) ) == mlt_producer_cut_parent( that.get_producer( ) );
+}
+
+bool Producer::runs_into( Producer &that )
+{
+ return same_clip( that ) && get_out( ) == ( that.get_in( ) - 1 );
+}