You are not logged in.

#1 2010-01-20 03:19:47

PirateJonno
Forum Fellow
From: New Zealand
Registered: 2009-04-13
Posts: 372

transcode audio, but not video, into MPEG transport stream

Hi, I live in New Zealand where our DVB broadcasts mostly use HE-AAC audio. This works fine in mythtv and recently mplayer as well, but I am not able to watch them on my PS3. I use mediatomb which was able to transcode my old analogue recordings into a format the PS3 supports, and was hoping to do the same for these videos. However, as some channels use 720p H.264 encoded video it would be impractical to transcode the video itself.

Fortunately, mencoder can retain the original video stream using -ovc copy, and I managed to get this and a recoded audio stream into an avi file. However, the PS3 stupidly assumes every avi file is encoded with DivX so I need to be able to use a different container, and I think mpeg is my only option. Anyway, when I try to do this, I get a useless 4kb file. Here's the command I used:
$ mencoder 3102_20100120135000.mpg -o ../tmp.mpg -oac lavc -ovc copy -lavcopts acodec=mp2:abitrate=128 -of mpeg
and the output.

Then I tried this:
$ mencoder 3102_20100120135000.mpg -o ../tmp.mpg -oac lavc -ovc copy -lavcopts acodec=mp2:abitrate=128 -of lavf -lavfopts format=mpegts
which gave me this.

this time the file is about the right size (17.3 MB) so it should have worked, but when I play it back with mplayer only the audio comes through. On the PS3 it won't work at all. I know H.264 is a valid stream for MPEG TS because the original file uses both. So basically I have no idea what the problem is, and can't spot anything in the output (the FAAD errors pop up when I make an avi file too so it can't be that).

If someone knows how to make this work that would be great. I would prefer to use mencoder because other programs that I've tried don't like writing to a FIFO, hence I can't stream the result over to the PS3. Thanks in advance for your help


"You can watch for your administrator to install the latest kernel with watch uname -r" - From the watch man page

Offline

Board footer

Powered by FluxBB