diff options
| author | Pokechu22 <Pokechu022@gmail.com> | 2022-04-22 12:50:44 -0700 |
|---|---|---|
| committer | Pokechu22 <Pokechu022@gmail.com> | 2022-04-22 16:54:36 -0700 |
| commit | 04fdadd9d5f9588055fb54571410febfa710b86d (patch) | |
| tree | 556444ad28b1c72d71364539a1f69722420ac50a /Source/Core/VideoBackends/D3D/D3DNativeVertexFormat.cpp | |
| parent | 88134a6786b102dbb9b473fa42d748ae9c64af91 (diff) | |
VideoCommon: Rename norm0/norm1/norm2 to normal/tangent/binormal
Diffstat (limited to 'Source/Core/VideoBackends/D3D/D3DNativeVertexFormat.cpp')
| -rw-r--r-- | Source/Core/VideoBackends/D3D/D3DNativeVertexFormat.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/Core/VideoBackends/D3D/D3DNativeVertexFormat.cpp b/Source/Core/VideoBackends/D3D/D3DNativeVertexFormat.cpp index b7aeab512c..b4da7fc354 100644 --- a/Source/Core/VideoBackends/D3D/D3DNativeVertexFormat.cpp +++ b/Source/Core/VideoBackends/D3D/D3DNativeVertexFormat.cpp @@ -115,11 +115,12 @@ D3DVertexFormat::D3DVertexFormat(const PortableVertexDeclaration& vtx_decl) for (int i = 0; i < 3; i++) { + static constexpr std::array<const char*, 3> NAMES = {"NORMAL", "TANGENT", "BINORMAL"}; format = &vtx_decl.normals[i]; if (format->enable) { - m_elems[m_num_elems].SemanticName = "NORMAL"; - m_elems[m_num_elems].SemanticIndex = i; + m_elems[m_num_elems].SemanticName = NAMES[i]; + m_elems[m_num_elems].SemanticIndex = 0; m_elems[m_num_elems].AlignedByteOffset = format->offset; m_elems[m_num_elems].Format = VarToD3D(format->type, format->components, format->integer); m_elems[m_num_elems].InputSlotClass = D3D11_INPUT_PER_VERTEX_DATA; |
