You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently rav1e assumes that every frame's duration is one unit of time_base. This is only correct for fixed framerate streams.
To Reproduce
Using rav1e to encode a stream coming from a normal webcam or some other source with a variable framerate causes rate control to not work correctly.
Expected behavior
It should be possible to provide timestamps for each frame (in time_base units) and this would be used by rate control to figure out how much time each frame represents.
Prior art can be found in aom (aom_codec_encode() PTS and duration parameters) or libvpx (vpx_codec_encode() PTS and duration parameters). Both seem to work correctly if the duration is just an estimate (you don't necessarily know it yet without waiting for the next frame) and use the PTS as main source of truth.
The text was updated successfully, but these errors were encountered:
Passing the information would be easy either adding fields to FrameParameters or adding yet another IntoFrame implementation.
But it requires the rate control to deal correctly with that change.
Describe the bug
Currently rav1e assumes that every frame's duration is one unit of time_base. This is only correct for fixed framerate streams.
To Reproduce
Using rav1e to encode a stream coming from a normal webcam or some other source with a variable framerate causes rate control to not work correctly.
Expected behavior
It should be possible to provide timestamps for each frame (in time_base units) and this would be used by rate control to figure out how much time each frame represents.
Prior art can be found in aom (
aom_codec_encode()
PTS and duration parameters) or libvpx (vpx_codec_encode()
PTS and duration parameters). Both seem to work correctly if the duration is just an estimate (you don't necessarily know it yet without waiting for the next frame) and use the PTS as main source of truth.The text was updated successfully, but these errors were encountered: