Fix confusing macro misuse in GrGLGetGLSLGeneration

The two macros (GR_GL_VER and GR_GLSL_VER) are equivalent, but
everywhere else (including in this function), we're careful to
use them based on the type of version (GL or GLSL). These uses
were inconsistent.

Change-Id: Iefcaf207f29f62541a2fe9252095f6601171a8d5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/558931
Auto-Submit: Brian Osman <brianosman@google.com>
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
This commit is contained in:
Brian Osman 2022-07-15 11:27:17 -04:00 committed by SkCQ
parent 213d41c8c8
commit e99248cf83

View File

@ -45,7 +45,7 @@ bool GrGLGetGLSLGeneration(const GrGLDriverInfo& info, SkSL::GLSLGeneration* gen
}
return true;
} else if (GR_IS_GR_GL_ES(info.fStandard)) {
SkASSERT(ver >= GR_GL_VER(1,00));
SkASSERT(ver >= GR_GLSL_VER(1,00));
if (ver >= GR_GLSL_VER(3,20)) {
*generation = SkSL::GLSLGeneration::k320es;
} else if (ver >= GR_GLSL_VER(3,10)) {
@ -57,7 +57,7 @@ bool GrGLGetGLSLGeneration(const GrGLDriverInfo& info, SkSL::GLSLGeneration* gen
}
return true;
} else if (GR_IS_GR_WEBGL(info.fStandard)) {
SkASSERT(ver >= GR_GL_VER(1,0));
SkASSERT(ver >= GR_GLSL_VER(1,0));
if (ver >= GR_GLSL_VER(2,0)) {
*generation = SkSL::GLSLGeneration::k300es;
} else {