Pack VertexAttribType enum.

This improves performance slightly in vertex array format checks.
Instead of needing to switch on GLenum values we can use packed arrays
and tables to determine the values we need.

Does not significantly affect performance but will enable future work.

Bug: angleproject:3074
Change-Id: I6f4821a463e9b41fe3f8c8967eb3ed4c1d6b84be
Reviewed-on: https://chromium-review.googlesource.com/c/1393903
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
diff --git a/src/libANGLE/renderer/d3d/ProgramD3D.cpp b/src/libANGLE/renderer/d3d/ProgramD3D.cpp
index 11c330f..48cd017 100644
--- a/src/libANGLE/renderer/d3d/ProgramD3D.cpp
+++ b/src/libANGLE/renderer/d3d/ProgramD3D.cpp
@@ -53,8 +53,12 @@
                 GLenum componentType = gl::VariableComponentType(transposedType);
                 GLuint components    = static_cast<GLuint>(gl::VariableColumnCount(transposedType));
                 bool pureInt         = (componentType != GL_FLOAT);
+
+                gl::VertexAttribType attribType =
+                    gl::FromGLenum<gl::VertexAttribType>(componentType);
+
                 angle::FormatID defaultID =
-                    gl::GetVertexFormatID(componentType, GL_FALSE, components, pureInt);
+                    gl::GetVertexFormatID(attribType, GL_FALSE, components, pureInt);
 
                 inputLayoutOut->push_back(defaultID);
             }