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

Issue 7221078: Make drawIndexedInstances non-virtual and rewrite GrIODB's drawRect on top of drawIndexedInstances. (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:
robertphillips
CC:
skia-review_googlegroups.com
Base URL:
http://skia.googlecode.com/svn/trunk/
Visibility:
Public.

Description

Make drawIndexedInstances non-virtual and rewrite GrIODB's drawRect on top of drawIndexedInstances. R=robertphillips@google.com Committed: https://code.google.com/p/skia/source/detail?r=7508

Patch Set 1 #

Patch Set 2 : #

Total comments: 16
Unified diffs Side-by-side diffs Delta from patch set Stats (+580 lines, -497 lines) Patch
M gyp/SampleApp.gyp View 1 chunk +1 line, -0 lines 0 comments Download
A samplecode/SampleManyRects.cpp View 1 chunk +80 lines, -0 lines 6 comments Download
M src/gpu/GrContext.cpp View 2 chunks +5 lines, -4 lines 2 comments Download
M src/gpu/GrDrawState.h View 2 chunks +26 lines, -5 lines 0 comments Download
M src/gpu/GrDrawState.cpp View 1 1 chunk +26 lines, -0 lines 2 comments Download
M src/gpu/GrDrawTarget.h View 10 chunks +65 lines, -32 lines 0 comments Download
M src/gpu/GrDrawTarget.cpp View 7 chunks +140 lines, -88 lines 0 comments Download
M src/gpu/GrInOrderDrawBuffer.h View 6 chunks +23 lines, -49 lines 0 comments Download
M src/gpu/GrInOrderDrawBuffer.cpp View 13 chunks +214 lines, -319 lines 6 comments Download

Messages

Total messages: 3
bsalomon
11 years, 5 months ago (2013-01-31 17:29:25 UTC) #1
robertphillips
LGTM + mainly comment suggestions https://codereview.appspot.com/7221078/diff/2001/samplecode/SampleManyRects.cpp File samplecode/SampleManyRects.cpp (right): https://codereview.appspot.com/7221078/diff/2001/samplecode/SampleManyRects.cpp#newcode15 samplecode/SampleManyRects.cpp:15: overall comment on what ...
11 years, 5 months ago (2013-01-31 18:48:57 UTC) #2
bsalomon
11 years, 5 months ago (2013-02-01 14:18:35 UTC) #3
https://codereview.appspot.com/7221078/diff/2001/samplecode/SampleManyRects.cpp
File samplecode/SampleManyRects.cpp (right):

https://codereview.appspot.com/7221078/diff/2001/samplecode/SampleManyRects.c...
samplecode/SampleManyRects.cpp:15: 
On 2013/01/31 18:48:57, robertphillips wrote:
> overall comment on what this sample is intended to do?

Done.

https://codereview.appspot.com/7221078/diff/2001/samplecode/SampleManyRects.c...
samplecode/SampleManyRects.cpp:39: SkRect clipRect = canvasRect;
On 2013/01/31 18:48:57, robertphillips wrote:
> comment on why doing the inset? Do we even use this value any more?

Removed

https://codereview.appspot.com/7221078/diff/2001/samplecode/SampleManyRects.c...
samplecode/SampleManyRects.cpp:51: // that the rect is inside the clip so the
clip changes interrupt batching.
On 2013/01/31 18:48:57, robertphillips wrote:
> It seems like we should be able to determine the rect is still in the clip for
> the majority of cases? Don't know if it would pay off time-wise though?

I think it would... This gets 12 to 16 times slower when the clip is rotated.

https://codereview.appspot.com/7221078/diff/2001/src/gpu/GrContext.cpp
File src/gpu/GrContext.cpp (right):

https://codereview.appspot.com/7221078/diff/2001/src/gpu/GrContext.cpp#newcod...
src/gpu/GrContext.cpp:103: delete fFontCache;
On 2013/01/31 18:48:57, robertphillips wrote:
> Why do we care about this?

Removed. I can't remember why I typed this since deleting null is fine.

https://codereview.appspot.com/7221078/diff/2001/src/gpu/GrDrawState.cpp
File src/gpu/GrDrawState.cpp (right):

https://codereview.appspot.com/7221078/diff/2001/src/gpu/GrDrawState.cpp#newc...
src/gpu/GrDrawState.cpp:548: 
On 2013/01/31 18:48:57, robertphillips wrote:
> is will -> will

Done.

https://codereview.appspot.com/7221078/diff/2001/src/gpu/GrInOrderDrawBuffer.cpp
File src/gpu/GrInOrderDrawBuffer.cpp (right):

https://codereview.appspot.com/7221078/diff/2001/src/gpu/GrInOrderDrawBuffer....
src/gpu/GrInOrderDrawBuffer.cpp:99: if (NULL != srcRects) {
On 2013/01/31 18:48:57, robertphillips wrote:
> I've seen this pattern a bunch - is it time for a inlineable helper method?

I think it appears two times, here and the base classes version of this
function.

It be consolidated but it'd be obsoleted by the stuff Jim is working on pretty
quickly. I don't know that we actually need an array of srcRects at all.

https://codereview.appspot.com/7221078/diff/2001/src/gpu/GrInOrderDrawBuffer....
src/gpu/GrInOrderDrawBuffer.cpp:123:
combinedMatrix.postConcat(this->drawState()->getViewMatrix());
On 2013/01/31 18:48:57, robertphillips wrote:
> want -> want to

Done.

https://codereview.appspot.com/7221078/diff/2001/src/gpu/GrInOrderDrawBuffer....
src/gpu/GrInOrderDrawBuffer.cpp:183: // Take into account that the viewport
edges may handle some clipping for us.
On 2013/01/31 18:48:57, robertphillips wrote:
> I think this needs to better explain why we are blasting out when the clip
> matches the rendertarget size

Done.
Sign in to reply to this message.

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