HTTP实时流MPEG TS段 [英] HTTP Live Streaming MPEG TS segment

查看:259
本文介绍了HTTP实时流MPEG TS段的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用FFMPEG和一个免费的分割器(Carson McDonald's)来生产我的ts片段,我以后保存到一个网络服务器,并通过玩.m3u8

I'm using FFMPEG and a free segmenter (Carson Mcdonald's) to produce my ts segments which i later save to a web server and play with Quicktime by playing the .m3u8

如果我有段1,2,3,4和另一个流1,2,3,4并且想要交错他们我应该怎么做。如果我做如下:1,2,其他流的3,4它工作正常。但是,如果我想做的如下:1,2,其他流的4,4它不工作。

If I have segments 1,2,3,4 and another stream with segments 1,2,3,4 and would like to interleave them what should I do. If i do as follows: 1,2, other stream's 3, 4 It works fine. However, If i want to do as follows: 1,2, other stream's 4, 4 it doesn't work.

换句话说,要添加的片段必须与我要替换的片段相同。这是为什么?它是否与PCR有关?我想能够在任何地方插入任何段落。我该怎么做?

In other words the segment to be added must have the same number as the one I'm replacing. Why is that? Does it have to do with PCR? I would like to be able to interleave any segment anywhere.. How can I do that?

谢谢,

M3U8文件是

#EXTM3U 
#EXT-X-TARGETDURATION:10 
#EXT-X-MEDIA-SEQUENCE:21 
#EXTINF:10, sample_ep_386k-00021.ts 
#EXTINF:10, media_2.ts 
#EXTINF:10, sample_ep_386k-00023.ts


推荐答案

这是许多在SO中面临的常见问题之一。

This is one of the common problem faced by many in SO.

请参阅我的答案: MPEG-TS段HTTP Live Streaming

要查看的内容:

o PCR(时间戳)不连续性

o匹配帧率

o文件格式

o数字和轨道类型

o编码参数

o编码序列

o PCR (timestamp) discontinuity
o Matching framerate
o file format
o number and type of tracks
o encoding parameters
o encoding sequence

这篇关于HTTP实时流MPEG TS段的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆