Opened 2 years ago

Closed 2 years ago

#8651 closed defect (fixed)

hls_fmp4_init_resend doesn't work when sending to a http output

Reported by: Mat Owned by: Steven Liu
Priority: normal Component: avformat
Version: git-master Keywords: hls
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no


Tested on master (0d81edcbba5149e46b11d447790f3a57a6eaa635) , the hls_fmp4_init_resend flag on the hls mux module seems to only work on file based output, this doesn't appear to work when a http based output it used.

We used the following configuration.


/opt/ffmpeg/bin/ffmpeg -i rtmp://${INPUT_STREAM_NAME} \

-map 0 \
-tune zerolatency -preset veryfast \
-sws_flags bilinear \
-framerate 30 -g 30 -keyint_min 30 -force_key_frames "expr:gte(t,n_forced*1)" -sc_threshold 0 -b_strategy 0 \
-c:v:0 libx264 -b:v:0 2000k -maxrate:v:0 2200k -bufsize:v:0 3000k -s:v:0 1280x720 -aspect:v:0 16\:9 -profile:v:0 main -crf:v:0 25 \
-c:a libfdk_aac \
-b:a:0 320k -maxrate:a:0 480k -bufsize:a:0 320k \
-hls_list_size $MANIFEST_LIST_SIZE \
-hls_segment_type fmp4 \
-hls_start_number_source epoch_us \
-var_stream_map "v:0,a:0,name:720p" \
-master_pl_name "master.m3u8" \
-master_pl_publish_rate 1 \
-hls_flags +program_date_time-temp_file \
-hls_fmp4_init_resend 1 \
-hls_fmp4_init_filename "init.mp4" \
-ignore_io_errors 1 \
-f hls -method PUT http://localhost:8001/publish/index-%v.m3u8`

This doesn't resend the init file as expected, however when swaping to a file based output it works as described.

Also the docs relating to hls_fmp4_init_resend ( appear to have been inserted in the middle of the the docs related to hls_fmp4_init_filename causing some confusion.

Change History (4)

comment:1 by Carl Eugen Hoyos, 2 years ago

Is network input required to reproduce the issue?
Please provide a simplified command line including complete, uncut console output to make this a valid ticket.

comment:2 by Steven Liu, 2 years ago

Cc: added
Owner: set to Steven Liu
Status: newopen

comment:3 by Mat, 2 years ago

I've just tried the attached patch, and can confirm that this is refreshing the init.mp4 file on http now.

Thank you!


comment:4 by Steven Liu, 2 years ago

Resolution: fixed
Status: openclosed
Note: See TracTickets for help on using tickets.