aboutsummaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authorGravatar jvanverth <jvanverth@google.com>2016-02-19 08:43:26 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2016-02-19 08:43:26 -0800
commitd106c2c64012688f8d1439543d942f8f66a142e0 (patch)
tree6ded2e795afeadfbe3f11e766a012a10747f33c3 /include
parent85fca851e621d18db9b0cb5dc47878a77310ef15 (diff)
Revert of Use unorm shorts for texture coordinates when rendering text. (patchset #3 id:40001 of https://codereview.chromium.org/1713693002/ )
Reason for revert: Causing issues with text on Mali 400s. Examples: largeglyphblur, imageblurtiled. It appears that there are precision problems. Original issue's description: > Use unorm shorts for texture coordinates when rendering text. > > There are a couple of reasons for this: > - Vulkan does not guarantee conversions from integral vertex attributes > to floating point shader variables > - This may be faster and more precise on some platforms, as it avoids > the aforementioned conversion and changes a multiply by a very small > value to a multiply by a medium-sized value. > GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1713693002 > TBR=bsalomon@google.com > > Committed: https://skia.googlesource.com/skia/+/e507ff0460f4f878214b9454fb5b9ab8d64d8063 TBR=joshualitt@google.com # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Review URL: https://codereview.chromium.org/1709133003
Diffstat (limited to 'include')
-rw-r--r--include/gpu/GrTypesPriv.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/include/gpu/GrTypesPriv.h b/include/gpu/GrTypesPriv.h
index 834c185944..e04a912d3e 100644
--- a/include/gpu/GrTypesPriv.h
+++ b/include/gpu/GrTypesPriv.h
@@ -212,7 +212,7 @@ enum GrVertexAttribType {
kUByte_GrVertexAttribType, // unsigned byte, e.g. coverage
kVec4ub_GrVertexAttribType, // vector of 4 unsigned bytes, e.g. colors
- kVec2us_GrVertexAttribType, // vector of 2 shorts, e.g. texture coordinates
+ kVec2s_GrVertexAttribType, // vector of 2 shorts, e.g. texture coordinates
kInt_GrVertexAttribType,
kUint_GrVertexAttribType,
@@ -235,7 +235,7 @@ static inline int GrVertexAttribTypeVectorCount(GrVertexAttribType type) {
GR_STATIC_ASSERT(3 == kVec4f_GrVertexAttribType);
GR_STATIC_ASSERT(4 == kUByte_GrVertexAttribType);
GR_STATIC_ASSERT(5 == kVec4ub_GrVertexAttribType);
- GR_STATIC_ASSERT(6 == kVec2us_GrVertexAttribType);
+ GR_STATIC_ASSERT(6 == kVec2s_GrVertexAttribType);
GR_STATIC_ASSERT(7 == kInt_GrVertexAttribType);
GR_STATIC_ASSERT(8 == kUint_GrVertexAttribType);
GR_STATIC_ASSERT(SK_ARRAY_COUNT(kCounts) == kGrVertexAttribTypeCount);
@@ -252,7 +252,7 @@ static inline size_t GrVertexAttribTypeSize(GrVertexAttribType type) {
4*sizeof(float), // kVec4f_GrVertexAttribType
1*sizeof(char), // kUByte_GrVertexAttribType
4*sizeof(char), // kVec4ub_GrVertexAttribType
- 2*sizeof(int16_t), // kVec2us_GrVertexAttribType
+ 2*sizeof(int16_t), // kVec2s_GrVertexAttribType
sizeof(int32_t), // kInt_GrVertexAttribType
sizeof(uint32_t) // kUint_GrVertexAttribType
};
@@ -264,7 +264,7 @@ static inline size_t GrVertexAttribTypeSize(GrVertexAttribType type) {
GR_STATIC_ASSERT(3 == kVec4f_GrVertexAttribType);
GR_STATIC_ASSERT(4 == kUByte_GrVertexAttribType);
GR_STATIC_ASSERT(5 == kVec4ub_GrVertexAttribType);
- GR_STATIC_ASSERT(6 == kVec2us_GrVertexAttribType);
+ GR_STATIC_ASSERT(6 == kVec2s_GrVertexAttribType);
GR_STATIC_ASSERT(7 == kInt_GrVertexAttribType);
GR_STATIC_ASSERT(8 == kUint_GrVertexAttribType);
GR_STATIC_ASSERT(SK_ARRAY_COUNT(kSizes) == kGrVertexAttribTypeCount);
@@ -283,7 +283,7 @@ static inline bool GrVertexAttribTypeIsIntType(GrVertexAttribType type) {
GR_STATIC_ASSERT(3 == kVec4f_GrVertexAttribType);
GR_STATIC_ASSERT(4 == kUByte_GrVertexAttribType);
GR_STATIC_ASSERT(5 == kVec4ub_GrVertexAttribType);
- GR_STATIC_ASSERT(6 == kVec2us_GrVertexAttribType);
+ GR_STATIC_ASSERT(6 == kVec2s_GrVertexAttribType);
GR_STATIC_ASSERT(7 == kInt_GrVertexAttribType);
GR_STATIC_ASSERT(8 == kUint_GrVertexAttribType);
GR_STATIC_ASSERT(9 == kGrVertexAttribTypeCount);
@@ -300,7 +300,7 @@ static inline GrSLType GrVertexAttribTypeToSLType(GrVertexAttribType type) {
case kUByte_GrVertexAttribType:
case kFloat_GrVertexAttribType:
return kFloat_GrSLType;
- case kVec2us_GrVertexAttribType:
+ case kVec2s_GrVertexAttribType:
case kVec2f_GrVertexAttribType:
return kVec2f_GrSLType;
case kVec3f_GrVertexAttribType: