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/glsl/GrGLSLUniformHandler.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/glsl/GrGLSLUniformHandler.h')
-rw-r--r-- | src/gpu/glsl/GrGLSLUniformHandler.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/gpu/glsl/GrGLSLUniformHandler.h b/src/gpu/glsl/GrGLSLUniformHandler.h index cf80c3ff0a..84bbfa104c 100644 --- a/src/gpu/glsl/GrGLSLUniformHandler.h +++ b/src/gpu/glsl/GrGLSLUniformHandler.h @@ -38,6 +38,13 @@ public: return this->addUniformArray(visibility, type, precision, name, 0, outName); } + UniformHandle addUniform(uint32_t visibility, + GrSLType type, + const char* name, + const char** outName = nullptr) { + return this->addUniform(visibility, type, kDefault_GrSLPrecision, name, outName); + } + UniformHandle addUniformArray(uint32_t visibility, GrSLType type, GrSLPrecision precision, @@ -49,6 +56,16 @@ public: outName); } + UniformHandle addUniformArray(uint32_t visibility, + GrSLType type, + const char* name, + int arrayCount, + const char** outName = nullptr) { + SkASSERT(!GrSLTypeIsCombinedSamplerType(type)); + return this->internalAddUniformArray(visibility, type, kDefault_GrSLPrecision, name, true, + arrayCount, outName); + } + virtual const GrShaderVar& getUniformVariable(UniformHandle u) const = 0; /** |