http live streaming – Why FFMPEG don't create master_pl while transcoding a RTMP stream? – Stack Overflow

Why this script don’t create any master playlist of HLS even after specify master_pl_name




mkdir -p /tmp/hls/$NAME

(ffmpeg -i $URI -vf "scale=w=-2:h=144" -c:a aac -b:a 48k -c:v h264 -b:v 200k -profile:v baseline -level 3.0 -s 256x144 -hls_time 10 -hls_list_size 0 -hls_segment_filename $OUTPUT_PATH/144p_%03d.ts $OUTPUT_PATH/144p.m3u8 \
  -vf "scale=w=-2:h=240" -c:a aac -b:a 64k -c:v h264 -b:v 400k -profile:v baseline -level 3.0 -s 426x240 -hls_time 10 -hls_list_size 0 -hls_segment_filename $OUTPUT_PATH/240p_%03d.ts $OUTPUT_PATH/240p.m3u8 \
  -vf "scale=w=-2:h=360" -c:a aac -b:a 128k -c:v h264 -b:v 800k -profile:v main -level 3.1 -s 640x360 -hls_time 10 -hls_list_size 0 -hls_segment_filename $OUTPUT_PATH/360p_%03d.ts $OUTPUT_PATH/360p.m3u8 \
  -vf "scale=w=-2:h=480" -c:a aac -b:a 128k -c:v h264 -b:v 1200k -profile:v main -level 3.1 -s 854x480 -hls_time 10 -hls_list_size 0 -hls_segment_filename $OUTPUT_PATH/480p_%03d.ts $OUTPUT_PATH/480p.m3u8 \
  -map 0:v:0 -map 0:a:0 -f hls \
  -var_stream_map "v:0,a:0 v:1,a:1 v:2,a:2 v:3,a:3" \
  -master_pl_name $OUTPUT_PATH/master.m3u8 )

Why it’s not happen and how can I fix it?

Read more here: Source link