使用 NuGet 包 M3USharp 解析 M3U8
我需要读入 m3u8 主播放列表、各个块播放列表和各个二进制数据块。我只是移动数据,不进行任何播放。
我使用 NuGet 包 M3USharp 来解析主播放列表,它为我提供了流列表。从每个单独的流中,我可以获得每个chuck 播放列表。但我无法解析块列表来获取各个块。我找不到任何示例来说明如何使用此包执行此操作。
这是我的代码:
var content = getMasterFilePlaylist();
M3UFile m3u8File = M3UReader.Parse(content);
foreach(var stream in m3u8File.Streams)
{
Console.WriteLine(stream.Path);
// do stuff here...
}
但我找不到任何用于配对块列表的示例。 我还应该使用其他软件包吗?
I need to read in an m3u8 master playlist, the individual chunk playlists, and the individual binary data chunks. I am just moving the data around, not doing any playbacks.
I'm using a NuGet package M3USharp to parse the master playlist, which gives me a list of streams. From each individual stream, I can get each chuck playlist. but I can not parse the chunk lists to get the individual chunks. I can not find any examples showing how to do this with this package.
this is my code:
var content = getMasterFilePlaylist();
M3UFile m3u8File = M3UReader.Parse(content);
foreach(var stream in m3u8File.Streams)
{
Console.WriteLine(stream.Path);
// do stuff here...
}
But I can not find any examples for paring the chunk lists.
are there any other packages I should be using?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
尝试使用 https://www.nuget.org/packages/M3U8Parser/ 代替。
喜欢:
或:
Try to use https://www.nuget.org/packages/M3U8Parser/ instead.
Like :
OR :