WebVfx  0.4.4-44-ga54b093
 All Classes Namespaces Functions Variables Enumerations Enumerator Pages
MLT Plugins

WebVfx implements producer, filter and transition plugin services for the MLT Framework. The MLT service ID is webvfx and the service argument or resource property is the path to the HTML or QML effect implementation.

MLT services are implemented as WebVfx effects - see Effects Authoring. The pathname to the HTML or QML effects implementation can be provided as the service contructor argument, or specified using the resource property. e.g.

melt -transition webvfx:/path/to/transition.html
melt -transition webvfx resource=/path/to/transition.html

Panzoom Producer Plugin

WebVfx also provides an image producer that implements a pan and zoom effect. This is similar to the MLT affine filter, but more efficient. The MLT service ID is webvfx.panzoom and the resource property is the source image to load. The geometry property holds the MLT geometry keyframe specifications.

Extra Images

Effects that use extra images (i.e. that register webvfx.ExtraImageType image names) accept an additional set of attributes of the form: producer.name.producer_attribute.

The example demo/examples/transition-demo.html transition uses an extra image named "backgroundImage":

webvfx.imageTypeMap = {
"sourceImage" : webvfx.SourceImageType,
"targetImage" : webvfx.TargetImageType,
"backgroundImage" : webvfx.ExtraImageType

The melt script example demo/mlt/mlt_transition_demo_html specifies the producer.backgroundImage.resource attribute for the transition:

export DISPLAY=${DISPLAY:-:0}
"${VFX_MELT:-melt}" -verbose "${VFX_SOURCE:-red.mlt}" out=149 \
-track -blank 59 \
"${VFX_TARGET:-blue.mlt}" out=149 \
-transition webvfx:../examples/transition-demo.html in=60 out=149 \
producer.backgroundImage.resource="${VFX_BACKGROUND:-green.mlt}" \
title="${VFX_TITLE:-Testing WebVfx Transition}" \
$(eval echo $(< "${VFX_CONSUMER:-consumer_sdl}"))


A set of bash scripts are provided to run melt with the sample effects. These are located in the demo/mlt directory and should be run in that directory. They are configurable through VFX_ prefixed environment variables. e.g. to run the mlt_transition_demo_html script, you can change the default source and target videos using VFX_SOURCE and VFX_TARGET.

VFX_SOURCE=/videos/source.mov VFX_TARGET=/videos/target.mov ./mlt_transition_demo_html

The demos default to using the SDL consumer, this can be changed to the avformat consumer by setting VFX_CONSUMER=consumer_av and setting VFX_OUTPUT to the path of the output QuickTime movie file to be created.

On MacOS, you will need to build qmelt and set VFX_MELT=qmelt to run the demos.

Each of the demos has been rendered as a video and can be previewed from the corresponding example.