This sounds like a silly place to ask this, but I think you guys are rather knowledgeable about these sorts of things.
I am working on a modification to a doom source port for direct video capture. My motivation was to get something with the same capabilities that the emulators used here have: non-realtime frame-exact capture, with sound perfectly synced to video. I didn't want to use anything platform specific (eg AVI output like visualboy advance), nor did I want to use anything that adds additional dependencies at build time (linking in something like libavcodec directly).
My solution is to use popen() to spawn encoding processes. The power user is then free to plug in any encoder he wants to that can read raw video or raw audio from stdin. I'd like however for the not-so-skilled user (especially under Windows) to be able to automatically dump videos that are of reasonable file size and quality while being uploadable to places like youtube directly. So I can bundle a free encoder with the download, set default command lines, and it all works presto gizmo. Here are the default invocations in the current beta version:
#audio pipe: stdin is 16bit signed stereo audio at samplerate %s
"ffmpeg -f s16le -ar %s -ac 2 -i pipe:0 -acodec libvorbis -f ogg -aq 5 output.ogg"
#video pipe: stdin is 24bit rgb raw video at size %w x %h, 35fps
"ffmpeg -f rawvideo -pix_fmt rgb24 -s %wx%h -r 35 -i pipe:0 -vcodec libx264 -f mp4 -fpre ./libx264-baseline.ffpreset -crf 22 output.mp4"
#mux command: run after recording is complete. %f was specified by user on commandline
"ffmpeg -i output.ogg -i output.mp4 -vcodec copy -acodec copy %f"
When %f is somefile.mkv, this has the problem that the output mkv is somehow damaged; it doesn't play right, but remux it with mkvmerge and it plays perfectly. There are no other output containers that ffmpeg will put both avc and vorbis into (I thought you could put avc into ogg, but apparently not). I could use avc+aac in mp4, but ffmpeg's aac encoder is marked experimental. I could bring in extra dependencies (like mkvmerge); but I'd like to keep the distribution size down; static link ffmpeg.exe is already 11MB.
So I guess my question is; can anyone recommend default encoding settings for a one-pass automated situation like this. If ffmpeg absolutely isn't up to the job, I am willing to consider replacements.
Remember that doom footage (especially with glitz like 32 bit color, hires, opengl, texture filtering, and hires texture replacements) is not going to compress well under ZMBV or anything similar.