Post details: RTMP: Flash video streaming protocol
2009-01-19
RTMP: Flash video streaming protocol
Real Time Messaging Protocol (RTMP) is a proprietary protocol developed by Adobe Systems for streaming audio, video and data over the Internet, between a Flash player and a server.
This protocol is used by a number of well known sites such as BBC iPlayer, Hulu and videolectures.net.
My interest about this protocol is in being able to save streamed video for later viewing (while sitting in a cafe or traveling). Most of popular open source video players and tools currently do not support RTMP, be it for playing video or downloading the video stream.
Here are pointers to information that I could find:
RTMP protocol:
- RTMP open source and RTMP protocol [Open Source Flash]
- RTMP protocol [Gnash Project wiki]
- AMF object spec - describes a format of data objects passed inside RTMP connection
- RTMP protocol flavours - lists various flavours of the protocol: RTMP, RTMPT, RTMPS, MRTMP, …
- RTMP protocol, handling and downloading [Zen of Linux]
Downloading RTMP streams (let me know if they work ok for you):
- rtmpdump [C++, open source (GPL)] - a small, nice utility developed by Andrej Stepanchuk (based on the libRTMP library from XBMC media player)
- “get_iplayer gets High Quality Flash BBC iPlayer RTMP Downloading Capability” - uses rtmpdump for downloading RTMP from iPlayer.
- How to record RTMP flash video streams using Red5 [Java] - describes Java code to use with libraries from Red5 in order to record RTMP.
- How to record rtmp:// flash video - a list of tools for recording RTMP streams. (*)
(*) tools in that list are Windows only and closed source (= will not help in improving RTMP support in other tools).
Libraries:
- RTMPy [Python, MIT license] is a Twisted protocol for RTMP
- RTMP library [C++, GPLv2] from XBMC media player
- ToDo list for a C++ RTMP Server mentions “pull out a C++ RTMP Client library from the present sources for stand-alone use” as one of the tasks for volunteer contributors.
- libcurl - there is an open ticket about adding RTMP support
Re. RTMPy it was not clear to me how to use it for the task at hand.
Interesting applications:
- radio2daap [Erlang, open source (MIT license) - expose on-demand flash radio as an iTunes shared library
- XBMC [open source (GPL) ] - a fully functional media player application with RTMP support.
But how do you use it to record a RTMP stream? (e.g., this video from ISWC08)
With regard to standalone applications there are RTMP streaming servers (e.g., Red5) but we may have to wait a little further before protocol support appears in media players like mplayer and VLC, or in libraries such as libcurl.
What is your experience in working with / playing / recording of RTMP media streams?
Comments, Pingbacks:
I had done some of this research last year which ended in the Red5 / Java blog post you linked to. Thanks for this compilation, there are some links here I wasn't aware of.
Message to the world (yeah I'm looking at you too Adobe): please understand that the more restrictions you put on content - the more your genuine users will suffer. Case in point - take the video sharing site break.com: I never go to watch videos there because the video player aggressively prevents buffering and this causes all kinds of problems, playback not smooth etc. And forget about trying to "seek" to a point in the video even when you have *already* viewed it!!
I recently signed up for a paid account at crunchyroll.com to watch an anime series I am interested in. Yes I paid. The streaming Flash video experience is just terrible, check out the chaos on this discussion thread:
http://www.crunchyroll.com/forumtopic-438729/Naruto-Shippuden-92-is-up.html
Some folks need to get used to the fact that people will resort to screen-capturing your precious video for offline viewing if they have to. So please allow users to download videos for offline content! Watermark it if it makes you feel better - but please.
A couple of links I would like to add:
- FVNC - Open Source VNC client for Flash: http://www.osflash.org/fvnc
- Java RTMP stream recorder: http://rtmprip.jtvlan.org/
http://flazr.com