diff options
author | 2015-01-14 08:12:47 -0800 | |
---|---|---|
committer | 2015-01-14 08:12:47 -0800 | |
commit | 71c9260e6fa1798ad1e41b2c2ae9b3cce08bb610 (patch) | |
tree | 6dcf4f549ee113669d8becc37c83225fcba36ba5 /src/gpu/GrInOrderDrawBuffer.cpp | |
parent | 95145a9d3e0be24769c4c4e3810058e08b06fd3b (diff) |
More changes to bring together path / geo procs
BUG=skia:
Review URL: https://codereview.chromium.org/820783005
Diffstat (limited to 'src/gpu/GrInOrderDrawBuffer.cpp')
-rw-r--r-- | src/gpu/GrInOrderDrawBuffer.cpp | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/src/gpu/GrInOrderDrawBuffer.cpp b/src/gpu/GrInOrderDrawBuffer.cpp index e6e7b80829..468045c634 100644 --- a/src/gpu/GrInOrderDrawBuffer.cpp +++ b/src/gpu/GrInOrderDrawBuffer.cpp @@ -245,7 +245,7 @@ void GrInOrderDrawBuffer::onDraw(const GrDrawState& ds, const GrDeviceCoordTexture* dstCopy) { SkASSERT(info.vertexBuffer() && (!info.isIndexed() || info.indexBuffer())); - if (!this->recordStateAndShouldDraw(ds, gp, NULL, + if (!this->recordStateAndShouldDraw(ds, gp, GrGpu::PrimTypeToDrawType(info.primitiveType()), scissorState, dstCopy)) { return; @@ -287,7 +287,7 @@ void GrInOrderDrawBuffer::onDrawPath(const GrDrawState& ds, const GrStencilSettings& stencilSettings, const GrDeviceCoordTexture* dstCopy) { // TODO: Only compare the subset of GrDrawState relevant to path covering? - if (!this->recordStateAndShouldDraw(ds, NULL, pathProc, GrGpu::kDrawPath_DrawType, + if (!this->recordStateAndShouldDraw(ds, pathProc, GrGpu::kDrawPath_DrawType, scissorState, dstCopy)) { return; } @@ -311,7 +311,7 @@ void GrInOrderDrawBuffer::onDrawPaths(const GrDrawState& ds, SkASSERT(indices); SkASSERT(transformValues); - if (!this->recordStateAndShouldDraw(ds, NULL, pathProc, GrGpu::kDrawPath_DrawType, scissorState, + if (!this->recordStateAndShouldDraw(ds, pathProc, GrGpu::kDrawPath_DrawType, scissorState, dstCopy)) { return; } @@ -513,13 +513,12 @@ bool GrInOrderDrawBuffer::onCopySurface(GrSurface* dst, } bool GrInOrderDrawBuffer::recordStateAndShouldDraw(const GrDrawState& ds, - const GrGeometryProcessor* gp, - const GrPathProcessor* pathProc, + const GrPrimitiveProcessor* primProc, GrGpu::DrawType drawType, const GrScissorState& scissor, const GrDeviceCoordTexture* dstCopy) { SetState* ss = GrNEW_APPEND_TO_RECORDER(fCmdBuffer, SetState, - (ds, gp, pathProc, *this->getGpu()->caps(), scissor, + (ds, primProc, *this->getGpu()->caps(), scissor, dstCopy, drawType)); if (ss->fState.mustSkip()) { fCmdBuffer.pop_back(); |