[MPlayer-users] RTMP streaming seems to be problematic...
Sander Plas
sander at seeas.nl
Sun Dec 11 00:39:19 CET 2011
On 12/09/2011 09:43 PM, Reimar Döffinger wrote:
> On Fri, Dec 09, 2011 at 05:46:28PM +0100, Sander Plas wrote:
>> On 12/09/2011 05:08 PM, Tom Evans wrote:
>>>> The following is a console log of a successful RTMP playback start. Between
>>>> the last "avformat_network_init(), this will become mandatory later." and
>>>> "libavformat file format detected" it takes nearly forever before something
>>>> happens.
>>
>>> You need to supply logs with verbose level:
>>
>> I do not want to demotivate anybody but as far as i know, RTMP
>> support has never worked reliably in mplayer (or ffmpeg) except for
>> a few test streams that were used by the guy who wrote the code.
>
> It seems your mistake is that you try to use FFmpeg's native RTMP.
> You should make sure to compile against librtmp, which should be
> working fine.
Thanks for the suggestions.
I managed to get Manuel's mp4 stream to work on the mplayer that is
shipped with Linux Mint 12 (SVN-r33713-4.6.1), but the first few times
the delay before it starts playing was literally minutes long. For some
reason it now works without any delay. I don't have any idea what causes
this difference - maybe something changed on the server side? AFAIK rtmp
works over TCP so there shouldn't be any UDP related firewall issues?
I compiled today's MPlayer SVN snapshot with librtmp support (librtmp
2.3-2ubuntu1 from Mint) and it plays the stream too, but less reliable
than Mint's MPlayer; most of the time it hangs after +/- 1 second.
ffmpeg://rtmpt// doesn't play at all and says "RTMP_Connect1, handshake
failed.".
I recompiled MPlayer without librtmp. The stream still hangs after +/- 1
second and ffmpeg://rtmpt:// just says "Failed to open
ffmpeg://rtmpt://85.239.122.162/vod/1316011807-6924a56f54048d0e28c28539368dfe57.mp4."
and exits.
I have quite a few rtmp urls from yourmuze users in old support tickets
and logs of the (mplayer based) script that checks new streams when
users try to add them on www.yourmuze.fm, but the problem is that it's
very hard to find out which of them are "correct" and which of them are
just wrong. I have no other way of checking them apart from the original
flash app from the publisher that has the URL hardcoded somewhere and
open source "hacks" like ffplay and mplayer.
What makes it even more difficult, is that in RTMP, there is a
disctinction between the 'server address' and the actual 'stream' path.
Some applications like mplayer and ffplay just concatenate those two
values, but most of the original flash based applications don't - so
it's generally quite hard to find out the correct full URL of a stream
from a HTML source or via a network sniffer.
Here's one radio stream URL from NPR that works fine in ffplay but
doesn't in Mint 12 MPlayer (hangs forever after "libavformat file format
detected") or today's SVN MPlayer with librtmp (exits after "Closing
connection: NetStream.Play.StreamNotFound"). It does work in today's SVN
MPlayer without librtmp but with an enormous delay before it starts
playing:
rtmp://92.123.66.37:1935/live?_fcs_vhost=cp42183.live.edgefcs.net&akmfv=1.7/Live1@1094
If anyone's interested in complete mplayer logs of any of the tests i've
done, just shout and i'll post them here.
More information about the MPlayer-users
mailing list