Master playlist generate points to only one resolution among multiple
Summary of the bug:
How to reproduce:
ffmpeg -re -i video.mp4 -f hls -master_pl_publish_rate 5 -master_pl_name master.m3u8 ^
-vf scale=w=640:h=-2 -c:a aac -ar 48000 -c:v h264 -profile:v main -crf 20 -sc_threshold 0 -g 48 -keyint_min 48 -hls_time 4 -b:v 800k -maxrate 856k -bufsize 1200k -b:a 96k -hls_segment_filename D:\xampp\htdocs\streaming-demo\360p_%%03d.ts D:\xampp\htdocs\streaming-demo\360p.m3u8 ^
-vf scale=w=842:h=-2 -c:a aac -ar 48000 -c:v h264 -profile:v main -crf 20 -sc_threshold 0 -g 48 -keyint_min 48 -hls_time 4 -b:v 1400k -maxrate 1498k -bufsize 2100k -b:a 128k -hls_segment_filename D:\xampp\htdocs\streaming-demo\480p_%%03d.ts D:\xampp\htdocs\streaming-demo\480p.m3u8 ^
-vf scale=w=1280:h=-2 -c:a aac -ar 48000 -c:v h264 -profile:v main -crf 20 -sc_threshold 0 -g 48 -keyint_min 48 -hls_time 4 -b:v 2800k -maxrate 2996k -bufsize 4200k -b:a 128k -hls_segment_filename D:\xampp\htdocs\streaming-demo\720p_%%03d.ts D:\xampp\htdocs\streaming-demo\720p.m3u8 ^
-vf scale=w=1920:h=-2 -c:a aac -ar 48000 -c:v h264 -profile:v main -crf 20 -sc_threshold 0 -g 48 -keyint_min 48 -hls_time 4 -b:v 5000k -maxrate 5350k -bufsize 7500k -b:a 192k -hls_segment_filename D:\xampp\htdocs\streaming-demo\1080p_%%03d.ts D:\xampp\htdocs\streaming-demo\1080p.m3u8
It outputs all the segments just fine . And I can stream using individual playlists . But my master playlist links only to the 360p resolution playlist . What could I be doing wrong ?
Change History
(5)
Keywords: |
master playlist removed
|
Priority: |
important → minor
|
Resolution: |
→ invalid
|
Status: |
new → closed
|
Resolution: |
invalid
|
Status: |
closed → reopened
|
Priority: |
minor → important
|
Priority: |
important → minor
|
Resolution: |
→ invalid
|
Status: |
reopened → closed
|
Component: |
ffmpeg → undetermined
|
Priority: |
minor → normal
|
Your command invokes four HLS muxers. You need to map the video and audio streams four times in the same output file.
See the examples for the option var_stream_map in the HLS muxer section: https://ffmpeg.org/ffmpeg-formats.html#hls-2