1

我一直在开发一个 roku 频道,主要来自http://www.herofish.com/2012/01/how-to-create-you-own-roku-videoplayer-channel/上的教程,它已经很好地融合在一起. 现在我的问题是我正在尝试将频道连接到 Kit Digital Live 流(.m3u8 流),但我不知道如何将频道连接到该流而不是常规选择您的视频流。

有谁知道我在哪里可以找到有关如何执行此操作的说明或可以提供帮助的文档?(我已经浏览了开发者指南和论坛,但找不到任何线索)

4

2 回答 2

1

查看以下演示代码: http: //sourceforge.net/projects/rokusdkexamples/files/customvideoplayer.zip/download 向您展示了如何使用 HLS 和其他一些很酷的播放功能。

this.player.SetMessagePort(this.port)
this.player.SetLoop(true)
this.player.SetPositionNotificationPeriod(1)
this.player.SetDestinationRect(this.layout.left)
this.player.SetContentList([{
    Stream: { url: "http://ec2-184-72-239-149.compute-1.amazonaws.com:1935/demos/smil:bigbuckbunnyiphone.smil/playlist.m3u8" }
    StreamFormat: "hls"
    SwitchingStrategy: "full-adaptation"
}])
this.player.Play()
于 2013-03-21T09:31:36.770 回答
0

测试 HLS 流的最简单示例可能是 simplevideoplayer 示例,它位于 sourceforge 或您下载的 SDK 中。只需找到“Big Buck Bunny”部分,将引号中的 url 替换为您的 .m3u8 url,添加 srt="" 然后注释掉其他示例。

' Big Buck Bunny test stream from Wowza
urls = ["http://myserver.com/mystream.m3u8"]
streamformat = "hls"
title = "Big Buck Bunny"
srt=""
于 2013-03-21T22:23:07.793 回答