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

Issue 2066993003: Begin instanced rendering for simple shapes (Closed)

Created:
4 years, 6 months ago by csmartdalton
Modified:
4 years, 5 months ago
CC:
reviews_skia.org
Base URL:
https://skia.googlesource.com/skia.git@master
Target Ref:
refs/heads/master
Project:
skia
Visibility:
Public.

Description

Begin instanced rendering for simple shapes Adds a module that performs instanced rendering and starts using it for a select subset of draws on Mac GL platforms. The instance processor can currently handle rects, ovals, round rects, and double round rects. It can generalize shapes as round rects in order to improve batching. The instance processor also employs new drawing algorithms, irrespective of instanced rendering, that improve GPU-side performance (e.g. sample mask, different triangle layouts, etc.). This change only scratches the surface of instanced rendering. The majority of draws still only have one instance. Future work may include: * Passing coord transforms through the texel buffer. * Sending FP uniforms through instanced vertex attribs. * Using instanced rendering for more draws (stencil writes, drawAtlas, etc.). * Adding more shapes to the instance processor’s repertoire. * Batching draws that have mismatched scissors (analyzing draw bounds, inserting clip planes, etc.). * Bindless textures. * Uber shaders. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2066993003 Committed: https://skia.googlesource.com/skia/+/42eafa4bc00354b132ad114d22ed6b95d8849891 Committed: https://skia.googlesource.com/skia/+/a7f29640f6ab4eb50962a9d9f12d01ac2ce8b471

Patch Set 1 #

Patch Set 2 : fixes #

Patch Set 3 : rebase #

Patch Set 4 : add missing file #

Patch Set 5 : get mixed samples and base instance paths working again #

Total comments: 2

Patch Set 6 : rebase and comments #

Patch Set 7 : #

Patch Set 8 : fix barriers #

Patch Set 9 : Implement instanced rendering for simple shapes #

Patch Set 10 : rebase #

Patch Set 11 : fix assertion #

Patch Set 12 : instances as linked list #

Patch Set 13 : Implement instanced rendering for simple shapes #

Patch Set 14 : Implement instanced rendering for simple shapes #

Patch Set 15 : fix coverage circles #

Patch Set 16 : test msaa4 and msaa8 on desktop as well #

Patch Set 17 : undo msaa4/msaa8 #

Patch Set 18 : Mac/NV whitelist #

Patch Set 19 : Improve subpixel rects #

Patch Set 20 : rebase #

Patch Set 21 : rebase #

Patch Set 22 : remove static initializer #

Patch Set 23 : Rix perf regressions #

Unified diffs Side-by-side diffs Delta from patch set Stats (+3603 lines, -30 lines) Patch
M bench/ShapesBench.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 2 chunks +3 lines, -3 lines 0 comments Download
M gyp/gpu.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 2 chunks +9 lines, -0 lines 0 comments Download
M include/gpu/GrDrawContext.h View 2 chunks +2 lines, -0 lines 0 comments Download
A include/private/GrInstancedPipelineInfo.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +49 lines, -0 lines 0 comments Download
M src/gpu/GrDrawContext.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 9 chunks +81 lines, -13 lines 0 comments Download
M src/gpu/GrDrawContextPriv.h View 1 2 3 4 5 6 7 8 9 10 2 chunks +5 lines, -0 lines 0 comments Download
M src/gpu/GrDrawTarget.h View 1 2 3 4 5 6 7 8 9 10 2 chunks +20 lines, -13 lines 0 comments Download
M src/gpu/GrDrawTarget.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 4 chunks +11 lines, -1 line 0 comments Download
M src/gpu/GrDrawingManager.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 3 chunks +14 lines, -0 lines 0 comments Download
M src/gpu/GrGpu.h View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +10 lines, -0 lines 0 comments Download
M src/gpu/gl/GrGLGpu.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 3 chunks +5 lines, -0 lines 0 comments Download
M src/gpu/gl/GrGLGpu.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 3 chunks +7 lines, -0 lines 0 comments Download
A src/gpu/instanced/GLInstancedRendering.h View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +60 lines, -0 lines 0 comments Download
A src/gpu/instanced/GLInstancedRendering.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1 chunk +301 lines, -0 lines 0 comments Download
A src/gpu/instanced/InstanceProcessor.h View 1 chunk +63 lines, -0 lines 0 comments Download
A src/gpu/instanced/InstanceProcessor.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 1 chunk +2096 lines, -0 lines 0 comments Download
A src/gpu/instanced/InstancedRendering.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 1 chunk +187 lines, -0 lines 0 comments Download
A src/gpu/instanced/InstancedRendering.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 1 chunk +488 lines, -0 lines 0 comments Download
A src/gpu/instanced/InstancedRenderingTypes.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 1 chunk +192 lines, -0 lines 0 comments Download

Depends on Patchset:

Messages

Total messages: 35 (15 generated)
csmartdalton
Hopefully this one is simpler than the last one. I still need to put in ...
4 years, 6 months ago (2016-06-15 19:46:53 UTC) #3
bsalomon
On 2016/06/15 19:46:53, csmartdalton wrote: > Hopefully this one is simpler than the last one. ...
4 years, 6 months ago (2016-06-20 14:48:52 UTC) #4
bsalomon
https://codereview.chromium.org/2066993003/diff/80001/src/gpu/instanced/InstancedRenderingTypes.h File src/gpu/instanced/InstancedRenderingTypes.h (right): https://codereview.chromium.org/2066993003/diff/80001/src/gpu/instanced/InstancedRenderingTypes.h#newcode91 src/gpu/instanced/InstancedRenderingTypes.h:91: enum AttribIdx { You could make these enum classes ...
4 years, 6 months ago (2016-06-20 14:49:54 UTC) #5
csmartdalton
https://codereview.chromium.org/2066993003/diff/80001/src/gpu/instanced/InstancedRenderingTypes.h File src/gpu/instanced/InstancedRenderingTypes.h (right): https://codereview.chromium.org/2066993003/diff/80001/src/gpu/instanced/InstancedRenderingTypes.h#newcode91 src/gpu/instanced/InstancedRenderingTypes.h:91: enum AttribIdx { On 2016/06/20 14:49:54, bsalomon wrote: > ...
4 years, 6 months ago (2016-06-20 15:33:47 UTC) #6
bsalomon
On 2016/06/20 15:33:47, csmartdalton wrote: > https://codereview.chromium.org/2066993003/diff/80001/src/gpu/instanced/InstancedRenderingTypes.h > File src/gpu/instanced/InstancedRenderingTypes.h (right): > > https://codereview.chromium.org/2066993003/diff/80001/src/gpu/instanced/InstancedRenderingTypes.h#newcode91 > ...
4 years, 6 months ago (2016-06-20 15:38:31 UTC) #7
csmartdalton
This change is all traiged now and ready to land. I'm just hoping for a ...
4 years, 5 months ago (2016-06-30 18:37:53 UTC) #12
bsalomon
lgtm
4 years, 5 months ago (2016-06-30 18:47:46 UTC) #13
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/2066993003/360001
4 years, 5 months ago (2016-06-30 18:48:32 UTC) #15
commit-bot: I haz the power
Try jobs failed on following builders: skia_presubmit-Trybot on master.client.skia.fyi (JOB_FAILED, http://build.chromium.org/p/client.skia.fyi/builders/skia_presubmit-Trybot/builds/10832)
4 years, 5 months ago (2016-06-30 18:50:07 UTC) #17
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/2066993003/380001
4 years, 5 months ago (2016-06-30 18:58:04 UTC) #20
commit-bot: I haz the power
Committed patchset #20 (id:380001) as https://skia.googlesource.com/skia/+/42eafa4bc00354b132ad114d22ed6b95d8849891
4 years, 5 months ago (2016-06-30 19:15:53 UTC) #22
commit-bot: I haz the power
CQ bit was unchecked.
4 years, 5 months ago (2016-06-30 19:15:56 UTC) #23
Kunihiko Sakamoto
A revert of this CL (patchset #20 id:380001) has been created in https://codereview.chromium.org/2123693002/ by ksakamoto@chromium.org. ...
4 years, 5 months ago (2016-07-05 04:10:52 UTC) #24
csmartdalton
This should remove the static initializer. Is there an easy way to re-run the failing ...
4 years, 5 months ago (2016-07-05 23:45:25 UTC) #27
Kunihiko Sakamoto
On 2016/07/05 23:45:25, csmartdalton wrote: > This should remove the static initializer. Is there an ...
4 years, 5 months ago (2016-07-06 01:21:16 UTC) #28
csmartdalton
On 2016/07/06 01:21:16, Kunihiko Sakamoto wrote: > On 2016/07/05 23:45:25, csmartdalton wrote: > > This ...
4 years, 5 months ago (2016-07-06 17:48:12 UTC) #29
csmartdalton
On 2016/07/06 17:48:12, csmartdalton wrote: > On 2016/07/06 01:21:16, Kunihiko Sakamoto wrote: > > On ...
4 years, 5 months ago (2016-07-07 07:53:29 UTC) #30
bsalomon
lgtm
4 years, 5 months ago (2016-07-07 13:51:38 UTC) #31
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/2066993003/440001
4 years, 5 months ago (2016-07-07 15:27:16 UTC) #33
commit-bot: I haz the power
4 years, 5 months ago (2016-07-07 15:49:15 UTC) #35
Message was sent while issue was closed.
Committed patchset #23 (id:440001) as
https://skia.googlesource.com/skia/+/a7f29640f6ab4eb50962a9d9f12d01ac2ce8b471

Powered by Google App Engine
This is Rietveld 408576698