diff options
author | Ethan Nicholas <ethannicholas@google.com> | 2017-09-18 14:10:39 -0400 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2017-09-18 18:32:13 +0000 |
commit | f7b8820dc813d1eb0b6b43fe4581dded0da38caf (patch) | |
tree | 518d313a9fa571a9f9ca26af7c381664694a4706 /src/gpu/GrShaderVar.h | |
parent | 47a540f503bc722393b61c4b822e95b17f200125 (diff) |
re-land of new SkSL precisions
Bug: skia:
Change-Id: Ic1deb3db2cbda6ca45f93dee99832971a36a2119
Reviewed-on: https://skia-review.googlesource.com/47841
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Diffstat (limited to 'src/gpu/GrShaderVar.h')
-rw-r--r-- | src/gpu/GrShaderVar.h | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/src/gpu/GrShaderVar.h b/src/gpu/GrShaderVar.h index 7f09f8cbf7..5a379b9d77 100644 --- a/src/gpu/GrShaderVar.h +++ b/src/gpu/GrShaderVar.h @@ -37,13 +37,12 @@ public: }; /** - * Defaults to a non-arry float with no precision specifier, type modifier, or layout qualifier. + * Defaults to a non-arry half with no type modifier or layout qualifier. */ GrShaderVar() - : fType(kFloat_GrSLType) + : fType(kHalf_GrSLType) , fTypeModifier(kNone_TypeModifier) , fCount(kNonArray) - , fPrecision(kDefault_GrSLPrecision) , fUseUniformFloatArrays(USE_UNIFORM_FLOAT_ARRAYS) { } @@ -116,7 +115,7 @@ public: const char* extraModifiers = nullptr, bool useUniformFloatArrays = USE_UNIFORM_FLOAT_ARRAYS) { SkASSERT(kVoid_GrSLType != type); - SkASSERT(kDefault_GrSLPrecision == precision || GrSLTypeAcceptsPrecision(type)); + SkASSERT(kDefault_GrSLPrecision == precision || GrSLTypeTemporarilyAcceptsPrecision(type)); fType = type; fTypeModifier = typeModifier; fName = name; @@ -140,7 +139,7 @@ public: const char* extraModifiers = nullptr, bool useUniformFloatArrays = USE_UNIFORM_FLOAT_ARRAYS) { SkASSERT(kVoid_GrSLType != type); - SkASSERT(kDefault_GrSLPrecision == precision || GrSLTypeAcceptsPrecision(type)); + SkASSERT(kDefault_GrSLPrecision == precision || GrSLTypeTemporarilyAcceptsPrecision(type)); fType = type; fTypeModifier = typeModifier; fName = name; @@ -165,7 +164,7 @@ public: const char* extraModifiers = nullptr, bool useUniformFloatArrays = USE_UNIFORM_FLOAT_ARRAYS) { SkASSERT(kVoid_GrSLType != type); - SkASSERT(kDefault_GrSLPrecision == precision || GrSLTypeAcceptsPrecision(type)); + SkASSERT(kDefault_GrSLPrecision == precision || GrSLTypeTemporarilyAcceptsPrecision(type)); fType = type; fTypeModifier = typeModifier; fName = name; @@ -190,7 +189,7 @@ public: const char* extraModifiers = nullptr, bool useUniformFloatArrays = USE_UNIFORM_FLOAT_ARRAYS) { SkASSERT(kVoid_GrSLType != type); - SkASSERT(kDefault_GrSLPrecision == precision || GrSLTypeAcceptsPrecision(type)); + SkASSERT(kDefault_GrSLPrecision == precision || GrSLTypeTemporarilyAcceptsPrecision(type)); fType = type; fTypeModifier = typeModifier; fName = name; |