mx:VideoDisplay and rtmpe streaming

I’ve spend some time trying to figure out how the get the Flex VideoDisplay object to play RTMPE streams. It turns out it’s just not possible using the default component.

The underlying NCManager class has the following hardcoded list of supported protocols, which doesn’t include RTMPE:

[code]
private static var RTMP_CONN:Array = [
{ protocol: "rtmp:/", port: "1935" },
{ protocol: "rtmp:/", port:"443" },
{ protocol: "rtmpt:/", port:"80" },
{ protocol: "rtmps:/", port:"443" }
];
[/code]

The connectRTMP function just iterates over it without any support to force a specific connection protocol:

[code]
private function connectRTMP():Boolean
{
// setup timeout
connectionTimer.reset();
connectionTimer.start();

tryNC = [];

tryNCTimer = new Timer(DEFAULT_NC_TIMEOUT);
tryNCTimer.addEventListener(TimerEvent.TIMER, nextConnect);

for (var i:uint = 0; i < RTMP_CONN.length; i++)
{
tryNC[i] = new NetConnection();
tryNC[i].objectEncoding = ObjectEncoding.AMF0;
tryNC[i].client = new NCManagerConnectClient(tryNC[i], this, i);
tryNC[i].addEventListener(NetStatusEvent.NET_STATUS, connectOnStatus);
}

nextConnect(null);
return false;
}
[/code]

I've filed this as a bug in the adobe issuetracker.

This entry was posted in flex. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>