@@ -74,7 +74,7 @@ namespace
7474
7575 if (length > 0 )
7676 {
77- auto const bytes = static_cast <DWORD>(sizeof (wchar_t ) * length);
77+ const auto bytes = static_cast <DWORD>(sizeof (wchar_t ) * length);
7878
7979 if (!WriteFile (hFile, value, bytes, &bytesWritten, nullptr ))
8080 return HRESULT_FROM_WIN32 (GetLastError ());
@@ -1084,7 +1084,7 @@ HRESULT Mesh::ExportToVBO(const wchar_t* szFileName) const noexcept
10841084 if (FAILED (hr))
10851085 return hr;
10861086
1087- auto const vertSize = static_cast <DWORD>(sizeof (vertex_t ) * header.numVertices );
1087+ const auto vertSize = static_cast <DWORD>(sizeof (vertex_t ) * header.numVertices );
10881088
10891089 DWORD bytesWritten;
10901090 if (!WriteFile (hFile.get (), vb.get (), vertSize, &bytesWritten, nullptr ))
@@ -1093,7 +1093,7 @@ HRESULT Mesh::ExportToVBO(const wchar_t* szFileName) const noexcept
10931093 if (bytesWritten != vertSize)
10941094 return E_FAIL;
10951095
1096- auto const indexSize = static_cast <DWORD>(sizeof (uint16_t ) * header.numIndices );
1096+ const auto indexSize = static_cast <DWORD>(sizeof (uint16_t ) * header.numIndices );
10971097
10981098 if (!WriteFile (hFile.get (), ib.get (), indexSize, &bytesWritten, nullptr ))
10991099 return HRESULT_FROM_WIN32 (GetLastError ());
@@ -1165,7 +1165,7 @@ HRESULT Mesh::CreateFromVBO(const wchar_t* szFileName, std::unique_ptr<Mesh>& re
11651165 if (!vb || !ib)
11661166 return E_OUTOFMEMORY;
11671167
1168- auto const vertSize = static_cast <DWORD>(sizeof (vertex_t ) * header.numVertices );
1168+ const auto vertSize = static_cast <DWORD>(sizeof (vertex_t ) * header.numVertices );
11691169
11701170 if (!ReadFile (hFile.get (), vb.get (), vertSize, &bytesRead, nullptr ))
11711171 {
@@ -1175,7 +1175,7 @@ HRESULT Mesh::CreateFromVBO(const wchar_t* szFileName, std::unique_ptr<Mesh>& re
11751175 if (bytesRead != vertSize)
11761176 return E_FAIL;
11771177
1178- auto const indexSize = static_cast <DWORD>(sizeof (uint16_t ) * header.numIndices );
1178+ const auto indexSize = static_cast <DWORD>(sizeof (uint16_t ) * header.numIndices );
11791179
11801180 if (!ReadFile (hFile.get (), ib.get (), indexSize, &bytesRead, nullptr ))
11811181 {
@@ -1660,7 +1660,7 @@ HRESULT Mesh::ExportToCMO(const wchar_t* szFileName, size_t nMaterials, const Ma
16601660 if (FAILED (hr))
16611661 return hr;
16621662
1663- auto const indexSize = static_cast <DWORD>(sizeof (uint16_t ) * nIndices);
1663+ const auto indexSize = static_cast <DWORD>(sizeof (uint16_t ) * nIndices);
16641664
16651665 DWORD bytesWritten;
16661666 if (!WriteFile (hFile.get (), ib.get (), indexSize, &bytesWritten, nullptr ))
@@ -1680,7 +1680,7 @@ HRESULT Mesh::ExportToCMO(const wchar_t* szFileName, size_t nMaterials, const Ma
16801680 if (FAILED (hr))
16811681 return hr;
16821682
1683- auto const vertSize = static_cast <DWORD>(sizeof (Vertex) * mnVerts);
1683+ const auto vertSize = static_cast <DWORD>(sizeof (Vertex) * mnVerts);
16841684
16851685 if (!WriteFile (hFile.get (), vb.get (), vertSize, &bytesWritten, nullptr ))
16861686 return HRESULT_FROM_WIN32 (GetLastError ());
@@ -1701,7 +1701,7 @@ HRESULT Mesh::ExportToCMO(const wchar_t* szFileName, size_t nMaterials, const Ma
17011701 if (FAILED (hr))
17021702 return hr;
17031703
1704- auto const skinVertSize = static_cast <DWORD>(sizeof (SkinningVertex) * mnVerts);
1704+ const auto skinVertSize = static_cast <DWORD>(sizeof (SkinningVertex) * mnVerts);
17051705
17061706 if (!WriteFile (hFile.get (), vbSkin.get (), skinVertSize, &bytesWritten, nullptr ))
17071707 return HRESULT_FROM_WIN32 (GetLastError ());
0 commit comments