Remove guard around getBackendTexture/RenderTarget calls

Bug: skia:
Change-Id: Ia9ad987d4af183985724f32b022553af0fcb2b78
Reviewed-on: https://skia-review.googlesource.com/120124
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
This commit is contained in:
Greg Daniel 2018-04-10 16:22:41 -04:00 committed by Skia Commit-Bot
parent c64ee20e13
commit 044b67d6c7
4 changed files with 0 additions and 10 deletions

View File

@ -543,7 +543,6 @@ public:
GrBackendObject getTextureHandle(bool flushPendingGrContextIO,
GrSurfaceOrigin* origin = nullptr) const;
#if GR_TEST_UTILS
/** Retrieves the backend texture. If SkImage has no backend texture, an invalid
object is returned. Call GrBackendTexture::isValid to determine if the result
is valid.
@ -559,7 +558,6 @@ public:
*/
GrBackendTexture getBackendTexture(bool flushPendingGrContextIO,
GrSurfaceOrigin* origin = nullptr) const;
#endif
/** \enum SkImage::CachingHint
CachingHint selects whether Skia may internally cache SkBitmap generated by

View File

@ -459,7 +459,6 @@ public:
bool getRenderTargetHandle(GrBackendObject* backendObject,
BackendHandleAccess backendHandleAccess);
#if GR_TEST_UTILS
/** Retrieves the backend texture. If Surface has no backend texture, an invalid
object is returned. Call GrBackendTexture::isValid to determine if the result
is valid.
@ -486,7 +485,6 @@ public:
@return GPU render target reference; invalid on failure
*/
GrBackendRenderTarget getBackendRenderTarget(BackendHandleAccess backendHandleAccess);
#endif
/** Returns SkCanvas that draws into SkSurface. Subsequent calls return the same SkCanvas.
SkCanvas returned is managed and owned by SkSurface, and is deleted when SkSurface

View File

@ -168,12 +168,10 @@ GrBackendObject SkImage::getTextureHandle(bool flushPendingGrContextIO,
return as_IB(this)->onGetTextureHandle(flushPendingGrContextIO, origin);
}
#if GR_TEST_UTILS
GrBackendTexture SkImage::getBackendTexture(bool flushPendingGrContextIO,
GrSurfaceOrigin* origin) const {
return as_IB(this)->onGetBackendTexture(flushPendingGrContextIO, origin);
}
#endif
bool SkImage::isValid(GrContext* context) const {
if (context && context->contextPriv().abandoned()) {
@ -190,12 +188,10 @@ bool SkImage::isTextureBacked() const { return false; }
GrBackendObject SkImage::getTextureHandle(bool, GrSurfaceOrigin*) const { return 0; }
#if GR_TEST_UTILS
GrBackendTexture SkImage::getBackendTexture(bool flushPendingGrContextIO,
GrSurfaceOrigin* origin) const {
return GrBackendTexture(); // invalid
}
#endif
bool SkImage::isValid(GrContext* context) const {
if (context) {

View File

@ -226,7 +226,6 @@ bool SkSurface::getRenderTargetHandle(GrBackendObject* obj, BackendHandleAccess
return asSB(this)->onGetRenderTargetHandle(obj, access);
}
#if GR_TEST_UTILS
GrBackendTexture SkSurface::getBackendTexture(BackendHandleAccess access) {
return asSB(this)->onGetBackendTexture(access);
}
@ -234,7 +233,6 @@ GrBackendTexture SkSurface::getBackendTexture(BackendHandleAccess access) {
GrBackendRenderTarget SkSurface::getBackendRenderTarget(BackendHandleAccess access) {
return asSB(this)->onGetBackendRenderTarget(access);
}
#endif
void SkSurface::prepareForExternalIO() {
this->flush();