aw: Manually generate LocalSurfaceId
Currently viz is using the LocalSurfaceId in RenderWidgetHostViewAndroid as the surface to submit a root renderer frame to. This doesn't always work because renderer side change to LocalSurfaceId may not have been committed yet for that frame, which then can cause a mismatch in viz. Due to webview having a shortcut to resize the root renderer compositor viewport without commit [1], it's also not ok to use the LocalSurfaceId of the renderer compositor, since renderer can resize before the new Id is committed. This technically breaks surface sync, though it doesn't matter to webview in practice. However this does need to be solved for IsUsingVizFrameSubmissionForWebView. Instead, just generate LocalSurfaceId in HardwareRendererViz and check the frame size and scale to generate new Ids instead. [1] https://source.chromium.org/chromium/chromium/src/+/master:cc/trees/layer_tree_frame_sink_client.h;drc=7cfc49943853b0c361223b47ddeb01f7e9fa7ff3;l=73 Bug: 1145412 Change-Id: I0ac5934e214ca2667bf71fc610dceddc343d0e1d Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2551788 Commit-Queue: Bo <boliu@chromium.org> Reviewed-by:Vasiliy Telezhnikov <vasilyt@chromium.org> Cr-Commit-Position: refs/heads/master@{#829873}
Showing
Please register or sign in to comment