[MEncoder-users] is this a good workflow?

Grozdan neutrino8 at gmail.com
Tue May 11 13:01:28 CEST 2010


On Tue, May 11, 2010 at 7:21 AM, Andrew Berg <bahamutzero8825 at gmail.com> wrote:
> On 5/10/2010 9:39 AM, Rick C. wrote:
>> Hi again,
>>
>> I'm looking for any input regarding this workflow:
>>
>> 1.  extract the audio from original file:  mencoder original_file.mpg -of rawaudio -oac mp3lame -ovc copy -o audio.mp3
>> 2.  will convert audio.mp3 to audio.m4a outside of mencoder to avoid using libfaac
>> 3.  joining everything back together:  mencoder original_file.mpg -audiofile audio.m4a -oac copy -fafmttag 0x706D -ovc lavc -lavcopts vglobal=1:vcodec=mpeg4 -of lavf -lavfopts format=ipod -o new_file.m4v
>>
>> This seems to work but is maybe a horrible way to do this and that's why I was looking for some input.  Any advice is much appreciated thanks,
>>
>> rc
> I prefer to use Nero's AAC encoder and something like the following will
> work for any command-line audio encoder:
>
> mencoder input.mpg -of avi -oac copy -ovc lavc -lavcopts
> vglobal=1:vcodec=mpeg4 -vf harddup -o temp.avi
> ffmpeg -i temp.avi -f wav - | neroaacenc -ignorelength -q 0.3 -if - -of
> temp.m4a
> mp4box -aviraw video temp.avi
> mp4box -add temp_video.h264:fps=29.97 -add temp.m4a -new output.mp4
>
> You may have to tweak the last command a bit to get it to handle MPEG-4
> video properly (I never use MPEG-4; I prefer AVC). The advantage to this
> approach over Grozdan's is that you don't need named pipes (which AFAIK
> are either difficult or impossible to make on Windows or other
> non-UNIX-based systems)

There is no advantage over my approach. It's just doing it slightly
different. And named pipes are supported by Windows, they are just
substantially different in semantics.


> and there is no need for mplayer (which always
> messes up my terminal on a server I use that doesn't have X, even when
> it doesn't try to play video).

Put a >/dev/null 2>&1 at the end of mplayer and it won't mess up
anything in your terminal. All you'll see is the Nero output.
Alternatively you can use -really-quiet in mplayer

> It also seems cleaner, but that's really
> more of an opinion. BTW, -oac copy works just fine as long as you're
> processing the video and you use the harddup filter (unless of course
> mencoder can't mux the stream; e.g. LPCM must be converted to another
> format).
> _______________________________________________
> MEncoder-users mailing list
> MEncoder-users at mplayerhq.hu
> https://lists.mplayerhq.hu/mailman/listinfo/mencoder-users
>


More information about the MEncoder-users mailing list