Get rid of VertexFormatType.

The enum VertexFormatType is redundant with angle::FormatID.  The Vulkan
back end has already eschewed VertexFormatType, this change updates the
D3D back ends.

BUG=angleproject:2531

Change-Id: I67ea2203ca80be828f4c757a37810fe67a279364
Reviewed-on: https://chromium-review.googlesource.com/c/1263899
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Frank Henigman <fjhenigman@chromium.org>
diff --git a/src/libANGLE/renderer/d3d/DynamicHLSL.cpp b/src/libANGLE/renderer/d3d/DynamicHLSL.cpp
index 0dfea5f..7a60fb4 100644
--- a/src/libANGLE/renderer/d3d/DynamicHLSL.cpp
+++ b/src/libANGLE/renderer/d3d/DynamicHLSL.cpp
@@ -204,8 +204,8 @@
         if (!shaderAttribute.name.empty())
         {
             ASSERT(inputIndex < MAX_VERTEX_ATTRIBS);
-            VertexFormatType vertexFormatType =
-                inputIndex < inputLayout.size() ? inputLayout[inputIndex] : VERTEX_FORMAT_INVALID;
+            angle::FormatID vertexFormatID =
+                inputIndex < inputLayout.size() ? inputLayout[inputIndex] : angle::FormatID::NONE;
 
             // HLSL code for input structure
             if (IsMatrixType(shaderAttribute.type))
@@ -216,7 +216,7 @@
             }
             else
             {
-                GLenum componentType = mRenderer->getVertexComponentType(vertexFormatType);
+                GLenum componentType = mRenderer->getVertexComponentType(vertexFormatID);
 
                 if (shaderAttribute.name == "gl_InstanceID" ||
                     shaderAttribute.name == "gl_VertexID")
@@ -258,9 +258,9 @@
             // data reinterpretation (eg for pure integer->float, float->pure integer)
             // TODO: issue warning with gl debug info extension, when supported
             if (IsMatrixType(shaderAttribute.type) ||
-                (mRenderer->getVertexConversionType(vertexFormatType) & VERTEX_CONVERT_GPU) != 0)
+                (mRenderer->getVertexConversionType(vertexFormatID) & VERTEX_CONVERT_GPU) != 0)
             {
-                GenerateAttributeConversionHLSL(vertexFormatType, shaderAttribute, initStream);
+                GenerateAttributeConversionHLSL(vertexFormatID, shaderAttribute, initStream);
             }
             else
             {
@@ -1150,7 +1150,7 @@
 }
 
 // static
-void DynamicHLSL::GenerateAttributeConversionHLSL(gl::VertexFormatType vertexFormatType,
+void DynamicHLSL::GenerateAttributeConversionHLSL(angle::FormatID vertexFormatID,
                                                   const sh::ShaderVariable &shaderAttrib,
                                                   std::ostringstream &outStream)
 {
@@ -1163,7 +1163,7 @@
 
     GLenum shaderComponentType = VariableComponentType(shaderAttrib.type);
     int shaderComponentCount   = VariableComponentCount(shaderAttrib.type);
-    const gl::VertexFormat &vertexFormat = gl::GetVertexFormatFromType(vertexFormatType);
+    const gl::VertexFormat &vertexFormat = gl::GetVertexFormatFromID(vertexFormatID);
 
     // Perform integer to float conversion (if necessary)
     if (shaderComponentType == GL_FLOAT && vertexFormat.type != GL_FLOAT)
diff --git a/src/libANGLE/renderer/d3d/DynamicHLSL.h b/src/libANGLE/renderer/d3d/DynamicHLSL.h
index d138c82..eeda2cd 100644
--- a/src/libANGLE/renderer/d3d/DynamicHLSL.h
+++ b/src/libANGLE/renderer/d3d/DynamicHLSL.h
@@ -162,7 +162,7 @@
                                  bool programUsesPointSize,
                                  std::ostringstream &hlslStream) const;
 
-    static void GenerateAttributeConversionHLSL(gl::VertexFormatType vertexFormatType,
+    static void GenerateAttributeConversionHLSL(angle::FormatID vertexFormatID,
                                                 const sh::ShaderVariable &shaderAttrib,
                                                 std::ostringstream &outStream);
 };
diff --git a/src/libANGLE/renderer/d3d/ProgramD3D.cpp b/src/libANGLE/renderer/d3d/ProgramD3D.cpp
index 2bd0059..f1a0587 100644
--- a/src/libANGLE/renderer/d3d/ProgramD3D.cpp
+++ b/src/libANGLE/renderer/d3d/ProgramD3D.cpp
@@ -53,10 +53,10 @@
                 GLenum componentType = gl::VariableComponentType(transposedType);
                 GLuint components    = static_cast<GLuint>(gl::VariableColumnCount(transposedType));
                 bool pureInt         = (componentType != GL_FLOAT);
-                gl::VertexFormatType defaultType =
-                    gl::GetVertexFormatType(componentType, GL_FALSE, components, pureInt);
+                angle::FormatID defaultID =
+                    gl::GetVertexFormatID(componentType, GL_FALSE, components, pureInt);
 
-                inputLayoutOut->push_back(defaultType);
+                inputLayoutOut->push_back(defaultID);
             }
         }
     }
@@ -502,15 +502,15 @@
 
     for (size_t index = 0; index < inputLayout.size(); ++index)
     {
-        gl::VertexFormatType vertexFormatType = inputLayout[index];
-        if (vertexFormatType == gl::VERTEX_FORMAT_INVALID)
+        angle::FormatID vertexFormatID = inputLayout[index];
+        if (vertexFormatID == angle::FormatID::NONE)
             continue;
 
-        VertexConversionType conversionType = renderer->getVertexConversionType(vertexFormatType);
+        VertexConversionType conversionType = renderer->getVertexConversionType(vertexFormatID);
         if ((conversionType & VERTEX_CONVERT_GPU) == 0)
             continue;
 
-        GLenum componentType   = renderer->getVertexComponentType(vertexFormatType);
+        GLenum componentType   = renderer->getVertexComponentType(vertexFormatID);
         (*signatureOut)[index] = GetAttribType(componentType);
     }
 }
@@ -928,11 +928,11 @@
          vertexShaderIndex++)
     {
         size_t inputLayoutSize = stream->readInt<size_t>();
-        gl::InputLayout inputLayout(inputLayoutSize, gl::VERTEX_FORMAT_INVALID);
+        gl::InputLayout inputLayout(inputLayoutSize, angle::FormatID::NONE);
 
         for (size_t inputIndex = 0; inputIndex < inputLayoutSize; inputIndex++)
         {
-            inputLayout[inputIndex] = stream->readInt<gl::VertexFormatType>();
+            inputLayout[inputIndex] = stream->readInt<angle::FormatID>();
         }
 
         unsigned int vertexShaderSize             = stream->readInt<unsigned int>();
@@ -2729,11 +2729,11 @@
         {
             if (mCachedInputLayout.size() < static_cast<size_t>(d3dSemantic + 1))
             {
-                mCachedInputLayout.resize(d3dSemantic + 1, gl::VERTEX_FORMAT_INVALID);
+                mCachedInputLayout.resize(d3dSemantic + 1, angle::FormatID::NONE);
             }
             mCachedInputLayout[d3dSemantic] =
-                GetVertexFormatType(vertexAttributes[locationIndex],
-                                    state.getVertexAttribCurrentValue(locationIndex).Type);
+                GetVertexFormatID(vertexAttributes[locationIndex],
+                                  state.getVertexAttribCurrentValue(locationIndex).Type);
         }
     }
 
diff --git a/src/libANGLE/renderer/d3d/RendererD3D.h b/src/libANGLE/renderer/d3d/RendererD3D.h
index 46e0e1c..50f67c4 100644
--- a/src/libANGLE/renderer/d3d/RendererD3D.h
+++ b/src/libANGLE/renderer/d3d/RendererD3D.h
@@ -127,9 +127,8 @@
     virtual IndexBuffer *createIndexBuffer()   = 0;
 
     // TODO(jmadill): add VertexFormatCaps
-    virtual VertexConversionType getVertexConversionType(
-        gl::VertexFormatType vertexFormatType) const                                   = 0;
-    virtual GLenum getVertexComponentType(gl::VertexFormatType vertexFormatType) const = 0;
+    virtual VertexConversionType getVertexConversionType(angle::FormatID vertexFormatID) const = 0;
+    virtual GLenum getVertexComponentType(angle::FormatID vertexFormatID) const                = 0;
 
     // Warning: you should ensure binding really matches attrib.bindingIndex before using this
     // function.
diff --git a/src/libANGLE/renderer/d3d/VertexDataManager.cpp b/src/libANGLE/renderer/d3d/VertexDataManager.cpp
index 7a6d611..888e644 100644
--- a/src/libANGLE/renderer/d3d/VertexDataManager.cpp
+++ b/src/libANGLE/renderer/d3d/VertexDataManager.cpp
@@ -86,10 +86,10 @@
     // TODO(jmadill): add VertexFormatCaps
     BufferFactoryD3D *factory = bufferD3D->getFactory();
 
-    gl::VertexFormatType vertexFormatType = gl::GetVertexFormatType(attrib);
+    angle::FormatID vertexFormatID = gl::GetVertexFormatID(attrib);
 
     // CPU-converted vertex data must be converted (naturally).
-    if ((factory->getVertexConversionType(vertexFormatType) & VERTEX_CONVERT_CPU) != 0)
+    if ((factory->getVertexConversionType(vertexFormatID) & VERTEX_CONVERT_CPU) != 0)
     {
         return false;
     }
diff --git a/src/libANGLE/renderer/d3d/d3d11/InputLayoutCache.cpp b/src/libANGLE/renderer/d3d/d3d11/InputLayoutCache.cpp
index f79a5e6..8874b41 100644
--- a/src/libANGLE/renderer/d3d/d3d11/InputLayoutCache.cpp
+++ b/src/libANGLE/renderer/d3d/d3d11/InputLayoutCache.cpp
@@ -73,7 +73,7 @@
 
 void PackedAttributeLayout::addAttributeData(GLenum glType,
                                              UINT semanticIndex,
-                                             gl::VertexFormatType vertexFormatType,
+                                             angle::FormatID vertexFormatID,
                                              unsigned int divisor)
 {
     gl::AttributeType attribType = gl::GetAttributeType(glType);
@@ -81,13 +81,13 @@
     PackedAttribute packedAttrib;
     packedAttrib.attribType       = static_cast<uint8_t>(attribType);
     packedAttrib.semanticIndex    = static_cast<uint8_t>(semanticIndex);
-    packedAttrib.vertexFormatType = static_cast<uint8_t>(vertexFormatType);
+    packedAttrib.vertexFormatType = static_cast<uint8_t>(vertexFormatID);
     packedAttrib.dummyPadding     = 0u;
     packedAttrib.divisor          = static_cast<uint32_t>(divisor);
 
     ASSERT(static_cast<gl::AttributeType>(packedAttrib.attribType) == attribType);
     ASSERT(static_cast<UINT>(packedAttrib.semanticIndex) == semanticIndex);
-    ASSERT(static_cast<gl::VertexFormatType>(packedAttrib.vertexFormatType) == vertexFormatType);
+    ASSERT(static_cast<angle::FormatID>(packedAttrib.vertexFormatType) == vertexFormatID);
     ASSERT(static_cast<unsigned int>(packedAttrib.divisor) == divisor);
 
     static_assert(sizeof(uint64_t) == sizeof(PackedAttribute),
@@ -165,9 +165,9 @@
 
         const auto &currentValue =
             state.getVertexAttribCurrentValue(static_cast<unsigned int>(attribIndex));
-        gl::VertexFormatType vertexFormatType = gl::GetVertexFormatType(attrib, currentValue.Type);
+        angle::FormatID vertexFormatID = gl::GetVertexFormatID(attrib, currentValue.Type);
 
-        layout.addAttributeData(glslElementType, d3dSemantic, vertexFormatType,
+        layout.addAttributeData(glslElementType, d3dSemantic, vertexFormatID,
                                 binding.getDivisor() * divisorMultiplier);
     }
 
@@ -220,9 +220,9 @@
         D3D11_INPUT_CLASSIFICATION inputClass =
             attrib.divisor > 0 ? D3D11_INPUT_PER_INSTANCE_DATA : D3D11_INPUT_PER_VERTEX_DATA;
 
-        const auto &vertexFormatType =
-            gl::GetVertexFormatType(*attrib.attribute, attrib.currentValueType);
-        const auto &vertexFormatInfo = d3d11::GetVertexFormatInfo(vertexFormatType, featureLevel);
+        angle::FormatID vertexFormatID =
+            gl::GetVertexFormatID(*attrib.attribute, attrib.currentValueType);
+        const auto &vertexFormatInfo = d3d11::GetVertexFormatInfo(vertexFormatID, featureLevel);
 
         auto *inputElement = &inputElements[inputElementCount];
 
diff --git a/src/libANGLE/renderer/d3d/d3d11/InputLayoutCache.h b/src/libANGLE/renderer/d3d/d3d11/InputLayoutCache.h
index 4ba2366..7914667 100644
--- a/src/libANGLE/renderer/d3d/d3d11/InputLayoutCache.h
+++ b/src/libANGLE/renderer/d3d/d3d11/InputLayoutCache.h
@@ -34,7 +34,7 @@
 
     void addAttributeData(GLenum glType,
                           UINT semanticIndex,
-                          gl::VertexFormatType vertexFormatType,
+                          angle::FormatID vertexFormatID,
                           unsigned int divisor);
 
     bool operator==(const PackedAttributeLayout &other) const;
diff --git a/src/libANGLE/renderer/d3d/d3d11/Renderer11.cpp b/src/libANGLE/renderer/d3d/d3d11/Renderer11.cpp
index 853bd77..1f9a066 100644
--- a/src/libANGLE/renderer/d3d/d3d11/Renderer11.cpp
+++ b/src/libANGLE/renderer/d3d/d3d11/Renderer11.cpp
@@ -3595,17 +3595,16 @@
     return true;
 }
 
-VertexConversionType Renderer11::getVertexConversionType(
-    gl::VertexFormatType vertexFormatType) const
+VertexConversionType Renderer11::getVertexConversionType(angle::FormatID vertexFormatID) const
 {
-    return d3d11::GetVertexFormatInfo(vertexFormatType, mRenderer11DeviceCaps.featureLevel)
+    return d3d11::GetVertexFormatInfo(vertexFormatID, mRenderer11DeviceCaps.featureLevel)
         .conversionType;
 }
 
-GLenum Renderer11::getVertexComponentType(gl::VertexFormatType vertexFormatType) const
+GLenum Renderer11::getVertexComponentType(angle::FormatID vertexFormatID) const
 {
     const auto &format =
-        d3d11::GetVertexFormatInfo(vertexFormatType, mRenderer11DeviceCaps.featureLevel);
+        d3d11::GetVertexFormatInfo(vertexFormatID, mRenderer11DeviceCaps.featureLevel);
     return d3d11::GetComponentType(format.nativeFormat);
 }
 
@@ -3637,10 +3636,10 @@
 
     ASSERT(elementCount > 0);
 
-    gl::VertexFormatType formatType      = gl::GetVertexFormatType(attrib);
+    angle::FormatID formatID             = gl::GetVertexFormatID(attrib);
     const D3D_FEATURE_LEVEL featureLevel = mRenderer11DeviceCaps.featureLevel;
     const d3d11::VertexFormat &vertexFormatInfo =
-        d3d11::GetVertexFormatInfo(formatType, featureLevel);
+        d3d11::GetVertexFormatInfo(formatID, featureLevel);
     const d3d11::DXGIFormatSize &dxgiFormatInfo =
         d3d11::GetDXGIFormatSizeInfo(vertexFormatInfo.nativeFormat);
     unsigned int elementSize = dxgiFormatInfo.pixelBytes;
diff --git a/src/libANGLE/renderer/d3d/d3d11/Renderer11.h b/src/libANGLE/renderer/d3d/d3d11/Renderer11.h
index e668a3c..a8170e3 100644
--- a/src/libANGLE/renderer/d3d/d3d11/Renderer11.h
+++ b/src/libANGLE/renderer/d3d/d3d11/Renderer11.h
@@ -355,9 +355,8 @@
                              uint8_t *pixelsOut);
 
     bool getLUID(LUID *adapterLuid) const override;
-    VertexConversionType getVertexConversionType(
-        gl::VertexFormatType vertexFormatType) const override;
-    GLenum getVertexComponentType(gl::VertexFormatType vertexFormatType) const override;
+    VertexConversionType getVertexConversionType(angle::FormatID vertexFormatID) const override;
+    GLenum getVertexComponentType(angle::FormatID vertexFormatID) const override;
 
     // Warning: you should ensure binding really matches attrib.bindingIndex before using this
     // function.
diff --git a/src/libANGLE/renderer/d3d/d3d11/VertexBuffer11.cpp b/src/libANGLE/renderer/d3d/d3d11/VertexBuffer11.cpp
index 234cd36..e4a5677 100644
--- a/src/libANGLE/renderer/d3d/d3d11/VertexBuffer11.cpp
+++ b/src/libANGLE/renderer/d3d/d3d11/VertexBuffer11.cpp
@@ -122,10 +122,10 @@
         input += inputStride * start;
     }
 
-    gl::VertexFormatType vertexFormatType = gl::GetVertexFormatType(attrib, currentValueType);
+    angle::FormatID vertexFormatID        = gl::GetVertexFormatID(attrib, currentValueType);
     const D3D_FEATURE_LEVEL featureLevel  = mRenderer->getRenderer11DeviceCaps().featureLevel;
     const d3d11::VertexFormat &vertexFormatInfo =
-        d3d11::GetVertexFormatInfo(vertexFormatType, featureLevel);
+        d3d11::GetVertexFormatInfo(vertexFormatID, featureLevel);
     ASSERT(vertexFormatInfo.copyFunction != nullptr);
     vertexFormatInfo.copyFunction(input, inputStride, count, output);
 
diff --git a/src/libANGLE/renderer/d3d/d3d11/formatutils11.cpp b/src/libANGLE/renderer/d3d/d3d11/formatutils11.cpp
index ec2fdfa..85185c1 100644
--- a/src/libANGLE/renderer/d3d/d3d11/formatutils11.cpp
+++ b/src/libANGLE/renderer/d3d/d3d11/formatutils11.cpp
@@ -211,34 +211,34 @@
 {
 }
 
-const VertexFormat *GetVertexFormatInfo_FL_9_3(gl::VertexFormatType vertexFormatType)
+const VertexFormat *GetVertexFormatInfo_FL_9_3(angle::FormatID vertexFormatID)
 {
     // D3D11 Feature Level 9_3 doesn't support as many formats for vertex buffer resource as Feature
     // Level 10_0+.
     // http://msdn.microsoft.com/en-us/library/windows/desktop/ff471324(v=vs.85).aspx
 
-    switch (vertexFormatType)
+    switch (vertexFormatID)
     {
         // GL_BYTE -- unnormalized
-        case gl::VERTEX_FORMAT_SBYTE1:
+        case angle::FormatID::R8_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_BOTH, DXGI_FORMAT_R16G16_SINT,
                                                &Copy8SintTo16SintVertexData<1, 2>);
             return &info;
         }
-        case gl::VERTEX_FORMAT_SBYTE2:
+        case angle::FormatID::R8G8_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_BOTH, DXGI_FORMAT_R16G16_SINT,
                                                &Copy8SintTo16SintVertexData<2, 2>);
             return &info;
         }
-        case gl::VERTEX_FORMAT_SBYTE3:
+        case angle::FormatID::R8G8B8_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_BOTH, DXGI_FORMAT_R16G16B16A16_SINT,
                                                &Copy8SintTo16SintVertexData<3, 4>);
             return &info;
         }
-        case gl::VERTEX_FORMAT_SBYTE4:
+        case angle::FormatID::R8G8B8A8_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_BOTH, DXGI_FORMAT_R16G16B16A16_SINT,
                                                &Copy8SintTo16SintVertexData<4, 4>);
@@ -246,25 +246,25 @@
         }
 
         // GL_BYTE -- normalized
-        case gl::VERTEX_FORMAT_SBYTE1_NORM:
+        case angle::FormatID::R8_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R16G16_SNORM,
                                                &Copy8SnormTo16SnormVertexData<1, 2>);
             return &info;
         }
-        case gl::VERTEX_FORMAT_SBYTE2_NORM:
+        case angle::FormatID::R8G8_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R16G16_SNORM,
                                                &Copy8SnormTo16SnormVertexData<2, 2>);
             return &info;
         }
-        case gl::VERTEX_FORMAT_SBYTE3_NORM:
+        case angle::FormatID::R8G8B8_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R16G16B16A16_SNORM,
                                                &Copy8SnormTo16SnormVertexData<3, 4>);
             return &info;
         }
-        case gl::VERTEX_FORMAT_SBYTE4_NORM:
+        case angle::FormatID::R8G8B8A8_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R16G16B16A16_SNORM,
                                                &Copy8SnormTo16SnormVertexData<4, 4>);
@@ -274,13 +274,13 @@
         // GL_UNSIGNED_BYTE -- un-normalized
         // NOTE: 3 and 4 component unnormalized GL_UNSIGNED_BYTE should use the default format
         // table.
-        case gl::VERTEX_FORMAT_UBYTE1:
+        case angle::FormatID::R8_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_BOTH, DXGI_FORMAT_R8G8B8A8_UINT,
                                                &CopyNativeVertexData<GLubyte, 1, 4, 1>);
             return &info;
         }
-        case gl::VERTEX_FORMAT_UBYTE2:
+        case angle::FormatID::R8G8_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_BOTH, DXGI_FORMAT_R8G8B8A8_UINT,
                                                &CopyNativeVertexData<GLubyte, 2, 4, 1>);
@@ -291,13 +291,13 @@
         // NOTE: 3 and 4 component normalized GL_UNSIGNED_BYTE should use the default format table.
 
         // GL_UNSIGNED_BYTE -- normalized
-        case gl::VERTEX_FORMAT_UBYTE1_NORM:
+        case angle::FormatID::R8_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R8G8B8A8_UNORM,
                                                &CopyNativeVertexData<GLubyte, 1, 4, UINT8_MAX>);
             return &info;
         }
-        case gl::VERTEX_FORMAT_UBYTE2_NORM:
+        case angle::FormatID::R8G8_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R8G8B8A8_UNORM,
                                                &CopyNativeVertexData<GLubyte, 2, 4, UINT8_MAX>);
@@ -306,7 +306,7 @@
 
         // GL_SHORT -- un-normalized
         // NOTE: 2, 3 and 4 component unnormalized GL_SHORT should use the default format table.
-        case gl::VERTEX_FORMAT_SSHORT1:
+        case angle::FormatID::R16_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_BOTH, DXGI_FORMAT_R16G16_SINT,
                                                &CopyNativeVertexData<GLshort, 1, 2, 0>);
@@ -315,7 +315,7 @@
 
         // GL_SHORT -- normalized
         // NOTE: 2, 3 and 4 component normalized GL_SHORT should use the default format table.
-        case gl::VERTEX_FORMAT_SSHORT1_NORM:
+        case angle::FormatID::R16_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R16G16_SNORM,
                                                &CopyNativeVertexData<GLshort, 1, 2, 0>);
@@ -323,25 +323,25 @@
         }
 
         // GL_UNSIGNED_SHORT -- un-normalized
-        case gl::VERTEX_FORMAT_USHORT1:
+        case angle::FormatID::R16_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32_FLOAT,
                                                &CopyTo32FVertexData<GLushort, 1, 2, false>);
             return &info;
         }
-        case gl::VERTEX_FORMAT_USHORT2:
+        case angle::FormatID::R16G16_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32_FLOAT,
                                                &CopyTo32FVertexData<GLushort, 2, 2, false>);
             return &info;
         }
-        case gl::VERTEX_FORMAT_USHORT3:
+        case angle::FormatID::R16G16B16_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32B32_FLOAT,
                                                &CopyTo32FVertexData<GLushort, 3, 3, false>);
             return &info;
         }
-        case gl::VERTEX_FORMAT_USHORT4:
+        case angle::FormatID::R16G16B16A16_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32B32A32_FLOAT,
                                                &CopyTo32FVertexData<GLushort, 4, 4, false>);
@@ -349,25 +349,25 @@
         }
 
         // GL_UNSIGNED_SHORT -- normalized
-        case gl::VERTEX_FORMAT_USHORT1_NORM:
+        case angle::FormatID::R16_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32_FLOAT,
                                                &CopyTo32FVertexData<GLushort, 1, 2, true>);
             return &info;
         }
-        case gl::VERTEX_FORMAT_USHORT2_NORM:
+        case angle::FormatID::R16G16_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32_FLOAT,
                                                &CopyTo32FVertexData<GLushort, 2, 2, true>);
             return &info;
         }
-        case gl::VERTEX_FORMAT_USHORT3_NORM:
+        case angle::FormatID::R16G16B16_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32B32_FLOAT,
                                                &CopyTo32FVertexData<GLushort, 3, 3, true>);
             return &info;
         }
-        case gl::VERTEX_FORMAT_USHORT4_NORM:
+        case angle::FormatID::R16G16B16A16_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32B32A32_FLOAT,
                                                &CopyTo32FVertexData<GLushort, 4, 4, true>);
@@ -377,7 +377,7 @@
         // GL_FIXED
         // TODO: Add test to verify that this works correctly.
         // NOTE: 2, 3 and 4 component GL_FIXED should use the default format table.
-        case gl::VERTEX_FORMAT_FIXED1:
+        case angle::FormatID::R32_FIXED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32_FLOAT,
                                                &Copy32FixedTo32FVertexData<1, 2>);
@@ -387,7 +387,7 @@
         // GL_FLOAT
         // TODO: Add test to verify that this works correctly.
         // NOTE: 2, 3 and 4 component GL_FLOAT should use the default format table.
-        case gl::VERTEX_FORMAT_FLOAT1:
+        case angle::FormatID::R32_FLOAT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32_FLOAT,
                                                &CopyNativeVertexData<GLfloat, 1, 2, 0>);
@@ -399,43 +399,44 @@
     }
 }
 
-const VertexFormat &GetVertexFormatInfo(gl::VertexFormatType vertexFormatType, D3D_FEATURE_LEVEL featureLevel)
+const VertexFormat &GetVertexFormatInfo(angle::FormatID vertexFormatID,
+                                        D3D_FEATURE_LEVEL featureLevel)
 {
     if (featureLevel == D3D_FEATURE_LEVEL_9_3)
     {
-        const VertexFormat *result = GetVertexFormatInfo_FL_9_3(vertexFormatType);
+        const VertexFormat *result = GetVertexFormatInfo_FL_9_3(vertexFormatID);
         if (result)
         {
             return *result;
         }
     }
 
-    switch (vertexFormatType)
+    switch (vertexFormatID)
     {
         //
         // Float formats
         //
 
         // GL_BYTE -- un-normalized
-        case gl::VERTEX_FORMAT_SBYTE1:
+        case angle::FormatID::R8_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R8_SINT,
                                                &CopyNativeVertexData<GLbyte, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SBYTE2:
+        case angle::FormatID::R8G8_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R8G8_SINT,
                                                &CopyNativeVertexData<GLbyte, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SBYTE3:
+        case angle::FormatID::R8G8B8_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_BOTH, DXGI_FORMAT_R8G8B8A8_SINT,
                                                &CopyNativeVertexData<GLbyte, 3, 4, 1>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SBYTE4:
+        case angle::FormatID::R8G8B8A8_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R8G8B8A8_SINT,
                                                &CopyNativeVertexData<GLbyte, 4, 4, 0>);
@@ -443,25 +444,25 @@
         }
 
         // GL_BYTE -- normalized
-        case gl::VERTEX_FORMAT_SBYTE1_NORM:
+        case angle::FormatID::R8_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R8_SNORM,
                                                &CopyNativeVertexData<GLbyte, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SBYTE2_NORM:
+        case angle::FormatID::R8G8_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R8G8_SNORM,
                                                &CopyNativeVertexData<GLbyte, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SBYTE3_NORM:
+        case angle::FormatID::R8G8B8_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R8G8B8A8_SNORM,
                                                &CopyNativeVertexData<GLbyte, 3, 4, INT8_MAX>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SBYTE4_NORM:
+        case angle::FormatID::R8G8B8A8_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R8G8B8A8_SNORM,
                                                &CopyNativeVertexData<GLbyte, 4, 4, 0>);
@@ -469,25 +470,25 @@
         }
 
         // GL_UNSIGNED_BYTE -- un-normalized
-        case gl::VERTEX_FORMAT_UBYTE1:
+        case angle::FormatID::R8_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R8_UINT,
                                                &CopyNativeVertexData<GLubyte, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UBYTE2:
+        case angle::FormatID::R8G8_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R8G8_UINT,
                                                &CopyNativeVertexData<GLubyte, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UBYTE3:
+        case angle::FormatID::R8G8B8_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_BOTH, DXGI_FORMAT_R8G8B8A8_UINT,
                                                &CopyNativeVertexData<GLubyte, 3, 4, 1>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UBYTE4:
+        case angle::FormatID::R8G8B8A8_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R8G8B8A8_UINT,
                                                &CopyNativeVertexData<GLubyte, 4, 4, 0>);
@@ -495,25 +496,25 @@
         }
 
         // GL_UNSIGNED_BYTE -- normalized
-        case gl::VERTEX_FORMAT_UBYTE1_NORM:
+        case angle::FormatID::R8_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R8_UNORM,
                                                &CopyNativeVertexData<GLubyte, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UBYTE2_NORM:
+        case angle::FormatID::R8G8_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R8G8_UNORM,
                                                &CopyNativeVertexData<GLubyte, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UBYTE3_NORM:
+        case angle::FormatID::R8G8B8_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R8G8B8A8_UNORM,
                                                &CopyNativeVertexData<GLubyte, 3, 4, UINT8_MAX>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UBYTE4_NORM:
+        case angle::FormatID::R8G8B8A8_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R8G8B8A8_UNORM,
                                                &CopyNativeVertexData<GLubyte, 4, 4, 0>);
@@ -521,25 +522,25 @@
         }
 
         // GL_SHORT -- un-normalized
-        case gl::VERTEX_FORMAT_SSHORT1:
+        case angle::FormatID::R16_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R16_SINT,
                                                &CopyNativeVertexData<GLshort, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SSHORT2:
+        case angle::FormatID::R16G16_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R16G16_SINT,
                                                &CopyNativeVertexData<GLshort, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SSHORT3:
+        case angle::FormatID::R16G16B16_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_BOTH, DXGI_FORMAT_R16G16B16A16_SINT,
                                                &CopyNativeVertexData<GLshort, 3, 4, 1>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SSHORT4:
+        case angle::FormatID::R16G16B16A16_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R16G16B16A16_SINT,
                                                &CopyNativeVertexData<GLshort, 4, 4, 0>);
@@ -547,25 +548,25 @@
         }
 
         // GL_SHORT -- normalized
-        case gl::VERTEX_FORMAT_SSHORT1_NORM:
+        case angle::FormatID::R16_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R16_SNORM,
                                                &CopyNativeVertexData<GLshort, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SSHORT2_NORM:
+        case angle::FormatID::R16G16_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R16G16_SNORM,
                                                &CopyNativeVertexData<GLshort, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SSHORT3_NORM:
+        case angle::FormatID::R16G16B16_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R16G16B16A16_SNORM,
                                                &CopyNativeVertexData<GLshort, 3, 4, INT16_MAX>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SSHORT4_NORM:
+        case angle::FormatID::R16G16B16A16_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R16G16B16A16_SNORM,
                                                &CopyNativeVertexData<GLshort, 4, 4, 0>);
@@ -573,25 +574,25 @@
         }
 
         // GL_UNSIGNED_SHORT -- un-normalized
-        case gl::VERTEX_FORMAT_USHORT1:
+        case angle::FormatID::R16_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R16_UINT,
                                                &CopyNativeVertexData<GLushort, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_USHORT2:
+        case angle::FormatID::R16G16_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R16G16_UINT,
                                                &CopyNativeVertexData<GLushort, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_USHORT3:
+        case angle::FormatID::R16G16B16_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_BOTH, DXGI_FORMAT_R16G16B16A16_UINT,
                                                &CopyNativeVertexData<GLushort, 3, 4, 1>);
             return info;
         }
-        case gl::VERTEX_FORMAT_USHORT4:
+        case angle::FormatID::R16G16B16A16_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R16G16B16A16_UINT,
                                                &CopyNativeVertexData<GLushort, 4, 4, 0>);
@@ -599,25 +600,25 @@
         }
 
         // GL_UNSIGNED_SHORT -- normalized
-        case gl::VERTEX_FORMAT_USHORT1_NORM:
+        case angle::FormatID::R16_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R16_UNORM,
                                                &CopyNativeVertexData<GLushort, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_USHORT2_NORM:
+        case angle::FormatID::R16G16_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R16G16_UNORM,
                                                &CopyNativeVertexData<GLushort, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_USHORT3_NORM:
+        case angle::FormatID::R16G16B16_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R16G16B16A16_UNORM,
                                                &CopyNativeVertexData<GLushort, 3, 4, UINT16_MAX>);
             return info;
         }
-        case gl::VERTEX_FORMAT_USHORT4_NORM:
+        case angle::FormatID::R16G16B16A16_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R16G16B16A16_UNORM,
                                                &CopyNativeVertexData<GLushort, 4, 4, 0>);
@@ -625,25 +626,25 @@
         }
 
         // GL_INT -- un-normalized
-        case gl::VERTEX_FORMAT_SINT1:
+        case angle::FormatID::R32_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R32_SINT,
                                                &CopyNativeVertexData<GLint, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SINT2:
+        case angle::FormatID::R32G32_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R32G32_SINT,
                                                &CopyNativeVertexData<GLint, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SINT3:
+        case angle::FormatID::R32G32B32_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R32G32B32_SINT,
                                                &CopyNativeVertexData<GLint, 3, 3, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SINT4:
+        case angle::FormatID::R32G32B32A32_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R32G32B32A32_SINT,
                                                &CopyNativeVertexData<GLint, 4, 4, 0>);
@@ -651,25 +652,25 @@
         }
 
         // GL_INT -- normalized
-        case gl::VERTEX_FORMAT_SINT1_NORM:
+        case angle::FormatID::R32_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32_FLOAT,
                                                &CopyTo32FVertexData<GLint, 1, 1, true>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SINT2_NORM:
+        case angle::FormatID::R32G32_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32_FLOAT,
                                                &CopyTo32FVertexData<GLint, 2, 2, true>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SINT3_NORM:
+        case angle::FormatID::R32G32B32_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32B32_FLOAT,
                                                &CopyTo32FVertexData<GLint, 3, 3, true>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SINT4_NORM:
+        case angle::FormatID::R32G32B32A32_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32B32A32_FLOAT,
                                                &CopyTo32FVertexData<GLint, 4, 4, true>);
@@ -677,25 +678,25 @@
         }
 
         // GL_UNSIGNED_INT -- un-normalized
-        case gl::VERTEX_FORMAT_UINT1:
+        case angle::FormatID::R32_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R32_UINT,
                                                &CopyNativeVertexData<GLuint, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UINT2:
+        case angle::FormatID::R32G32_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R32G32_UINT,
                                                &CopyNativeVertexData<GLuint, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UINT3:
+        case angle::FormatID::R32G32B32_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R32G32B32_UINT,
                                                &CopyNativeVertexData<GLuint, 3, 3, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UINT4:
+        case angle::FormatID::R32G32B32A32_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_GPU, DXGI_FORMAT_R32G32B32A32_UINT,
                                                &CopyNativeVertexData<GLuint, 4, 4, 0>);
@@ -703,25 +704,25 @@
         }
 
         // GL_UNSIGNED_INT -- normalized
-        case gl::VERTEX_FORMAT_UINT1_NORM:
+        case angle::FormatID::R32_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32_FLOAT,
                                                &CopyTo32FVertexData<GLuint, 1, 1, true>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UINT2_NORM:
+        case angle::FormatID::R32G32_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32_FLOAT,
                                                &CopyTo32FVertexData<GLuint, 2, 2, true>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UINT3_NORM:
+        case angle::FormatID::R32G32B32_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32B32_FLOAT,
                                                &CopyTo32FVertexData<GLuint, 3, 3, true>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UINT4_NORM:
+        case angle::FormatID::R32G32B32A32_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32B32A32_FLOAT,
                                                &CopyTo32FVertexData<GLuint, 4, 4, true>);
@@ -729,25 +730,25 @@
         }
 
         // GL_FIXED
-        case gl::VERTEX_FORMAT_FIXED1:
+        case angle::FormatID::R32_FIXED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32_FLOAT,
                                                &Copy32FixedTo32FVertexData<1, 1>);
             return info;
         }
-        case gl::VERTEX_FORMAT_FIXED2:
+        case angle::FormatID::R32G32_FIXED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32_FLOAT,
                                                &Copy32FixedTo32FVertexData<2, 2>);
             return info;
         }
-        case gl::VERTEX_FORMAT_FIXED3:
+        case angle::FormatID::R32G32B32_FIXED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32B32_FLOAT,
                                                &Copy32FixedTo32FVertexData<3, 3>);
             return info;
         }
-        case gl::VERTEX_FORMAT_FIXED4:
+        case angle::FormatID::R32G32B32A32_FIXED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32B32A32_FLOAT,
                                                &Copy32FixedTo32FVertexData<4, 4>);
@@ -755,25 +756,25 @@
         }
 
         // GL_HALF_FLOAT
-        case gl::VERTEX_FORMAT_HALF1:
+        case angle::FormatID::R16_FLOAT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R16_FLOAT,
                                                &CopyNativeVertexData<GLhalf, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_HALF2:
+        case angle::FormatID::R16G16_FLOAT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R16G16_FLOAT,
                                                &CopyNativeVertexData<GLhalf, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_HALF3:
+        case angle::FormatID::R16G16B16_FLOAT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R16G16B16A16_FLOAT,
                                                &CopyNativeVertexData<GLhalf, 3, 4, gl::Float16One>);
             return info;
         }
-        case gl::VERTEX_FORMAT_HALF4:
+        case angle::FormatID::R16G16B16A16_FLOAT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R16G16B16A16_FLOAT,
                                                &CopyNativeVertexData<GLhalf, 4, 4, 0>);
@@ -781,25 +782,25 @@
         }
 
         // GL_FLOAT
-        case gl::VERTEX_FORMAT_FLOAT1:
+        case angle::FormatID::R32_FLOAT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R32_FLOAT,
                                                &CopyNativeVertexData<GLfloat, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_FLOAT2:
+        case angle::FormatID::R32G32_FLOAT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R32G32_FLOAT,
                                                &CopyNativeVertexData<GLfloat, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_FLOAT3:
+        case angle::FormatID::R32G32B32_FLOAT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R32G32B32_FLOAT,
                                                &CopyNativeVertexData<GLfloat, 3, 3, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_FLOAT4:
+        case angle::FormatID::R32G32B32A32_FLOAT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R32G32B32A32_FLOAT,
                                                &CopyNativeVertexData<GLfloat, 4, 4, 0>);
@@ -807,13 +808,13 @@
         }
 
         // GL_INT_2_10_10_10_REV
-        case gl::VERTEX_FORMAT_SINT210:
+        case angle::FormatID::R10G10B10A2_SSCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32B32A32_FLOAT,
                                                &CopyXYZ10W2ToXYZW32FVertexData<true, false, true>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SINT210_NORM:
+        case angle::FormatID::R10G10B10A2_SNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32B32A32_FLOAT,
                                                &CopyXYZ10W2ToXYZW32FVertexData<true, true, true>);
@@ -821,13 +822,13 @@
         }
 
         // GL_UNSIGNED_INT_2_10_10_10_REV
-        case gl::VERTEX_FORMAT_UINT210:
+        case angle::FormatID::R10G10B10A2_USCALED:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R32G32B32A32_FLOAT,
                                                &CopyXYZ10W2ToXYZW32FVertexData<false, false, true>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UINT210_NORM:
+        case angle::FormatID::R10G10B10A2_UNORM:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R10G10B10A2_UNORM,
                                                &CopyNativeVertexData<GLuint, 1, 1, 0>);
@@ -839,25 +840,25 @@
         //
 
         // GL_BYTE
-        case gl::VERTEX_FORMAT_SBYTE1_INT:
+        case angle::FormatID::R8_SINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R8_SINT,
                                                &CopyNativeVertexData<GLbyte, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SBYTE2_INT:
+        case angle::FormatID::R8G8_SINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R8G8_SINT,
                                                &CopyNativeVertexData<GLbyte, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SBYTE3_INT:
+        case angle::FormatID::R8G8B8_SINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R8G8B8A8_SINT,
                                                &CopyNativeVertexData<GLbyte, 3, 4, 1>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SBYTE4_INT:
+        case angle::FormatID::R8G8B8A8_SINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R8G8B8A8_SINT,
                                                &CopyNativeVertexData<GLbyte, 4, 4, 0>);
@@ -865,25 +866,25 @@
         }
 
         // GL_UNSIGNED_BYTE
-        case gl::VERTEX_FORMAT_UBYTE1_INT:
+        case angle::FormatID::R8_UINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R8_UINT,
                                                &CopyNativeVertexData<GLubyte, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UBYTE2_INT:
+        case angle::FormatID::R8G8_UINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R8G8_UINT,
                                                &CopyNativeVertexData<GLubyte, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UBYTE3_INT:
+        case angle::FormatID::R8G8B8_UINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R8G8B8A8_UINT,
                                                &CopyNativeVertexData<GLubyte, 3, 4, 1>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UBYTE4_INT:
+        case angle::FormatID::R8G8B8A8_UINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R8G8B8A8_UINT,
                                                &CopyNativeVertexData<GLubyte, 4, 4, 0>);
@@ -891,25 +892,25 @@
         }
 
         // GL_SHORT
-        case gl::VERTEX_FORMAT_SSHORT1_INT:
+        case angle::FormatID::R16_SINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R16_SINT,
                                                &CopyNativeVertexData<GLshort, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SSHORT2_INT:
+        case angle::FormatID::R16G16_SINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R16G16_SINT,
                                                &CopyNativeVertexData<GLshort, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SSHORT3_INT:
+        case angle::FormatID::R16G16B16_SINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R16G16B16A16_SINT,
                                                &CopyNativeVertexData<GLshort, 3, 4, 1>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SSHORT4_INT:
+        case angle::FormatID::R16G16B16A16_SINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R16G16B16A16_SINT,
                                                &CopyNativeVertexData<GLshort, 4, 4, 0>);
@@ -917,25 +918,25 @@
         }
 
         // GL_UNSIGNED_SHORT
-        case gl::VERTEX_FORMAT_USHORT1_INT:
+        case angle::FormatID::R16_UINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R16_UINT,
                                                &CopyNativeVertexData<GLushort, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_USHORT2_INT:
+        case angle::FormatID::R16G16_UINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R16G16_UINT,
                                                &CopyNativeVertexData<GLushort, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_USHORT3_INT:
+        case angle::FormatID::R16G16B16_UINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R16G16B16A16_UINT,
                                                &CopyNativeVertexData<GLushort, 3, 4, 1>);
             return info;
         }
-        case gl::VERTEX_FORMAT_USHORT4_INT:
+        case angle::FormatID::R16G16B16A16_UINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R16G16B16A16_UINT,
                                                &CopyNativeVertexData<GLushort, 4, 4, 0>);
@@ -943,25 +944,25 @@
         }
 
         // GL_INT
-        case gl::VERTEX_FORMAT_SINT1_INT:
+        case angle::FormatID::R32_SINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R32_SINT,
                                                &CopyNativeVertexData<GLint, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SINT2_INT:
+        case angle::FormatID::R32G32_SINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R32G32_SINT,
                                                &CopyNativeVertexData<GLint, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SINT3_INT:
+        case angle::FormatID::R32G32B32_SINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R32G32B32_SINT,
                                                &CopyNativeVertexData<GLint, 3, 3, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_SINT4_INT:
+        case angle::FormatID::R32G32B32A32_SINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R32G32B32A32_SINT,
                                                &CopyNativeVertexData<GLint, 4, 4, 0>);
@@ -969,25 +970,25 @@
         }
 
         // GL_UNSIGNED_INT
-        case gl::VERTEX_FORMAT_UINT1_INT:
+        case angle::FormatID::R32_UINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R32_SINT,
                                                &CopyNativeVertexData<GLuint, 1, 1, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UINT2_INT:
+        case angle::FormatID::R32G32_UINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R32G32_SINT,
                                                &CopyNativeVertexData<GLuint, 2, 2, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UINT3_INT:
+        case angle::FormatID::R32G32B32_UINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R32G32B32_SINT,
                                                &CopyNativeVertexData<GLuint, 3, 3, 0>);
             return info;
         }
-        case gl::VERTEX_FORMAT_UINT4_INT:
+        case angle::FormatID::R32G32B32A32_UINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R32G32B32A32_SINT,
                                                &CopyNativeVertexData<GLuint, 4, 4, 0>);
@@ -995,7 +996,7 @@
         }
 
         // GL_INT_2_10_10_10_REV
-        case gl::VERTEX_FORMAT_SINT210_INT:
+        case angle::FormatID::R10G10B10A2_SINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_CPU, DXGI_FORMAT_R16G16B16A16_SINT,
                                                &CopyXYZ10W2ToXYZW32FVertexData<true, true, false>);
@@ -1003,7 +1004,7 @@
         }
 
         // GL_UNSIGNED_INT_2_10_10_10_REV
-        case gl::VERTEX_FORMAT_UINT210_INT:
+        case angle::FormatID::R10G10B10A2_UINT:
         {
             static constexpr VertexFormat info(VERTEX_CONVERT_NONE, DXGI_FORMAT_R10G10B10A2_UINT,
                                                &CopyNativeVertexData<GLuint, 1, 1, 0>);
diff --git a/src/libANGLE/renderer/d3d/d3d11/formatutils11.h b/src/libANGLE/renderer/d3d/d3d11/formatutils11.h
index 04c99fc..58b6238 100644
--- a/src/libANGLE/renderer/d3d/d3d11/formatutils11.h
+++ b/src/libANGLE/renderer/d3d/d3d11/formatutils11.h
@@ -54,7 +54,7 @@
     VertexCopyFunction copyFunction;
 };
 
-const VertexFormat &GetVertexFormatInfo(gl::VertexFormatType vertexFormatType,
+const VertexFormat &GetVertexFormatInfo(angle::FormatID vertexFormatID,
                                         D3D_FEATURE_LEVEL featureLevel);
 
 // Auto-generated in dxgi_format_map_autogen.cpp.
diff --git a/src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp b/src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp
index f6d2c29..8e30ba5 100644
--- a/src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp
+++ b/src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp
@@ -2895,14 +2895,14 @@
     return false;
 }
 
-VertexConversionType Renderer9::getVertexConversionType(gl::VertexFormatType vertexFormatType) const
+VertexConversionType Renderer9::getVertexConversionType(angle::FormatID vertexFormatID) const
 {
-    return d3d9::GetVertexFormatInfo(getCapsDeclTypes(), vertexFormatType).conversionType;
+    return d3d9::GetVertexFormatInfo(getCapsDeclTypes(), vertexFormatID).conversionType;
 }
 
-GLenum Renderer9::getVertexComponentType(gl::VertexFormatType vertexFormatType) const
+GLenum Renderer9::getVertexComponentType(angle::FormatID vertexFormatID) const
 {
-    return d3d9::GetVertexFormatInfo(getCapsDeclTypes(), vertexFormatType).componentType;
+    return d3d9::GetVertexFormatInfo(getCapsDeclTypes(), vertexFormatID).componentType;
 }
 
 angle::Result Renderer9::getVertexSpaceRequired(const gl::Context *context,
@@ -2918,9 +2918,9 @@
         return angle::Result::Continue();
     }
 
-    gl::VertexFormatType vertexFormatType = gl::GetVertexFormatType(attrib, GL_FLOAT);
+    angle::FormatID vertexFormatID = gl::GetVertexFormatID(attrib, GL_FLOAT);
     const d3d9::VertexFormat &d3d9VertexInfo =
-        d3d9::GetVertexFormatInfo(getCapsDeclTypes(), vertexFormatType);
+        d3d9::GetVertexFormatInfo(getCapsDeclTypes(), vertexFormatID);
 
     unsigned int elementCount  = 0;
     const unsigned int divisor = binding.getDivisor();
diff --git a/src/libANGLE/renderer/d3d/d3d9/Renderer9.h b/src/libANGLE/renderer/d3d/d3d9/Renderer9.h
index 80f9193..ffe57ba 100644
--- a/src/libANGLE/renderer/d3d/d3d9/Renderer9.h
+++ b/src/libANGLE/renderer/d3d/d3d9/Renderer9.h
@@ -356,9 +356,8 @@
     D3DPOOL getTexturePool(DWORD usage) const;
 
     bool getLUID(LUID *adapterLuid) const override;
-    VertexConversionType getVertexConversionType(
-        gl::VertexFormatType vertexFormatType) const override;
-    GLenum getVertexComponentType(gl::VertexFormatType vertexFormatType) const override;
+    VertexConversionType getVertexConversionType(angle::FormatID vertexFormatID) const override;
+    GLenum getVertexComponentType(angle::FormatID vertexFormatID) const override;
 
     // Warning: you should ensure binding really matches attrib.bindingIndex before using this
     // function.
diff --git a/src/libANGLE/renderer/d3d/d3d9/VertexBuffer9.cpp b/src/libANGLE/renderer/d3d/d3d9/VertexBuffer9.cpp
index 491645a..a2ba863 100644
--- a/src/libANGLE/renderer/d3d/d3d9/VertexBuffer9.cpp
+++ b/src/libANGLE/renderer/d3d/d3d9/VertexBuffer9.cpp
@@ -90,8 +90,9 @@
         input += inputStride * start;
     }
 
-    gl::VertexFormatType vertexFormatType = gl::GetVertexFormatType(attrib, currentValueType);
-    const d3d9::VertexFormat &d3dVertexInfo = d3d9::GetVertexFormatInfo(mRenderer->getCapsDeclTypes(), vertexFormatType);
+    angle::FormatID vertexFormatID = gl::GetVertexFormatID(attrib, currentValueType);
+    const d3d9::VertexFormat &d3dVertexInfo =
+        d3d9::GetVertexFormatInfo(mRenderer->getCapsDeclTypes(), vertexFormatID);
     bool needsConversion = (d3dVertexInfo.conversionType & VERTEX_CONVERT_CPU) > 0;
 
     if (!needsConversion && inputStride == elementSize)
diff --git a/src/libANGLE/renderer/d3d/d3d9/VertexDeclarationCache.cpp b/src/libANGLE/renderer/d3d/d3d9/VertexDeclarationCache.cpp
index 9be9346..9fc35d8 100644
--- a/src/libANGLE/renderer/d3d/d3d9/VertexDeclarationCache.cpp
+++ b/src/libANGLE/renderer/d3d/d3d9/VertexDeclarationCache.cpp
@@ -168,9 +168,10 @@
                 mAppliedVBs[stream].offset = offset;
             }
 
-            gl::VertexFormatType vertexformatType =
-                gl::GetVertexFormatType(*attributes[i].attribute, GL_FLOAT);
-            const d3d9::VertexFormat &d3d9VertexInfo = d3d9::GetVertexFormatInfo(caps.DeclTypes, vertexformatType);
+            angle::FormatID vertexformatID =
+                gl::GetVertexFormatID(*attributes[i].attribute, GL_FLOAT);
+            const d3d9::VertexFormat &d3d9VertexInfo =
+                d3d9::GetVertexFormatInfo(caps.DeclTypes, vertexformatID);
 
             element->Stream = static_cast<WORD>(stream);
             element->Offset = 0;
diff --git a/src/libANGLE/renderer/d3d/d3d9/formatutils9.cpp b/src/libANGLE/renderer/d3d/d3d9/formatutils9.cpp
index 0236b0b..75aed41 100644
--- a/src/libANGLE/renderer/d3d/d3d9/formatutils9.cpp
+++ b/src/libANGLE/renderer/d3d/d3d9/formatutils9.cpp
@@ -872,8 +872,7 @@
     }
 }
 
-const VertexFormat &GetVertexFormatInfo(DWORD supportedDeclTypes,
-                                        gl::VertexFormatType vertexFormatType)
+const VertexFormat &GetVertexFormatInfo(DWORD supportedDeclTypes, angle::FormatID vertexFormatID)
 {
     static bool initialized           = false;
     static DWORD initializedDeclTypes = 0;
@@ -908,7 +907,7 @@
         initializedDeclTypes = supportedDeclTypes;
     }
 
-    const gl::VertexFormat &vertexFormat = gl::GetVertexFormatFromType(vertexFormatType);
+    const gl::VertexFormat &vertexFormat = gl::GetVertexFormatFromID(vertexFormatID);
 
     // Pure integer attributes only supported in ES3.0
     ASSERT(!vertexFormat.pureInteger);
diff --git a/src/libANGLE/renderer/d3d/d3d9/formatutils9.h b/src/libANGLE/renderer/d3d/d3d9/formatutils9.h
index c632d0d..2ae3d02 100644
--- a/src/libANGLE/renderer/d3d/d3d9/formatutils9.h
+++ b/src/libANGLE/renderer/d3d/d3d9/formatutils9.h
@@ -73,8 +73,7 @@
     D3DDECLTYPE nativeFormat;
     GLenum componentType;
 };
-const VertexFormat &GetVertexFormatInfo(DWORD supportedDeclTypes,
-                                        gl::VertexFormatType vertexFormatType);
+const VertexFormat &GetVertexFormatInfo(DWORD supportedDeclTypes, angle::FormatID vertexFormatID);
 
 struct TextureFormat
 {