gstreamer pipeline for this: gst-launch -v filesrc location=ch2.avi ! decodebin ! videoscale ! video/x-raw-yuv,width=720,height=480 ! videobox left=-720 top=-480 border-alpha=0 ! videomixer name=right ! videomixer name=three ! videomixer name=all ! alpha ! ffmpegcolorspace ! theoraenc ! oggmux ! filesink location=all.ogv filesrc location=ch1.avi ! decodebin ! videoscale ! video/x-raw-yuv,width=720,height=480 ! videobox border-alpha=0.0 left=-720 ! alpha ! ffmpegcolorspace ! all. filesrc location=ch4.avi ! decodebin ! videoscale ! video/x-raw-yuv,width=720,height=480 ! videobox border-alpha=0.0 top=-480 ! alpha ! ffmpegcolorspace ! three. filesrc location=ch3.avi ! decodebin ! videoscale ! video/x-raw-yuv,width=720,height=480 ! alpha ! ffmpegcolorspace ! right.