You probably could use mencoder. If mplayer can play the file, you probably won't need to have input parameters configured for each file, because mencoder should be able to set them automatically. That means that you need to configure the video and audio output parameters which might be the same since you want to convert the video to flash. So after figuring out the arguments you need to do the conversion, you can write a script that calls mencoder with the same arguments. Then you could simply run your script and the input filename: toflash video.avi
Look in the info bash manual. There are parameter expansions that you can use so set a variable to a default if it isn't supplied as an argument:
Code:
bitrate=1000
jschiwal@hpmedia:~> echo ${bitrate:=$((500))}
1000
jschiwal@hpmedia:~> unset bitrate
jschiwal@hpmedia:~> echo ${bitrate:=$((500))}
500
Also look at the getopts command. It allows you to write wrapper scripts that take arguments with values. For example, suppose you want to convert the video to one of three sizes. You could have an option -s that takes either "small", "medium" or "large" as arguments, so then you could call the command like:
toflash -s small avideo.mpg
Using defaults and optional arguments you can call a wrapper script with only the filename or you could apply special arguments when you don't want to use your own defaults.