[FFmpeg-trac] #2828(avformat:new): HLS segment MPEGTS continuity counter is being incorrectly set to 0 on each segment
FFmpeg
trac at avcodec.org
Fri Sep 27 22:50:42 CEST 2013
#2828: HLS segment MPEGTS continuity counter is being incorrectly set to 0 on each
segment
-------------------------------------+------------------------------------
Reporter: dlevinson5 | Owner:
Type: defect | Status: new
Priority: normal | Component: avformat
Version: unspecified | Resolution:
Keywords: hls mpegts | Blocked By:
Blocking: | Reproduced by developer: 0
Analyzed by developer: 0 |
-------------------------------------+------------------------------------
Comment (by dicroce):
The problem is the bug does not result in a failure of the ffmpeg tool. It
splits the files, and the files are even playable. The problem is that for
clients to play smoothly from file to file certain counters in the ts
headers are supposed to increment linearly across the sequence of files.
In the current code, they are always 0. The failure to increment these
counters results in a small macroblock effect on iOS devices.
Further, I am not actually using the ffmpeg tool. I am writing software
and using libavcodec and libavformat directly. I am not actually that
familiar with how to tell the ffmpeg binary to segment files.... Tho, I
can tell you how how to do it from a C program.
The original posters attached "mpegtsenc.c" file does actually fix the
problem (if you enable his fix via AVOptions). The problem is that it uses
3 static globals to preserve the counters from call to call. I suspect
this code will fail horribly in a multithreaded environment.
--
Ticket URL: <https://ffmpeg.org/trac/ffmpeg/ticket/2828#comment:5>
FFmpeg <http://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list