Chromium Code Reviews
DescriptionOzone: Keep the native pixmap alive till gl_image is destroyed
While testing with support for HW Overlays enabled and playing video,
I observed that browser crashes when you refresh the tab or try to close
the window (Debug builds). This was the sequence:
1)GLImage is scheduled to be displayed with GLSurfaceOzone.(HandleScheduleOverlayPlaneCHROMIUM)
2)If the page is refreshed, we start releasing the resources of
Video and VaapiDrmPicture calls destroy on the GLImage.
3)In the swapbuffer request, surfaceOzone tries to use the GLImage to
display the buffer on screen but the pixmap_is not valid anymore as
it has been destroyed in step 2 above. (We hit the DCHECK in
GLImageOzoneNativePixmap::ScheduleOverlayPlane)
Now, we release only EGL resources during Destroy call while
keeping around NativePixmap till ImageOzoneNativePixmap is
alive.
BUG=
Committed: https://crrev.com/862a9d9c5b475b05b6bb1741f782b8459967591e
Cr-Commit-Position: refs/heads/master@{#342280}
Patch Set 1 #Patch Set 2 : Missing changes #Patch Set 3 : Release Pixmap only in Destructor #Patch Set 4 : Remove un-needed changes #Messages
Total messages: 12 (2 generated)
|