Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(325)

Issue 2586803003: Enable creation of offscreen contexts which own their backing surface. (Closed)

Created:
4 years ago by klausw
Modified:
3 years, 11 months ago
CC:
blink-reviews, blink-reviews-api_chromium.org, chromium-reviews, darin-cc_chromium.org, dglazkov+blink, haraken, jam, kalyank, mlamouri+watch-content_chromium.org, ozone-reviews_chromium.org, piman+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Enable creation of offscreen contexts which own their backing surface. This is adapted from bajones's patch from issue 2461803002 at patchset 1 (http://crrev.com/2461803002#ps1) Uses the own_offscreen_surface flag with WebGL contexts when WebVR is enabled, to allow the surface to be swapped out with a compatible one if used for VR presentation. Includes support for canvas attributes such as "antialias", and adds a "low priority" GL context option so that postprocessing such as in WebVR frame submit at normal priority won't get blocked on the next frame being drawn. BUG=655722 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel Review-Url: https://codereview.chromium.org/2586803003 Cr-Commit-Position: refs/heads/master@{#442448} Committed: https://chromium.googlesource.com/chromium/src/+/46b9f6aaaf5851014c2474365734e71ffe9367a0

Patch Set 1 #

Patch Set 2 : Rebase to 356cd8379b3f2b06bd17716f88a2568791b4c60a #

Patch Set 3 : Rebase on top of crrev.com/2616723002 #

Patch Set 4 : Rebase #

Patch Set 5 : Rebase #

Patch Set 6 : Rebase, mark dependency #

Patch Set 7 : (ownsurface) Add EGL_IMG_context_priority extension presence check #

Patch Set 8 : Avoid segfault when there is no script context #

Total comments: 2

Patch Set 9 : (ownsurface) context priority workaround, update comments, VLOG->DVLOG #

Total comments: 2

Patch Set 10 : (ownsurface) Remove unused declaration #

Patch Set 11 : (ownsurface) add low_priority to buffer_traits #

Total comments: 4

Patch Set 12 : Rebase, update comment for alpha semantics #

Unified diffs Side-by-side diffs Delta from patch set Stats (+125 lines, -7 lines) Patch
M content/renderer/renderer_blink_platform_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +16 lines, -5 lines 0 comments Download
M gpu/command_buffer/common/gles2_cmd_utils.h View 1 2 chunks +2 lines, -1 line 0 comments Download
M gpu/command_buffer/common/gles2_cmd_utils.cc View 1 1 chunk +2 lines, -0 lines 0 comments Download
M gpu/command_buffer/service/service_utils.cc View 1 chunk +3 lines, -0 lines 0 comments Download
M gpu/ipc/common/gpu_command_buffer_traits_multi.h View 1 2 3 4 5 6 7 8 9 10 1 chunk +2 lines, -0 lines 0 comments Download
M gpu/ipc/service/gpu_command_buffer_stub.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +26 lines, -1 line 0 comments Download
M third_party/WebKit/Source/modules/webgl/WebGLContextAttributeHelpers.cpp View 1 chunk +4 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/modules/webgl/WebGLRenderingContextBase.cpp View 1 2 3 4 5 6 7 8 2 chunks +12 lines, -0 lines 0 comments Download
M third_party/WebKit/public/platform/Platform.h View 1 2 3 4 5 6 7 8 1 chunk +6 lines, -0 lines 0 comments Download
M ui/gl/gl_context.h View 1 chunk +1 line, -0 lines 0 comments Download
M ui/gl/gl_context_egl.cc View 1 2 3 4 5 6 7 8 2 chunks +12 lines, -0 lines 0 comments Download
M ui/gl/gl_surface_egl.h View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M ui/gl/gl_surface_egl.cc View 1 2 3 4 5 6 7 8 8 chunks +38 lines, -0 lines 0 comments Download

Messages

Total messages: 61 (29 generated)
klausw
This is an updated fork of bajones's original version, see also https://codereview.chromium.org/2461803002#msg20 for history. The ...
3 years, 11 months ago (2017-01-05 05:48:31 UTC) #8
klausw
dcheng@chromium.org: Please review changes in gpu_command_buffer_traits_multi.h and Platform.h . This is a refreshed fork of ...
3 years, 11 months ago (2017-01-05 05:51:59 UTC) #10
klausw
On 2017/01/05 05:51:59, klausw wrote: > mailto:dcheng@chromium.org: Please review changes in gpu_command_buffer_traits_multi.h > and Platform.h ...
3 years, 11 months ago (2017-01-05 07:04:57 UTC) #15
mthiesse
please update BUG to something narrower (and not closed :P)
3 years, 11 months ago (2017-01-05 20:04:02 UTC) #19
klausw
On 2017/01/05 20:04:02, mthiesse wrote: > please update BUG to something narrower (and not closed ...
3 years, 11 months ago (2017-01-05 20:34:20 UTC) #23
jbauman
https://codereview.chromium.org/2586803003/diff/140001/gpu/ipc/service/gpu_command_buffer_stub.cc File gpu/ipc/service/gpu_command_buffer_stub.cc (right): https://codereview.chromium.org/2586803003/diff/140001/gpu/ipc/service/gpu_command_buffer_stub.cc#newcode628 gpu/ipc/service/gpu_command_buffer_stub.cc:628: use_virtualized_gl_context_ = false; We probably need to actually fail ...
3 years, 11 months ago (2017-01-06 03:09:08 UTC) #26
klausw
https://codereview.chromium.org/2586803003/diff/140001/gpu/ipc/service/gpu_command_buffer_stub.cc File gpu/ipc/service/gpu_command_buffer_stub.cc (right): https://codereview.chromium.org/2586803003/diff/140001/gpu/ipc/service/gpu_command_buffer_stub.cc#newcode628 gpu/ipc/service/gpu_command_buffer_stub.cc:628: use_virtualized_gl_context_ = false; On 2017/01/06 03:09:08, jbauman wrote: > ...
3 years, 11 months ago (2017-01-06 06:13:00 UTC) #27
klausw
aelias@chromium.org: Please review changes in content/renderer/renderer_blink_platform_impl.cc dcheng@chromium.org: Please review changes in gpu/ipc/common/gpu_command_buffer_traits_multi.h
3 years, 11 months ago (2017-01-06 19:49:05 UTC) #29
klausw
On 2017/01/05 07:04:57, klausw wrote: > BTW, I think I help how to do the ...
3 years, 11 months ago (2017-01-06 19:51:18 UTC) #30
aelias_OOO_until_Jul13
content/renderer lgtm
3 years, 11 months ago (2017-01-06 20:21:51 UTC) #33
bajones
gpu/command_buffer and modules/webgl LGTM % one question. https://codereview.chromium.org/2586803003/diff/160001/gpu/ipc/common/gpu_command_buffer_traits_multi.h File gpu/ipc/common/gpu_command_buffer_traits_multi.h (right): https://codereview.chromium.org/2586803003/diff/160001/gpu/ipc/common/gpu_command_buffer_traits_multi.h#newcode148 gpu/ipc/common/gpu_command_buffer_traits_multi.h:148: IPC_STRUCT_TRAITS_MEMBER(own_offscreen_surface) Don't ...
3 years, 11 months ago (2017-01-06 23:14:04 UTC) #36
jbauman
On 2017/01/06 06:13:00, klausw wrote: > https://codereview.chromium.org/2586803003/diff/140001/gpu/ipc/service/gpu_command_buffer_stub.cc > File gpu/ipc/service/gpu_command_buffer_stub.cc (right): > > https://codereview.chromium.org/2586803003/diff/140001/gpu/ipc/service/gpu_command_buffer_stub.cc#newcode628 > ...
3 years, 11 months ago (2017-01-06 23:58:15 UTC) #37
klausw
https://codereview.chromium.org/2586803003/diff/160001/gpu/ipc/common/gpu_command_buffer_traits_multi.h File gpu/ipc/common/gpu_command_buffer_traits_multi.h (right): https://codereview.chromium.org/2586803003/diff/160001/gpu/ipc/common/gpu_command_buffer_traits_multi.h#newcode148 gpu/ipc/common/gpu_command_buffer_traits_multi.h:148: IPC_STRUCT_TRAITS_MEMBER(own_offscreen_surface) On 2017/01/06 23:14:04, bajones wrote: > Don't we ...
3 years, 11 months ago (2017-01-07 00:02:34 UTC) #38
klausw
On 2017/01/06 23:58:15, jbauman wrote: > On 2017/01/06 06:13:00, klausw wrote: > > > https://codereview.chromium.org/2586803003/diff/140001/gpu/ipc/service/gpu_command_buffer_stub.cc ...
3 years, 11 months ago (2017-01-07 00:13:59 UTC) #39
jbauman
On 2017/01/07 00:13:59, klausw wrote: > On 2017/01/06 23:58:15, jbauman wrote: > > On 2017/01/06 ...
3 years, 11 months ago (2017-01-07 00:29:01 UTC) #40
klausw
On 2017/01/07 00:29:01, jbauman wrote: > On 2017/01/07 00:13:59, klausw wrote: > > On 2017/01/06 ...
3 years, 11 months ago (2017-01-07 01:36:47 UTC) #41
jbauman
On 2017/01/07 01:36:47, klausw wrote: > On 2017/01/07 00:29:01, jbauman wrote: > > On 2017/01/07 ...
3 years, 11 months ago (2017-01-07 01:55:44 UTC) #42
klausw
Good point, I was assuming this is where it's coming from, but Brandon pointed out ...
3 years, 11 months ago (2017-01-07 02:09:46 UTC) #43
klausw
Good point, I was assuming this is where it's coming from, but Brandon pointed out ...
3 years, 11 months ago (2017-01-07 02:09:47 UTC) #44
klausw
Brandon was right, debugging shows that workarounds().use_virtualized_gl_contexts is true and mailbox_manager()->UsesSync() is false in the ...
3 years, 11 months ago (2017-01-07 02:19:04 UTC) #45
jbauman
On 2017/01/07 02:09:47, klausw wrote: > Good point, I was assuming this is where it's ...
3 years, 11 months ago (2017-01-07 02:48:19 UTC) #46
aelias_OOO_until_Jul13
Context virtualization is a big hammer we've applied to lots of drivers. It often makes ...
3 years, 11 months ago (2017-01-09 20:35:22 UTC) #47
klausw
On 2017/01/09 20:35:22, aelias wrote: > Context virtualization is a big hammer we've applied to ...
3 years, 11 months ago (2017-01-09 22:00:56 UTC) #48
aelias_OOO_until_Jul13
On 2017/01/09 at 22:00:56, klausw wrote: > My understanding is that even if some or ...
3 years, 11 months ago (2017-01-09 22:14:56 UTC) #49
bajones
On 2017/01/09 22:14:56, aelias wrote: > Yeah, it seems OK to have WebGL opt out ...
3 years, 11 months ago (2017-01-09 22:56:53 UTC) #50
aelias_OOO_until_Jul13
OK, sounds good to me then.
3 years, 11 months ago (2017-01-09 22:59:35 UTC) #51
jbauman
On 2017/01/09 22:56:53, bajones wrote: > On 2017/01/09 22:14:56, aelias wrote: > > Yeah, it ...
3 years, 11 months ago (2017-01-09 23:07:21 UTC) #52
dcheng
ipc lgtm https://codereview.chromium.org/2586803003/diff/200001/content/renderer/renderer_blink_platform_impl.cc File content/renderer/renderer_blink_platform_impl.cc (right): https://codereview.chromium.org/2586803003/diff/200001/content/renderer/renderer_blink_platform_impl.cc#newcode1033 content/renderer/renderer_blink_platform_impl.cc:1033: attributes.alpha_size = -1; Nit: I think this ...
3 years, 11 months ago (2017-01-09 23:14:57 UTC) #53
klausw
https://codereview.chromium.org/2586803003/diff/200001/content/renderer/renderer_blink_platform_impl.cc File content/renderer/renderer_blink_platform_impl.cc (right): https://codereview.chromium.org/2586803003/diff/200001/content/renderer/renderer_blink_platform_impl.cc#newcode1033 content/renderer/renderer_blink_platform_impl.cc:1033: attributes.alpha_size = -1; On 2017/01/09 23:14:57, dcheng wrote: > ...
3 years, 11 months ago (2017-01-09 23:33:24 UTC) #54
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2586803003/220001
3 years, 11 months ago (2017-01-09 23:37:57 UTC) #57
commit-bot: I haz the power
Committed patchset #12 (id:220001) as https://chromium.googlesource.com/chromium/src/+/46b9f6aaaf5851014c2474365734e71ffe9367a0
3 years, 11 months ago (2017-01-10 02:22:43 UTC) #60
mthiesse
3 years, 11 months ago (2017-01-11 19:48:46 UTC) #61
Message was sent while issue was closed.
A revert of this CL (patchset #12 id:220001) has been created in
https://codereview.chromium.org/2628963002/ by mthiesse@chromium.org.

The reason for reverting is: Causes out-of-order frames and tearing in WebVR..

Powered by Google App Engine
This is Rietveld 408576698