VideoHelp Forum




+ Reply to Thread
Results 1 to 3 of 3
  1. I am trying to batch convert a number of recordings from media portal. My intent is to use watch them on a stand alone cheap set top box.

    I've set up a script that goes through all my recordings, and transcodes them. However, because of the way they are recorded, I get the voice over stream (NAR) rather than the English (ENG) stream, as the NAR is the first audio stream.

    I could use the "-map" option, but depending on which channel the programme was originally recorded, the stream is in a different place; for example, Channel 5 has the right track in Stream 2, but BBC has it in Stream 4.... and it seems to vary between SD and HD recordings.

    Is there an easy way to tell FFMPEG which audio stream to use based on stream name (i.e. ENG) or codec (AC3)?
    ... or do I need to build into my script some logic of if BBC then use stream X, if Channel 4, use stream Y.

    Example of my FFMPEG command line:
    ffmpeg.exe" -i "recorded TV.ts" -vcodec mpeg2video -pix_fmt yuv420p -me_method epzs -threads 4 -r 25 -g 15 -s 624x352 -b 2500k -bt 300k -acodec mp2 -ac 2 -ab 192k -ar 44100 -async 1 -y -f vob "output.mpg"


    Thanks

    Richard.
    Quote Quote  
  2. afaik ffmpeg does not support to select streams based on their language. (mencoder should be able to do that using '-alang')
    Quote Quote  
  3. Brilliant - that advice seems to be working. I've amended my script to use mencoder, and I now get the right sound track.

    mencoder.exe recorded_tv.ts -ofps 25 -vf scale=624:352,harddup -of lavf -lavfopts format=mpg -oac lavc -alang eng -lavcopts acodec=mp2:abitrate=224 -ovc lavc -lavcopts vcodec=mpeg1video:vrc_buf_size=327:keyint=15:vrc_m axrate=1152:vbitrate=1152:vmax_b_frames=0 -o output.mpg
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!