From 00a7a77aafa34b049d9bcebe9970ad2fa5df13c2 Mon Sep 17 00:00:00 2001 From: Chuck Walbourn Date: Wed, 10 Feb 2021 13:54:33 -0800 Subject: [PATCH] Minor -Wsign-conversion warning fix for d3dx12.h --- Src/d3dx12.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Src/d3dx12.h b/Src/d3dx12.h index ed0eec4..3bf9ac5 100644 --- a/Src/d3dx12.h +++ b/Src/d3dx12.h @@ -2024,11 +2024,11 @@ inline void MemcpySubresource( for (UINT z = 0; z < NumSlices; ++z) { auto pDestSlice = static_cast(pDest->pData) + pDest->SlicePitch * z; - auto pSrcSlice = (static_cast(pResourceData) + pSrc->Offset) + pSrc->DepthPitch * LONG_PTR(z); + auto pSrcSlice = (static_cast(pResourceData) + pSrc->Offset) + pSrc->DepthPitch * ULONG_PTR(z); for (UINT y = 0; y < NumRows; ++y) { memcpy(pDestSlice + pDest->RowPitch * y, - pSrcSlice + pSrc->RowPitch * LONG_PTR(y), + pSrcSlice + pSrc->RowPitch * ULONG_PTR(y), RowSizeInBytes); } }