Refer to GLSL extensions through TExtension enum
Extensions are now referred to by enum values instead of strings most
of the time. This gets rid of unnecessary copying of strings. The code
is easier to work with than before as typoing the extension enum names
will be caught by the compiler.
BUG=angleproject:2147
TEST=angle_unittests
Change-Id: Ifa61b9f86ef03211188fc23bc23a5ce4e4d8c390
Reviewed-on: https://chromium-review.googlesource.com/571002
Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
diff --git a/src/compiler/translator/InitializeVariables.cpp b/src/compiler/translator/InitializeVariables.cpp
index bab1b6a..61c02c4 100644
--- a/src/compiler/translator/InitializeVariables.cpp
+++ b/src/compiler/translator/InitializeVariables.cpp
@@ -107,7 +107,7 @@
{
initializedSymbol = ReferenceBuiltInVariable(name, symbolTable, shaderVersion);
if (initializedSymbol->getQualifier() == EvqFragData &&
- !IsExtensionEnabled(extensionBehavior, "GL_EXT_draw_buffers"))
+ !IsExtensionEnabled(extensionBehavior, TExtension::EXT_draw_buffers))
{
// If GL_EXT_draw_buffers is disabled, only the 0th index of gl_FragData can be
// written to.