Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(45)

Unified Diff: third_party/WebKit/Source/platform/graphics/gpu/Extensions3DUtil.cpp

Issue 2776083002: enable fallback path (Closed)
Patch Set: use stream read Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/platform/graphics/gpu/Extensions3DUtil.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/platform/graphics/gpu/Extensions3DUtil.cpp
diff --git a/third_party/WebKit/Source/platform/graphics/gpu/Extensions3DUtil.cpp b/third_party/WebKit/Source/platform/graphics/gpu/Extensions3DUtil.cpp
index c15baff9cd520de86eff9fdcc7314f77d44d488a..6bea0cbbf6f16d1dd9e48f0c561cf615ecc3df00 100644
--- a/third_party/WebKit/Source/platform/graphics/gpu/Extensions3DUtil.cpp
+++ b/third_party/WebKit/Source/platform/graphics/gpu/Extensions3DUtil.cpp
@@ -74,17 +74,19 @@ bool Extensions3DUtil::isExtensionEnabled(const String& name) {
return m_enabledExtensions.contains(name);
}
-bool Extensions3DUtil::canUseCopyTextureCHROMIUM(GLenum destTarget,
- GLenum destFormat,
- GLenum destType,
- GLint level) {
- // TODO(zmo): restriction of (RGB || RGBA)/UNSIGNED_BYTE/(Level 0) should be
- // lifted when GLES2Interface::CopyTextureCHROMIUM(...) are fully functional.
- if (destTarget == GL_TEXTURE_2D &&
- (destFormat == GL_RGB || destFormat == GL_RGBA) &&
- destType == GL_UNSIGNED_BYTE && !level)
- return true;
- return false;
+bool Extensions3DUtil::canUseCopyTextureCHROMIUM(GLenum destTarget) {
+ switch (destTarget) {
+ case GL_TEXTURE_2D:
+ case GL_TEXTURE_CUBE_MAP_POSITIVE_X:
+ case GL_TEXTURE_CUBE_MAP_NEGATIVE_X:
+ case GL_TEXTURE_CUBE_MAP_POSITIVE_Y:
+ case GL_TEXTURE_CUBE_MAP_NEGATIVE_Y:
+ case GL_TEXTURE_CUBE_MAP_POSITIVE_Z:
+ case GL_TEXTURE_CUBE_MAP_NEGATIVE_Z:
+ return true;
+ default:
+ return false;
+ }
}
} // namespace blink
« no previous file with comments | « third_party/WebKit/Source/platform/graphics/gpu/Extensions3DUtil.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698