I think that is something that could be done with mencoder. TomJensen would probably know better than me.