[Libav-user] Decoder detects wrong framerate

Vasiliy Volkov volk.vasiliy at gmail.com
Sun Aug 19 20:22:59 EEST 2018


While working on application based on libav* we've encountered strange
decoder behavior: it detects wrong input framerate when we specify more
than 1 thread to it. So it looks like a bug, but maybe we do something
The problem with framerate detected by decoder: when we set 1 decoder
thread it detects framerate correctly, but when we set 2 or more it doubles
the framerate.

Here is a minimal code with h264 sample bitstream for reproduce such
behavior: https://yadi.sk/d/SBC1mv_L3aNJKK

If you compile it and run you will see output:
./decode_video 1 input.h264 -- 50/1 fps (correct)
./decode_video auto input.h264 -- 100/1 (doubled)

Can please help to figure out what wrong here? How to fix this behavior?
And yes I need multiple threads for decoding.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://ffmpeg.org/pipermail/libav-user/attachments/20180819/cf43f080/attachment.html>

More information about the Libav-user mailing list