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

Unified Diff: src/gpu/gl/GrGLGLSL.cpp

Issue 1417993004: Add version string and force highp NDS transfrom to GLSLCaps (Closed) Base URL: https://skia.googlesource.com/skia.git@renameShaderVar
Patch Set: Fix glslInit Created 5 years, 2 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 | « src/gpu/gl/GrGLGLSL.h ('k') | src/gpu/gl/GrGLGpu.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/gl/GrGLGLSL.cpp
diff --git a/src/gpu/gl/GrGLGLSL.cpp b/src/gpu/gl/GrGLGLSL.cpp
index 76988513c03ea88c789525621d31eb2f52555aba..4d2bf9794baa43f7ef593f50cb0e0f292d05fbab 100755
--- a/src/gpu/gl/GrGLGLSL.cpp
+++ b/src/gpu/gl/GrGLGLSL.cpp
@@ -48,48 +48,6 @@ bool GrGLGetGLSLGeneration(const GrGLInterface* gl, GrGLSLGeneration* generation
}
}
-const char* GrGLGetGLSLVersionDecl(const GrGLContextInfo& info) {
- switch (info.glslGeneration()) {
- case k110_GrGLSLGeneration:
- if (kGLES_GrGLStandard == info.standard()) {
- // ES2s shader language is based on version 1.20 but is version
- // 1.00 of the ES language.
- return "#version 100\n";
- } else {
- SkASSERT(kGL_GrGLStandard == info.standard());
- return "#version 110\n";
- }
- case k130_GrGLSLGeneration:
- SkASSERT(kGL_GrGLStandard == info.standard());
- return "#version 130\n";
- case k140_GrGLSLGeneration:
- SkASSERT(kGL_GrGLStandard == info.standard());
- return "#version 140\n";
- case k150_GrGLSLGeneration:
- SkASSERT(kGL_GrGLStandard == info.standard());
- if (info.caps()->isCoreProfile()) {
- return "#version 150\n";
- } else {
- return "#version 150 compatibility\n";
- }
- case k330_GrGLSLGeneration:
- if (kGLES_GrGLStandard == info.standard()) {
- return "#version 300 es\n";
- } else {
- SkASSERT(kGL_GrGLStandard == info.standard());
- if (info.caps()->isCoreProfile()) {
- return "#version 330\n";
- } else {
- return "#version 330 compatibility\n";
- }
- }
- case k310es_GrGLSLGeneration:
- SkASSERT(kGLES_GrGLStandard == info.standard());
- return "#version 310 es\n";
- }
- return "<no version>";
-}
-
void GrGLAppendGLSLDefaultFloatPrecisionDeclaration(GrSLPrecision p, GrGLStandard s, SkString* out) {
// Desktop GLSL has added precision qualifiers but they don't do anything.
if (kGLES_GrGLStandard == s) {
« no previous file with comments | « src/gpu/gl/GrGLGLSL.h ('k') | src/gpu/gl/GrGLGpu.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698