aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/GrBackendSurface.cpp
diff options
context:
space:
mode:
authorGravatar Timothy Liang <timliang@google.com>2018-06-28 15:50:36 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2018-06-28 20:21:17 +0000
commit036fdfe5aa1266dbc35f0a2c680f648b62b9c28b (patch)
tree5daf6dd36649795833724d954994438c9ab35dd2 /src/gpu/GrBackendSurface.cpp
parentbe0ab883e796b190cd20a4b1cfaedea932f9e0bf (diff)
implemented getting format from texture as virtual in gpu caps
Bug: skia: Change-Id: If6bbbd212ff472ea322d2bbed61995fe7ba85df7 Reviewed-on: https://skia-review.googlesource.com/138240 Commit-Queue: Timothy Liang <timliang@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com>
Diffstat (limited to 'src/gpu/GrBackendSurface.cpp')
-rw-r--r--src/gpu/GrBackendSurface.cpp28
1 files changed, 0 insertions, 28 deletions
diff --git a/src/gpu/GrBackendSurface.cpp b/src/gpu/GrBackendSurface.cpp
index eb7aea2020..d68b42a9ba 100644
--- a/src/gpu/GrBackendSurface.cpp
+++ b/src/gpu/GrBackendSurface.cpp
@@ -221,34 +221,6 @@ bool GrBackendTexture::getMockTextureInfo(GrMockTextureInfo* outInfo) const {
return false;
}
-GrBackendFormat GrBackendTexture::format() const {
- if (!this->isValid()) {
- return GrBackendFormat();
- }
-
- switch (this->backend()) {
-#ifdef SK_VULKAN
- case kVulkan_GrBackend: {
- GrVkImageInfo vkInfo;
- SkAssertResult(this->getVkImageInfo(&vkInfo));
- return GrBackendFormat::MakeVk(vkInfo.fFormat);
- }
-#endif
- case kOpenGL_GrBackend: {
- GrGLTextureInfo glInfo;
- SkAssertResult(this->getGLTextureInfo(&glInfo));
- return GrBackendFormat::MakeGL(glInfo.fFormat, glInfo.fTarget);
- }
- case kMock_GrBackend: {
- GrMockTextureInfo mockInfo;
- SkAssertResult(this->getMockTextureInfo(&mockInfo));
- return GrBackendFormat::MakeMock(mockInfo.fConfig);
- }
- default:
- return GrBackendFormat();
- }
-}
-
#if GR_TEST_UTILS
bool GrBackendTexture::TestingOnly_Equals(const GrBackendTexture& t0, const GrBackendTexture& t1) {
if (!t0.isValid() || !t1.isValid()) {