diff --git a/renderdoc/driver/d3d12/d3d12_shaderdebug.cpp b/renderdoc/driver/d3d12/d3d12_shaderdebug.cpp index 55926caa8..469034d51 100644 --- a/renderdoc/driver/d3d12/d3d12_shaderdebug.cpp +++ b/renderdoc/driver/d3d12/d3d12_shaderdebug.cpp @@ -276,6 +276,10 @@ bool D3D12ShaderDebug::CalculateSampleGather( }; cbufferData.debugSampleRetType = retTypes[resourceData.retType]; + if(cbufferData.debugSampleRetType == 0) + { + RDCERR("Unsupported return type %d in sample operation", resourceData.retType); + } cbufferData.debugSampleGatherChannel = (int)gatherChannel; cbufferData.debugSampleSampleIndex = multisampleIndex;