Remove hacks for UShort2 texture coords
Plumb GPU type down for binding of vertex attributes in GL. Use that
to select between float and int versions of VertexAttribPointer.
For client code that was relying on the strange behavior of UShort2,
use shader caps to pick the appropriate GrSLType.
Bug: skia:
Change-Id: If52ea49e0a5667246687e90e088d0823dbedb921
Reviewed-on: https://skia-review.googlesource.com/155401
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
diff --git a/src/gpu/glsl/GrGLSL.cpp b/src/gpu/glsl/GrGLSL.cpp
index 848f571..694aaa7 100644
--- a/src/gpu/glsl/GrGLSL.cpp
+++ b/src/gpu/glsl/GrGLSL.cpp
@@ -71,14 +71,7 @@
case kUShort_GrSLType:
return "ushort";
case kUShort2_GrSLType:
- if (shaderCaps->integerSupport()) {
- return "ushort2";
- } else {
- // uint2 (aka uvec2) isn't supported in GLSL ES 1.00/GLSL 1.20
- // FIXME: this should be handled by the client code rather than relying on
- // unconventional ushort2 behavior.
- return "float2";
- }
+ return "ushort2";
case kUShort3_GrSLType:
return "ushort3";
case kUShort4_GrSLType: