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

Issue 1040153002: Removed arbitrary 4096 size limit on WebGL canvas backbuffers, Take 2 (Closed)

Created:
5 years, 8 months ago by bajones
Modified:
5 years, 8 months ago
CC:
blink-reviews, krit, dshwang, Dominik Röttsches, blink-reviews-html_chromium.org, pdr+graphicswatchlist_chromium.org, Justin Novosad, jbroman, danakj, dglazkov+blink, Rik, f(malita), Stephen Chennney, aandrey+blink_chromium.org, rwlbuis
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Target Ref:
refs/heads/master
Project:
blink
Visibility:
Public.

Description

Removed arbitrary 4096 size limit on WebGL canvas backbuffers, Take 2 Follow up to https://codereview.chromium.org/1002523007/, which had to be reverted due to hitting OOM errors on some hardware which advertized support for larger textures than it could actually create. This version checks for those errors and scales back the buffer allocation if needed. BUG=445542 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=192970

Patch Set 1 #

Total comments: 1

Patch Set 2 : Addressed kbr@'s comments #

Total comments: 1

Patch Set 3 : Added suggested ASSERT #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+72 lines, -14 lines) Patch
M Source/core/html/canvas/WebGLRenderingContextBase.cpp View 1 chunk +0 lines, -3 lines 0 comments Download
M Source/platform/graphics/gpu/DrawingBuffer.h View 2 chunks +2 lines, -2 lines 0 comments Download
M Source/platform/graphics/gpu/DrawingBuffer.cpp View 1 2 7 chunks +70 lines, -9 lines 1 comment Download

Messages

Total messages: 12 (4 generated)
bajones
PTAL
5 years, 8 months ago (2015-03-30 20:06:46 UTC) #2
Ken Russell (switch to Gerrit)
https://codereview.chromium.org/1040153002/diff/1/Source/platform/graphics/gpu/DrawingBuffer.cpp File Source/platform/graphics/gpu/DrawingBuffer.cpp (right): https://codereview.chromium.org/1040153002/diff/1/Source/platform/graphics/gpu/DrawingBuffer.cpp#newcode710 Source/platform/graphics/gpu/DrawingBuffer.cpp:710: return false; There's a preexisting bug with all of ...
5 years, 8 months ago (2015-03-31 02:13:34 UTC) #3
Ken Russell (switch to Gerrit)
P.S. Please also file bugs about the unrelated layout test failures on linux_chromium_rel_ng. They won't ...
5 years, 8 months ago (2015-03-31 02:14:28 UTC) #4
bajones
On 2015/03/31 02:13:34, Ken Russell wrote: > https://codereview.chromium.org/1040153002/diff/1/Source/platform/graphics/gpu/DrawingBuffer.cpp#newcode710 > Source/platform/graphics/gpu/DrawingBuffer.cpp:710: return false; > There's a ...
5 years, 8 months ago (2015-03-31 23:25:41 UTC) #5
Ken Russell (switch to Gerrit)
Thanks, this looks better. LGTM https://codereview.chromium.org/1040153002/diff/20001/Source/platform/graphics/gpu/DrawingBuffer.cpp File Source/platform/graphics/gpu/DrawingBuffer.cpp (right): https://codereview.chromium.org/1040153002/diff/20001/Source/platform/graphics/gpu/DrawingBuffer.cpp#newcode86 Source/platform/graphics/gpu/DrawingBuffer.cpp:86: while (error != GL_NO_ERROR) ...
5 years, 8 months ago (2015-03-31 23:52:09 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1040153002/40001
5 years, 8 months ago (2015-04-01 17:35:16 UTC) #9
commit-bot: I haz the power
Committed patchset #3 (id:40001) as https://src.chromium.org/viewvc/blink?view=rev&revision=192970
5 years, 8 months ago (2015-04-01 22:41:05 UTC) #10
piman
5 years, 8 months ago (2015-04-06 22:35:10 UTC) #12
Message was sent while issue was closed.
https://codereview.chromium.org/1040153002/diff/40001/Source/platform/graphic...
File Source/platform/graphics/gpu/DrawingBuffer.cpp (right):

https://codereview.chromium.org/1040153002/diff/40001/Source/platform/graphic...
Source/platform/graphics/gpu/DrawingBuffer.cpp:1018: ScopedErrorCache
errorCache(m_context.get());
drive-by: this sounds pretty unfortunate to do (many!) sync round trips to the
GPU process... This will hit on every webgl page load as well as on every canvas
resize. Each resizeFramebuffer will typically involve 4 to 6 round trips (at
least one for each ScopedErrorCache constructor, one for each peekError, a pair
of these for the resolved texture, the depth RB and possibly the multisampled
RB).

Could this be done by either:
1- limiting the error checks to "large" textures (if 4096x4096 were ok before,
they should still be)
2- identifying the GPUs which exhibit the bad behavior and add a workaround to
limit their max texture size to 4096
3- at the very very minimum, a single pair of round trips?

Powered by Google App Engine
This is Rietveld 408576698