From 1dad17ec7b25450731f728aa2ed235dffbb3fba4 Mon Sep 17 00:00:00 2001 From: baldurk Date: Sun, 31 Jul 2016 20:32:11 +0700 Subject: [PATCH] Use the resource format from the texture, with type hint, creating SRV --- renderdoc/driver/d3d12/d3d12_debug.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/renderdoc/driver/d3d12/d3d12_debug.cpp b/renderdoc/driver/d3d12/d3d12_debug.cpp index 06c60dbb4..2153c55f0 100644 --- a/renderdoc/driver/d3d12/d3d12_debug.cpp +++ b/renderdoc/driver/d3d12/d3d12_debug.cpp @@ -1550,7 +1550,7 @@ bool D3D12DebugManager::RenderTexture(TextureDisplay cfg, bool blendAlpha) D3D12_SHADER_RESOURCE_VIEW_DESC srvDesc; srvDesc.ViewDimension = D3D12_SRV_DIMENSION_TEXTURE2D; - srvDesc.Format = DXGI_FORMAT_R8G8B8A8_UNORM_SRGB; + srvDesc.Format = GetTypedFormat(resource->GetDesc().Format, cfg.typeHint); srvDesc.Shader4ComponentMapping = D3D12_DEFAULT_SHADER_4_COMPONENT_MAPPING; srvDesc.Texture2D.MipLevels = 1; srvDesc.Texture2D.MostDetailedMip = 0;