PDA

View Full Version : Live streams (RTMP) captured from ustream.tv somewhat broken



melkov
12-22-2011, 11:34 AM
I tried to capture some live streams from ustream.tv using the latest version of Replay Media Catcher 4.3.2. The videos are getting partially unplayable with at least mplayer and vlc, mplayer usually complains about the audio:



[nellymoser @ 013215a0]Packet is too small
lavc_audio: error


Usually vlc can play a few first seconds of the video then crashes. Mplayer freeses but I'm still able to scroll forward through the file. Conversion often fails, when it does not the converted file has nearly the same problems.

Conversion failures are also due to the audio:


Converting - Output #0, mp4, to 'FILE-NAME here':
Converting - Stream #0.0: Video: mpeg4, yuv420p, 640x360 [PAR 1:1 DAR 16:9], q=2-31, 200 kb/s, 90k tbn, 20 tbc
Converting - Stream #0.1: Audio: libfaac, 0 channels, s16, 64 kb/s
Converting - Stream mapping:
Converting - Stream #0.0 -> #0.0
Converting - Stream #0.1 -> #0.1
Converting - Error while opening codec for output stream #0.1 - maybe incorrect parameters such as bit_rate, rate, width or height


The problem appears with all live streaming videos at Ustream I've ever tried.
You can fetch such videos here: http://www.ustream.tv/discovery/live/all?order=least-popular - any video with some picture and "Live" mark on its icon.

Some channels create slightly different-looking problems, such as this high quality stream: http://www.ustream.tv/channel/hclive13 - I get un-seek-able video, picture freezes, etc., while audio is OK.

I think that's probably a bug in the software. Or may be there are some special settings in RMC that can help to work-around the problem?

melkov
12-29-2011, 04:54 PM
Hi, I've discovered that the problem is additionally caused by a "very variable" video frame rate of the captured video.

That is, the following command "fixes" the file to become edible by mplayer and vlc but of course the video rate is now wrong and sound is out of sync:


mencoder.exe %1 -forceidx -o %1.mkv -ovc copy -oac mp3lame -lameopts abr:br=24 -fps 25 -of lavf

melkov
12-29-2011, 05:15 PM
OK, and now I've found "Fix flv" -> "File contents" -> "Fix time" thing.
The "time" column initially just contains zeroes.

I would like to ask Applian to make an option to fix time in such files (0 in frame times) automatically, or even better to let your capture module to use time of de-facto frame reception when there's such a trouble.