Add nearest-neighbor samplers for remaining backends

This commit is contained in:
Jack Andersen
2018-02-02 17:05:53 -10:00
parent 72c9809655
commit a2c3e14d8e
5 changed files with 27 additions and 6 deletions

View File

@@ -350,6 +350,12 @@ public:
sampDesc.AddressW = D3D11_TEXTURE_ADDRESS_CLAMP;
m_3dCtx.m_ctx11.m_dev->CreateSamplerState(&sampDesc, &m_3dCtx.m_ctx11.m_ss[2]);
sampDesc.AddressU = D3D11_TEXTURE_ADDRESS_CLAMP;
sampDesc.AddressV = D3D11_TEXTURE_ADDRESS_CLAMP;
sampDesc.AddressW = D3D11_TEXTURE_ADDRESS_CLAMP;
sampDesc.Filter = D3D11_FILTER_MIN_MAG_MIP_POINT;
m_3dCtx.m_ctx11.m_dev->CreateSamplerState(&sampDesc, &m_3dCtx.m_ctx11.m_ss[3]);
Log.report(logvisor::Info, "initialized D3D11 renderer");
return;
}

View File

@@ -66,7 +66,7 @@ struct D3D11Context
ComPtr<IDXGIFactory2> m_dxFactory;
ComPtr<ID3D11Device1> m_dev;
ComPtr<ID3D11DeviceContext1> m_devCtx;
ComPtr<ID3D11SamplerState> m_ss[3];
ComPtr<ID3D11SamplerState> m_ss[4];
struct Window
{
ComPtr<IDXGISwapChain1> m_swapChain;