mirror of
https://github.com/opencv/opencv.git
synced 2024-11-24 19:20:28 +08:00
001a2c5195
videoio/FFmpeg: increased packet read attempt limit, allow configuring it resolves #9455 related #3225 * Use different counters for wrong packets recieved by demuxer and errors from decoder * Allow modifying these counters via environment variables `OPENCV_FFMPEG_READ_ATTEMPTS`/`OPENCV_FFMPEG_DECODE_ATTEMPTS` * Added logging when reading breaks at one of error limits Notes: * I've been able to reproduce original issue with a video file with 14 total streams (video + audio + subtitles), at some point in the video only packets from the last stream are being sent by the demuxer, thus exceeding our limit. For my specific video total number of packets from wrong stream was about 2700. I've chosen 4096 as default value. * Default limit of decoding attempts is quite low, because I'm not sure in which cases it can be exceeded (network stream?). I tried to read 8k video from the disk, but it did not cause break at decode point. |
||
---|---|---|
.. | ||
cmake | ||
doc | ||
include/opencv2 | ||
misc | ||
perf | ||
src | ||
test | ||
CMakeLists.txt |