Saturday, April 21, 2012

Creating video files to play on sansa players with rockbox installed.

Create two files, start each one with #!/bin/bash

Then the second line of each file is one of the following two lines:

e200:

mencoder $1 -of mpeg -oac lavc -lavcopts acodec=mp2:abitrate=64 -af resample=44100:0:0 -ovc lavc -lavcopts vcodec=mpeg2video:vbitrate=256 -vf scale,harddup -ofps 24 -zoom -xy 220 -o $1_220.mpg

c200:

mencoder $1 -of mpeg -oac lavc -lavcopts acodec=mp2:abitrate=128 -af resample=44100:0:0 -ovc lavc -lavcopts vcodec=mpeg2video:vbitrate=256 -vf scale,harddup -ofps 12 -zoom -xy 132 -o $1_tny.mpg

make each file executable with

chmod +x filename

for each file.

To run the script run scriptname.sh videofilename.avi

It will create a new smaller file next to the video file itself.

No comments:

Post a Comment