aboutsummaryrefslogtreecommitdiffstats
path: root/doc/examples/decode_video.c
diff options
context:
space:
mode:
authorVignesh Ravichandran <vignesh.ravichandran02@gmail.com>2020-12-01 15:40:40 +0530
committerliuqi05 <liuqi05@kuaishou.com>2020-12-08 20:57:24 +0800
commit45a673ebee2e603a87c0ecb259c0027c14321018 (patch)
tree0c5e1e41d45426928bad9d9df001781b86831244 /doc/examples/decode_video.c
parent18befac5da2c71aeb9922b6fd5551502f4c5a913 (diff)
downloadffmpeg-45a673ebee2e603a87c0ecb259c0027c14321018.tar.gz
avformat/hls: Fixes overwriting existing #EXT-X-PROGRAM-DATE-TIME value in HLS playlist
fix ticket: 8989 This is is due to the following behavior in the current code: 1. The initial_prog_date_time gets set to the current local time 2. The existing playlist (.m3u8) file gets parsed and the segments present are added to the variant stream 3. The new segment is created and added 4. The existing segments and the new segment are written to the playlist file. The initial_prog_date_time from point 1 is used for calculating "#EXT-X-PROGRAM-DATE-TIME" for the segments, which results in incorrect "#EXT-X-PROGRAM-DATE-TIME" values for existing segments The following approach fixes this bug: 1. Add a new variable "discont_program_date_time" of type double to HLSSegment struct 2. Store the "EXT-X-PROGRAM-DATE-TIME" value from the existing segments in this variable 3. When writing to playlist file if "discont_program_date_time" is set, then use that value for "EXT-X-PROGRAM-DATE-TIME" else use the value present in vs->initial_prog_date_time Signed-off-by: Vignesh Ravichandran <vignesh.ravichandran02@gmail.com> Signed-off-by: liuqi05 <liuqi05@kuaishou.com>
Diffstat (limited to 'doc/examples/decode_video.c')
0 files changed, 0 insertions, 0 deletions