X-Git-Url: http://research.m1stereo.tv/gitweb?a=blobdiff_plain;f=src%2Fframework%2Fmlt_field.c;fp=src%2Fframework%2Fmlt_field.c;h=3ba08419ae1d8bc5b00ab571b61f472008905c0d;hb=be092fb725a3ef83741bb72460e11aac95989e3c;hp=05a41e5503e64cde9c673e3cea0c8543ed905b56;hpb=870a1069dd7a1b33623f3284c089b9be2dfb4491;p=melted diff --git a/src/framework/mlt_field.c b/src/framework/mlt_field.c index 05a41e5..3ba0841 100644 --- a/src/framework/mlt_field.c +++ b/src/framework/mlt_field.c @@ -73,6 +73,31 @@ mlt_field mlt_field_init( ) return this; } +mlt_field mlt_field_new( mlt_multitrack multitrack, mlt_tractor tractor ) +{ + // Initialise the field + mlt_field this = calloc( sizeof( struct mlt_field_s ), 1 ); + + // Initialise it + if ( this != NULL ) + { + // Construct a multitrack + this->multitrack = multitrack; + + // Construct a tractor + this->tractor = tractor; + + // The first plant will be connected to the mulitrack + this->producer = mlt_multitrack_service( this->multitrack ); + + // Connect the tractor to the multitrack + mlt_tractor_connect( this->tractor, this->producer ); + } + + // Return this + return this; +} + /** Get the service associated to this field. */