Comments (1)
Uh... browser drop my anwer. In short: not an issue, just a WAD.
Some codecs has Delay in some amount of frames. Delay - major thing. In some cases Delay requires by performance optimization or by codec design itself (B-frames).
So, in some cases you should put some amount of packets to the codec before receive first decoded frame. Count of packets that sends to codec before first frame is a codec Delay. As a result, avcodec_receive_frame() can produce EAGAIN error for a some time.
Also, after input stream finished you must put some amount null packets to drain codecs and receive leftover frames. You should do it until EAGAIN (in my API: I do not put null packet to the codec, so it does not moves to flush state, basically it is an error) or AVERROR_EOF.
For more details see:
- https://www.ffmpeg.org/doxygen/3.1/group__lavc__encdec.html
- https://blogs.gentoo.org/lu_zero/2016/03/29/new-avcodec-api/
from avcpp.
Related Issues (20)
- Create aggregate headers roughly corresponding to FFmpeg's libraries
- `av::Rational`: define other relational operators
- Broken with FFmpeg 5.1 HOT 2
- CMake: INTERFACE_LIBRARY targets may only have whitelisted properties. HOT 2
- FFmpeg 5.1: fix channel_layout API HOT 1
- Is this project still alive? HOT 1
- Spelling Mistake in Content - "insormation" should be "information" in README HOT 1
- Broken Link in CONTRIBUTING.md - 404 Error
- `api2-decode-encode-video.cpp` example and correct stream tear-down sequence HOT 3
- Decoded frames have invalid PTS
- Copy a stream without transcoding HOT 3
- Take into account the filter size when calculating the delay HOT 1
- Memory leak (duplicate initialization) of all `CodecContext2` derived classes
- example api2-decode fail HOT 9
- compile ffmpeg with cuda surpport, so can avcpp use hwaccelerate? HOT 1
- problem: not with libpostproc?
- Why do you use new Codec() object in examples? HOT 2
- Debugging the library HOT 1
- Error compiling catch on Ubuntu 21 gcc 11.2.0 HOT 2
- Support for gpu-accelerated decoding? HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from avcpp.