Right now, when I stack videos vertically, I output the Tractor and the
Profile: "tuple[tr:Tractor; p:Profile] "
proc stackVertically*( v1,v2:Producer ):tuple[tr:Tractor; p:Profile]

Later I apply the returned profile to the consumer:
# Call the function to stack vertically two videos.
# The tractor and new profile are returned
var (newProducer, profile) = stackVertically( v1, v2 )
# Consumer using the new calculated profile
var sdl = profile.newFactoryConsumer( "sdl2" )
sdl["terminate_on_pause"] = 1

# From tractor to SDL2
newProducer > sdl

What I would like to do is to apply the profile to the tractor. Like moving
the consumer within the stackVertically function and then using that
consumer as a producer.

I see that there is this plugin to use a consumer as a producer:
https://www.mltframework.org/plugins/ProducerConsumer/

but it is not very clear how I should use it and if it is appropriate for
this purpose.

On the other hand, I wonder if I should get the producer from the tractor
and set "width", "height", "aspect_ratio". I am trying this last option
without success.

Any suggestion is welcomed.
_______________________________________________
Mlt-devel mailing list
Mlt-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mlt-devel

Reply via email to