Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(307)

Issue 7237045: Add GrDrawTarget::DrawInfo, combine API for performing indexed/non-indexed draws in subclasses. (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 5 months ago by bsalomon
Modified:
11 years, 5 months ago
Reviewers:
JimVV, robertphillips
CC:
skia-review_googlegroups.com
Base URL:
http://skia.googlecode.com/svn/trunk/
Visibility:
Public.

Description

Add GrDrawTarget::DrawInfo, combine API for performing indexed/non-indexed draws in subclasses. Committed: https://code.google.com/p/skia/source/detail?r=7466

Patch Set 1 #

Patch Set 2 : #

Total comments: 9
Unified diffs Side-by-side diffs Delta from patch set Stats (+154 lines, -276 lines) Patch
M src/gpu/GrDrawTarget.h View 1 2 chunks +32 lines, -8 lines 0 comments Download
M src/gpu/GrDrawTarget.cpp View 1 1 chunk +16 lines, -8 lines 0 comments Download
M src/gpu/GrGpu.h View 1 4 chunks +5 lines, -31 lines 0 comments Download
M src/gpu/GrGpu.cpp View 1 1 chunk +4 lines, -31 lines 0 comments Download
M src/gpu/GrInOrderDrawBuffer.h View 1 4 chunks +6 lines, -11 lines 1 comment Download
M src/gpu/GrInOrderDrawBuffer.cpp View 1 7 chunks +54 lines, -102 lines 4 comments Download
M src/gpu/gl/GrGpuGL.h View 1 2 chunks +5 lines, -14 lines 4 comments Download
M src/gpu/gl/GrGpuGL.cpp View 1 3 chunks +19 lines, -45 lines 0 comments Download
M src/gpu/gl/GrGpuGL_program.cpp View 1 3 chunks +13 lines, -26 lines 0 comments Download

Messages

Total messages: 3
bsalomon
The motivation for this is that GrDrawTarget will do any processing to support GrEffect dst-reads ...
11 years, 5 months ago (2013-01-28 20:22:20 UTC) #1
robertphillips
LGTM + suggestions https://codereview.appspot.com/7237045/diff/2001/src/gpu/GrInOrderDrawBuffer.cpp File src/gpu/GrInOrderDrawBuffer.cpp (right): https://codereview.appspot.com/7237045/diff/2001/src/gpu/GrInOrderDrawBuffer.cpp#newcode378 src/gpu/GrInOrderDrawBuffer.cpp:378: if (!info.vertexCount()) { return; } ? ...
11 years, 5 months ago (2013-01-29 15:19:45 UTC) #2
bsalomon
11 years, 5 months ago (2013-01-30 16:10:15 UTC) #3
https://codereview.appspot.com/7237045/diff/2001/src/gpu/GrInOrderDrawBuffer.cpp
File src/gpu/GrInOrderDrawBuffer.cpp (right):

https://codereview.appspot.com/7237045/diff/2001/src/gpu/GrInOrderDrawBuffer....
src/gpu/GrInOrderDrawBuffer.cpp:378: 
On 2013/01/29 15:19:45, robertphillips wrote:
> if (!info.vertexCount()) {
>     return;
> }
> ?

I removed the checks b/c GrDrawTarget is already checking the counts before
calling this

https://codereview.appspot.com/7237045/diff/2001/src/gpu/GrInOrderDrawBuffer....
src/gpu/GrInOrderDrawBuffer.cpp:836: 
On 2013/01/29 15:19:45, robertphillips wrote:
> Fuse these two recordDraws into one?

The next CL will eliminate the one that does not take a DrawInfo. DrawRecord
will a subclass of DrawInfo and always initialized from a DrawInfo passed by
GrDrawTarget.

https://codereview.appspot.com/7237045/diff/2001/src/gpu/gl/GrGpuGL.h
File src/gpu/gl/GrGpuGL.h (right):

https://codereview.appspot.com/7237045/diff/2001/src/gpu/gl/GrGpuGL.h#newcode117
src/gpu/gl/GrGpuGL.h:117: // sets up vertex attribute pointers and strides.
On 2013/01/29 15:19:45, robertphillips wrote:
> explanation of "extraStartIndexOffset"?

Done.

    // sets up vertex attribute pointers and strides. startIndexOffset specifies
an additional
    // offset into the index buffer to the first index to be read. It accounts
for the fact that
    // index buffer pool may have provided space in the middle of a larger index
buffer.

Renamed to startIndexOffset.

https://codereview.appspot.com/7237045/diff/2001/src/gpu/gl/GrGpuGL.h#newcode118
src/gpu/gl/GrGpuGL.h:118: void setupGeometry(const DrawInfo& info, int*
extraStartIndexOffset);
On 2013/01/29 15:19:45, robertphillips wrote:
> extra extra

Done.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b