[FFmpeg-cvslog] avformat/dashenc: avformat/dashenc: Fix the EXT-X-TARGETDURATION as per the hls specification

Karthick J git at videolan.org
Fri Dec 22 01:46:18 EET 2017


ffmpeg | branch: master | Karthick J <kjeyapal at akamai.com> | Fri Dec 22 07:44:51 2017 +0800| [e3b2c8502b33c180e0f053ac2ef32ee782224c2e] | committer: Steven Liu

avformat/dashenc: avformat/dashenc: Fix the EXT-X-TARGETDURATION as per the hls specification

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=e3b2c8502b33c180e0f053ac2ef32ee782224c2e
---

 libavformat/dashenc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/dashenc.c b/libavformat/dashenc.c
index 5687530f2d..5368a2334c 100644
--- a/libavformat/dashenc.c
+++ b/libavformat/dashenc.c
@@ -358,7 +358,7 @@ static void output_segment_list(OutputStream *os, AVIOContext *out, DASHContext
             Segment *seg = os->segments[i];
             double duration = (double) seg->duration / timescale;
             if (target_duration <= duration)
-                target_duration = hls_get_int_from_double(duration);
+                target_duration = lrint(duration);
         }
 
         ff_hls_write_playlist_header(out_hls, 6, -1, target_duration,



More information about the ffmpeg-cvslog mailing list