2
I'm taking responsibility for maintaining a collection of recordings from online meetings, and I'm at a loss to determine which encodings I should use for them. The videos are coming from GoToMeeting, so they emerge in g2m4 format (which is quite large on disk) and so first I transcode with g2mtranscoder from Citrix. This gets me partway there, since other transcoders can work with my files once they're in normal wmv format.
However, from there--what is a proper choice of audio/video codecs? My main goal is to minimize storage, and I'm willing to accept some artifacts from lossy codecs.
My first attempts were using VBR h264 and 32kb/s MP3 in an MP4 container, and this worked well to minimize storage. However, I found that these transcodings could not be indexed when played in VLC: clicking most the way through a 2h video, the audio indexed to the correct time, but the video just froze.
This happened with two separate videos so I thought maybe it was my choice in codecs or something. Is there a better choice?
Yep! that's right. g2m4-wmv, then wmv-mp4. – bwerks – 2013-01-05T16:58:32.867
Probably does--I was using VLC to do the second transcode, but it doesn't appear to support keyframes in the UI and the command line documentation is illegible. I'm going to try to FFmpeg, I think. – bwerks – 2013-01-05T17:03:43.073
From my experience there's usually no problem seeking through H.264/MP4 files generated by FFmpeg. Try something like the following:
ffmpeg -i in.wmv -c:v libx264 -crf 25 -c:a libfaac -q:a 50 out.mp4
for a low quality approach. Decrease the CRF (it's like VBR) and increase the Q for better video/audio quality respectively. Default CRF is 23, and lower than 18 would be unnecessary. Default Q for FAAC is 100%, I chose 50% since 32kB/s MP3 seemed enough for you. – slhck – 2013-01-05T17:07:01.307The FFmpeg build from 2013-01-04 doesn't recognize libfaac as an encoder. This is a difficulty I've faced both with VLC and with FFmpeg--how can I enumerate supported codecs? – bwerks – 2013-01-05T17:23:59.723
Ah, sorry. the Zeranoe FFmpeg builds don't have
– slhck – 2013-01-05T17:30:10.683libfaac
(check withffmpeg -codecs
). You could use-c:a aac -strict experimental -b:a 128k
for the built-in FFmpeg AAC encoder, which unfortunately doesn't give as good results as FAAC.Does this mean you're running on osx/Linux? Do windows users have options other than Zeranoe FFmpeg builds? I got the impression that those were the only windows builds. – bwerks – 2013-01-05T17:34:32.290
I'm on OS X. The static builds for OS X and Linux linked to on the FFmpeg download page generally include FAAC. Zeranoe does not for license reasons, and I'm not aware of a build that'd include FAAC, sorry. – slhck – 2013-01-05T18:41:39.963
I attempted the FFmpeg command given above, but unfortunately the resulting mp4 was actually about 50% larger than the original wmv. I'll continue to play around; I suspect it has to do with configuring it to do VBR of some kind. – bwerks – 2013-01-05T19:34:08.310
It will do VBR. The CRF (constant quality) mode will do that automatically. Just set a higher CRF, e.g. 28, 31, etc. Higher means less quality and less file size. – slhck – 2013-01-05T19:49:19.513
Yeah, I've kept the video at the original CRF, and I'm trying again with the audio set to 32kb/s. I looked at ffmpeg -h full for the AAC-specific options but I didn't see anything about VBR; however, what I've read about AAC says it should be VBR capable--any idea if this is possible with FFmpeg? – bwerks – 2013-01-05T19:55:29.747
1FFmpeg's native AAC encoder (
-c:a aac
) does not perform VBR encoding for AAC. FAAC can, but that's going to be hard to accomplish with Windows without an FFmpeg version that bundles it. – slhck – 2013-01-05T19:56:38.830I've investigated an attempt to build FFmpeg in windows by myself, first by installing GNU Make and then by running FFmpeg's makefiles, however it seems that there are some shell scripts involved in the process that of course won't run in cmd or powershell. Might just be stuck with the Zeranoe build. – bwerks – 2013-01-05T23:01:22.677