DescriptionDon't dismiss picture buffers on rez change until they are available
This CL fixes a race where the code would call DismissPictureBuffer()
on all output_picture_buffers_ once it detected a resolution change.
However some of those picture buffers had yet to be displayed by the
client. The client code, when asked to dismiss a picture buffer, only
tries to detect if it is currently displaying that frame, and if not
goes ahead and deletes the texture. This patch defers the dismissing
of the picture buffers until the client calls RecyclePictureBuffer
back with that stale buffer ID, meaning that the texture has been
displayed and can be safely deleted.
TEST: navigate to
http://sr-repro.s3.amazonaws.com/gpudecode/repro-gpu-mbr.html, before
CL there may be series of black frames when playing the video and it
switches from 720p to 1080p. After the CL the black frames are gone.
BUG=404817
Committed: https://crrev.com/9c311d81c7adb0391d596163c5159a0fb41f0cfd
Cr-Commit-Position: refs/heads/master@{#293616}
Patch Set 1 #Patch Set 2 : comment fix #
Total comments: 2
Patch Set 3 : move disposal to task #
Total comments: 2
Patch Set 4 : clear vector on invalidate #
Messages
Total messages: 16 (5 generated)
|