diff --git a/Graphics/GraphicsEngineD3D11/src/ShaderD3D11Impl.cpp b/Graphics/GraphicsEngineD3D11/src/ShaderD3D11Impl.cpp index 85bdfed6f..08b6d76d6 100644 --- a/Graphics/GraphicsEngineD3D11/src/ShaderD3D11Impl.cpp +++ b/Graphics/GraphicsEngineD3D11/src/ShaderD3D11Impl.cpp @@ -55,6 +55,7 @@ static const ShaderVersion HLSLValidateShaderVersion(const ShaderVersion& Versio static const ShaderVersion GetD3D11ShaderModel(D3D_FEATURE_LEVEL d3dDeviceFeatureLevel, const ShaderVersion& HLSLVersion) { #if defined(_MSC_VER) && !defined(NTDDI_WIN10_FE) +# pragma warning(push) # pragma warning(disable : 4063) #endif switch (d3dDeviceFeatureLevel) @@ -88,7 +89,7 @@ static const ShaderVersion GetD3D11ShaderModel(D3D_FEATURE_LEVEL d3dDeviceFeatur return ShaderVersion{4, 0}; } #if defined(_MSC_VER) && !defined(NTDDI_WIN10_FE) -# pragma warning(default : 4063) +# pragma warning(pop) #endif } diff --git a/Graphics/GraphicsEngineD3D12/src/RenderDeviceD3D12Impl.cpp b/Graphics/GraphicsEngineD3D12/src/RenderDeviceD3D12Impl.cpp index 542287ac1..2ccf7ae0c 100644 --- a/Graphics/GraphicsEngineD3D12/src/RenderDeviceD3D12Impl.cpp +++ b/Graphics/GraphicsEngineD3D12/src/RenderDeviceD3D12Impl.cpp @@ -177,6 +177,7 @@ RenderDeviceD3D12Impl::RenderDeviceD3D12Impl(IReferenceCounters* pRefCo auto FeatureLevel = GetD3DFeatureLevelFromDevice(m_pd3d12Device); #if defined(_MSC_VER) && !defined(NTDDI_WIN10_FE) +# pragma warning(push) # pragma warning(disable : 4063) #endif switch (FeatureLevel) @@ -191,7 +192,7 @@ RenderDeviceD3D12Impl::RenderDeviceD3D12Impl(IReferenceCounters* pRefCo default: UNEXPECTED("Unexpected D3D feature level"); } #if defined(_MSC_VER) && !defined(NTDDI_WIN10_FE) -# pragma warning(default : 4063) +# pragma warning(pop) #endif // Detect maximum shader model.