|author||wm4 <wm4@nowhere>||2018-04-29 16:04:50 +0200|
|committer||Jan Ekström <firstname.lastname@example.org>||2018-05-03 01:08:44 +0300|
video: actually wait for last frame being rendered on EOF
The video timing code could just decide that EOF was reached before it was displayed. This is not really a problem for normal playback (if you use something like --keep-open it'd show the last frame anyway, otherwise it'd at best flash it on screen before destroying the window). But in encode mode, it really matters, and makes the difference between having one frame more or less in the output file. Fix this by waiting for the VO before starting the real EOF. vo_is_ready_for_frame() is normally used to determine when the VO frame queue has enough space to send a new frame. Since the VO frame queue is currently at most 1 frame, it being signaled means the remaining frame was consumed and thus sent to the VO driver. If it returns false, it will wake up the playloop as soon as the state changes. I also considered using vo_still_displaying(), but it's not reliable, because it checks the realtime of the frame end display time.
Diffstat (limited to 'sub')
0 files changed, 0 insertions, 0 deletions