[FFmpeg-trac] #7166(undetermined:new): HLS format with fmp4 creates empty init.mp4 file when there is a single m4s output segment

FFmpeg trac at avcodec.org
Fri Apr 27 00:37:11 EEST 2018


#7166: HLS format with fmp4 creates empty init.mp4 file when there is a single m4s
output segment
-------------------------------------+-------------------------------------
             Reporter:  catbug       |                     Type:  defect
               Status:  new          |                 Priority:  normal
            Component:               |                  Version:
  undetermined                       |  unspecified
             Keywords:               |               Blocked By:
             Blocking:               |  Reproduced by developer:  0
Analyzed by developer:  0            |
-------------------------------------+-------------------------------------
 Summary of the bug:
 When using the hls format and fmp4 segment type, ffmpeg creates broken
 output segments if the input file has a short duration.

 Specifically whenever there is a single m4s output segment. This seems to
 happen anytime the input file duration is less than hls_time, or if the
 input file only has a single keyframe.

 With the repro command below, four files are produced.
 1. init.mp4
 2. segment0.m4s
 3. segment.m3u8 (contents appear correct)
 4. ffmpeg log (from -report flag)

 The init.mp4 file is empty with 0 bytes. I inspected the segment0.m4s with
 mp4dump, and it contains the data that should be in init.mp4, (styp, ftyp
 & moov).

 I expected init.mp4 to contain the styp, ftyp and moov atoms, and
 segment0.m4s should contain a moof and mdat.

 How to reproduce:
 {{{
 % ffmpeg -i h264_5s.mp4 -f hls -hls_segment_type fmp4 -hls_time 10 -report
 segment.m3u8
 ffmpeg version
 }}}

 Reproduced with latest build from today (2018-04-26), and 4.0 release.

 I'll upload the report log and sample mp4

--
Ticket URL: <https://trac.ffmpeg.org/ticket/7166>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list