使用Adobe Flash媒体服务器进行RTMP视频流传输

4

我正在开发一款针对安卓设备(Android TV Box)的应用程序,允许经过认证的用户通过使用Adobe Flash媒体服务器通过RTMP协议观看“数字频道”。我需要创建一个服务器端应用程序来进行流传输,还是只需托管视频?我已经搜索了很多但没有找到答案,感谢任何帮助。

我已经尝试过像这样使用Web视图:

webView = (WebView) findViewById(R.id.webview);

    webView.getSettings().setJavaScriptEnabled(true);
    webView.getSettings().setAllowFileAccess(true);
    webView.getSettings().setPluginsEnabled(true);
    webView.getSettings().setSupportZoom(true);
    webView.getSettings().setAppCacheEnabled(true);

    refreshButton = 
        (Button) findViewById(R.id.main_bt_refresh);
    refreshButton.setOnClickListener(this);

    refreshFileName();
}

@Override
public void onClick(View v) {
    refreshFileName();
}

private void refreshFileName() {
    EditText etRtmpUrl = 
        (EditText) findViewById(R.id.setup_et_host);
    EditText etFileName = 
        (EditText) findViewById(R.id.setup_et_file);
    rtmpUrl = etRtmpUrl.getText().toString();
    fileName = etFileName.getText().toString();
    if (fileName.endsWith(".flv")) {
        fileName = "flv:" + fileName;
    }

    bodyHtml = htmlCode;
    bodyHtml = bodyHtml.replaceAll("@FILESRC@", 
            "\"file=" + fileName
            + "&streamer=" + rtmpUrl + "\"");
    webView.loadDataWithBaseURL("http://127.0.0.1",
            htmlPre + bodyHtml
            + htmlPost, "text/html", "UTF-8", null);

但是没有回应...

1个回答

0

这些链接对我无用,我已经尝试过了。我需要使用Rtmp实现。不管怎样,谢谢。 - Shani Goriwal

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接