I’m recording my screen on Windows using the command: ./ffmpeg -f gdigrab -framerate 30 -i desktop -c:v libx264 -crf 20 -preset ultrafast -max_muxing_queue_size 1024 -hls_time 5 -hls_list_size 10 -hls_flags delete_segments -hls_segment_filename "d:\1\file%03d.ts" "d:\1\playlist.m3u8"
Then I use the function avformat_open_input
to open this m3u8 file, but after calling this function, the m3u8 file stops updating. When I use the command ./ffmpeg -i D:1video.m3u8 -c copy -f mpegts "srt://xxxxx?streamid=#!::h=live/qyt,m=publish"
, the test results are the same. However, when I open the M3U8 file with a text editor, it updates normally. What’s the problem? Is avformat_open_input
exclusive?
How can I make this function read-only?