开发者

get connected to flash media server via RTMP android

开发者_运维技巧

I want to make connection to FMS (flash media server) in my android application.

Please suggest if there is any way to get connected to FMS via RTMP.


Have you had a look at the NetConnection class? It establishes an RTMP connection to a RTMP-capable server.

Establishing a connection is easy:

var nc:NetConnection = new NetConnection();

// Listen for the netstatus event
nc.addEventListener(NetStatusEvent.NET_STATUS, onStatus);

// Connect to your server
nc.connect("IP_GOES_HERE");

function onStatus(e:NetStatusEvent):void
{
    if (e.info.code == "NetConnection.Connect.Success")
    {
        // Connection has been established
    }
}

Looks like you don't want to do it in Flash but in Java. There is one library I know off that implements RTMP on the client side which is Flazr.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜