RTMP Output to YouTube Live

About encoding, codec settings, muxers and filter usage
biolizard89
New Cone
New Cone
Posts: 5
Joined: 24 May 2008 21:06

RTMP Output to YouTube Live

Postby biolizard89 » 13 Jul 2013 02:45

Using a recent VLC nightly on Windows x64 (vlc-2.2.0-git-20130712-1017-win64.exe), called via Cygwin bash, I can stream to Justin.tv via RTMP using the "flv" codec:

$ ./vlc 'C:\Users\JeremyAdmin\Videos\Big Buck Bunny\BigBuckBunny1080pTranscodeYouTube480p.ts' --sout-mux-caching 10000 --sout '#transcode{vcodec=flv,vb=350,width=320,height=240}:std{access=rtmp,mux=avformat{mux=flv},dst=[RTMP URL]}'
[00000000004a9800] main libvlc: Running vlc with the default interface. Use 'cvlc' to use vlc without interface.
Using network protocols without global network initialization. Please use avformat_network_init(), this will become mandatory later.
Using network protocols without global network initialization. Please use avformat_network_init(), this will become mandatory later.
[0000000000592ed0] qt4 interface error: First ImageList_Add failed
[0000000000592ed0] qt4 interface error: Second ImageList_Add failed
[0000000000592ed0] qt4 interface error: Third ImageList_Add failed
[0000000000592ed0] qt4 interface error: Fourth ImageList_Add failed
[00000000027fb770] ts demux error: MPEG-4 descriptor not found
[00000000027fd770] packetizer_mpeg4audio decoder: AAC channels: 2 samplerate: 44100
[flv @ 00000000020d6a60] removing common factors from framerate
[flv @ 00000000020d7280] removing common factors from framerate
[flv @ 00000000027e5a60] Codec for stream 0 does not use global headers but container format requires global headers
[flv @ 00000000027e5a60] Codec for stream 1 does not use global headers but container format requires global headers
[flv @ 00000000027e5a60] Failed to update header with correct duration.
[flv @ 00000000027e5a60] Failed to update header with correct filesize.

This appears to work properly, although the video is a bit jerky.

Changing the codec to "h264" also works in that nightly, although in an older nightly (vlc-2.1.0-pre1-20130702-0403-win64.exe) Justin.tv gives a black screen.

However, neither the flv codec nor the h264 codec seem to work for YouTube Live, which also uses RTMP output. When I attempt to do so (same command line as above, but with the YouTube Live RTMP URL), VLC segfaults:

[00000000005aa270] main libvlc: Running vlc with the default interface. Use 'cvlc' to use vlc without interface.
Using network protocols without global network initialization. Please use avformat_network_init(), this will become mandatory later.
Using network protocols without global network initialization. Please use avformat_network_init(), this will become mandatory later.
[0000000000516ed0] qt4 interface error: First ImageList_Add failed
[0000000000516ed0] qt4 interface error: Second ImageList_Add failed
[0000000000516ed0] qt4 interface error: Third ImageList_Add failed
[0000000000516ed0] qt4 interface error: Fourth ImageList_Add failed
Segmentation fault

Is there something about YouTube Live which VLC is unable to properly handle? I notice that the YouTube Live URL has query strings, which Justin.tv doesn't. What is the correct way to write a RTMP URL that has query strings in VLC? I'm currently just concatenating the "url" and "stream" values in the FMLE XML file, with a "/" separating them... this results in a "/" after the query strings, I have no idea if this is the problem or not.

Happy to see that RTMP output is at least working for Justin.tv though... this is a feature I've been waiting for for a while.

Any suggestions would be greatly appreciated.

Return to “VLC stream-output (sout)”

Who is online

Users browsing this forum: No registered users and 9 guests