diff options
author | bsalomon <bsalomon@google.com> | 2014-12-02 09:40:12 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-12-02 09:40:12 -0800 |
commit | eff2c721b9877e5e9e6c71b21dde0e69eccb2b14 (patch) | |
tree | 8bcdab0e222341c5aef7036797fa7d7bf8d9dcab /src | |
parent | 5abbc420e36feb229ed3498d7482a79f089c0e35 (diff) |
move some copy surface stuff to GrFlushToGpuDrawTarget
Review URL: https://codereview.chromium.org/770813002
Diffstat (limited to 'src')
-rw-r--r-- | src/gpu/GrFlushToGpuDrawTarget.cpp | 11 | ||||
-rw-r--r-- | src/gpu/GrFlushToGpuDrawTarget.h | 5 | ||||
-rw-r--r-- | src/gpu/GrInOrderDrawBuffer.cpp | 11 | ||||
-rw-r--r-- | src/gpu/GrInOrderDrawBuffer.h | 5 |
4 files changed, 16 insertions, 16 deletions
diff --git a/src/gpu/GrFlushToGpuDrawTarget.cpp b/src/gpu/GrFlushToGpuDrawTarget.cpp index b8604684b1..7007625737 100644 --- a/src/gpu/GrFlushToGpuDrawTarget.cpp +++ b/src/gpu/GrFlushToGpuDrawTarget.cpp @@ -249,3 +249,14 @@ void GrFlushToGpuDrawTarget::geometrySourceWillPop(const GeometrySrcState& resto poolState.fUsedPoolIndexBytes = sizeof(uint16_t) * restoredState.fIndexCount; } } + +bool GrFlushToGpuDrawTarget::onCanCopySurface(const GrSurface* dst, + const GrSurface* src, + const SkIRect& srcRect, + const SkIPoint& dstPoint) { + return getGpu()->canCopySurface(dst, src, srcRect, dstPoint); +} + +bool GrFlushToGpuDrawTarget::onInitCopySurfaceDstDesc(const GrSurface* src, GrSurfaceDesc* desc) { + return getGpu()->initCopySurfaceDstDesc(src, desc); +} diff --git a/src/gpu/GrFlushToGpuDrawTarget.h b/src/gpu/GrFlushToGpuDrawTarget.h index f3f34b0cc8..2383c623d0 100644 --- a/src/gpu/GrFlushToGpuDrawTarget.h +++ b/src/gpu/GrFlushToGpuDrawTarget.h @@ -79,6 +79,11 @@ private: void willReserveVertexAndIndexSpace(int vertexCount, size_t vertexStride, int indexCount) SK_OVERRIDE; + bool onCanCopySurface(const GrSurface* dst, + const GrSurface* src, + const SkIRect& srcRect, + const SkIPoint& dstPoint) SK_OVERRIDE; + bool onInitCopySurfaceDstDesc(const GrSurface* src, GrSurfaceDesc* desc) SK_OVERRIDE; GeoPoolStateStack fGeoPoolStateStack; SkAutoTUnref<GrGpu> fGpu; diff --git a/src/gpu/GrInOrderDrawBuffer.cpp b/src/gpu/GrInOrderDrawBuffer.cpp index 8a136cdb2b..6b98e13439 100644 --- a/src/gpu/GrInOrderDrawBuffer.cpp +++ b/src/gpu/GrInOrderDrawBuffer.cpp @@ -481,17 +481,6 @@ bool GrInOrderDrawBuffer::onCopySurface(GrSurface* dst, return false; } -bool GrInOrderDrawBuffer::onCanCopySurface(const GrSurface* dst, - const GrSurface* src, - const SkIRect& srcRect, - const SkIPoint& dstPoint) { - return getGpu()->canCopySurface(dst, src, srcRect, dstPoint); -} - -bool GrInOrderDrawBuffer::onInitCopySurfaceDstDesc(const GrSurface* src, GrSurfaceDesc* desc) { - return getGpu()->initCopySurfaceDstDesc(src, desc); -} - bool GrInOrderDrawBuffer::recordStateAndShouldDraw(const GrDrawState& ds, GrGpu::DrawType drawType, const GrClipMaskManager::ScissorState& scissor, diff --git a/src/gpu/GrInOrderDrawBuffer.h b/src/gpu/GrInOrderDrawBuffer.h index 207f88e65d..532842a3b4 100644 --- a/src/gpu/GrInOrderDrawBuffer.h +++ b/src/gpu/GrInOrderDrawBuffer.h @@ -225,11 +225,6 @@ private: GrSurface* src, const SkIRect& srcRect, const SkIPoint& dstPoint) SK_OVERRIDE; - bool onCanCopySurface(const GrSurface* dst, - const GrSurface* src, - const SkIRect& srcRect, - const SkIPoint& dstPoint) SK_OVERRIDE; - bool onInitCopySurfaceDstDesc(const GrSurface* src, GrSurfaceDesc* desc) SK_OVERRIDE; // Attempts to concat instances from info onto the previous draw. info must represent an // instanced draw. The caller must have already recorded a new draw state and clip if necessary. |