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

Issue 6324046: Extend texture release on DrawState to also handle custom stages (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 11 months ago by TomH
Modified:
11 years, 10 months ago
Base URL:
http://skia.googlecode.com/svn/trunk/
Visibility:
Public.

Patch Set 1 #

Patch Set 2 : Rename as suggested by Brian #

Total comments: 2

Patch Set 3 : Debug upload: has namechanges, asserts as suggested, and asserts fail #

Total comments: 2

Patch Set 4 : Clean up debug, encapsulate checking for disabled stages, hack on batched text init() #

Patch Set 5 : Add warning to header file where no-one will ever see it #

Total comments: 2

Patch Set 6 : Done and done #

Unified diffs Side-by-side diffs Delta from patch set Stats (+38 lines, -18 lines) Patch
M src/gpu/GrBatchedTextContext.h View 1 2 3 4 1 chunk +2 lines, -0 lines 0 comments Download
M src/gpu/GrBatchedTextContext.cpp View 1 2 3 4 5 4 chunks +7 lines, -1 line 0 comments Download
M src/gpu/GrContext.cpp View 1 2 3 7 chunks +7 lines, -6 lines 0 comments Download
M src/gpu/GrDefaultTextContext.cpp View 1 2 3 4 5 1 chunk +0 lines, -2 lines 0 comments Download
M src/gpu/GrDrawState.h View 1 2 3 2 chunks +22 lines, -9 lines 0 comments Download

Messages

Total messages: 13
TomH
11 years, 11 months ago (2012-06-22 17:51:46 UTC) #1
bsalomon
On 2012/06/22 17:51:46, TomH wrote: How about disableStages()? It's shorter and still makes sense when ...
11 years, 11 months ago (2012-06-22 17:54:06 UTC) #2
robertphillips
LGTM but wasn't there supposed to be an assert somewhere in your code to make ...
11 years, 11 months ago (2012-06-22 17:56:37 UTC) #3
bsalomon
On 2012/06/22 17:56:37, robertphillips wrote: > LGTM but wasn't there supposed to be an assert ...
11 years, 11 months ago (2012-06-22 18:00:53 UTC) #4
TomH
On 2012/06/22 17:54:06, bsalomon wrote: > How about disableStages()? It's shorter and still makes sense ...
11 years, 11 months ago (2012-06-22 18:14:00 UTC) #5
bsalomon
http://codereview.appspot.com/6324046/diff/1003/src/gpu/GrDrawState.h File src/gpu/GrDrawState.h (right): http://codereview.appspot.com/6324046/diff/1003/src/gpu/GrDrawState.h#newcode229 src/gpu/GrDrawState.h:229: class AutoTextureStageRelease : public ::GrNoncopyable { I hate to ...
11 years, 11 months ago (2012-06-22 18:15:53 UTC) #6
TomH
So, when I add the asserts (see current patch), they fail during gm. shadertext, by ...
11 years, 11 months ago (2012-06-22 19:12:56 UTC) #7
TomH
On 2012/06/22 19:12:56, TomH wrote: > So, when I add the asserts (see current patch), ...
11 years, 11 months ago (2012-06-22 19:24:57 UTC) #8
bsalomon
Mostly LGTM. http://codereview.appspot.com/6324046/diff/3003/src/gpu/GrContext.cpp File src/gpu/GrContext.cpp (right): http://codereview.appspot.com/6324046/diff/3003/src/gpu/GrContext.cpp#newcode248 src/gpu/GrContext.cpp:248: SkDebugf("setCustomStage %lu\n", morph.get()); accidentally left in? http://codereview.appspot.com/6324046/diff/3003/src/gpu/SkGpuDevice.cpp ...
11 years, 11 months ago (2012-06-22 19:25:06 UTC) #9
TomH
Mostly cleaned up. Mostly PTAL?
11 years, 11 months ago (2012-06-22 19:56:47 UTC) #10
bsalomon
Mostly LGTM http://codereview.appspot.com/6324046/diff/9002/src/gpu/GrBatchedTextContext.cpp File src/gpu/GrBatchedTextContext.cpp (right): http://codereview.appspot.com/6324046/diff/9002/src/gpu/GrBatchedTextContext.cpp#newcode30 src/gpu/GrBatchedTextContext.cpp:30: //fDrawTarget = fContext->getTextTarget(fGrPaint); Should we just axe ...
11 years, 11 months ago (2012-06-22 20:08:08 UTC) #11
TomH
Committed with r4313.
11 years, 11 months ago (2012-06-22 20:11:07 UTC) #12
TomH
11 years, 10 months ago (2012-06-26 19:53:43 UTC) #13
GrContext::setPaint()'s GrAssert(fDrawState->stagesDisabled()) had to be rolled
out in r4332 because it triggers in chrome.

A fairly minimal test is:
 - paint.setShader(SkGradientShader::CreateLinear(...))
 - paint.setTextSize(SkIntToScalar(500))
 - canvas->drawText(..., paint)

If either the shader OR the textSize is omitted, the assert succeeds.
Sign in to reply to this message.

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