From c31b32382c9fcf2b79de4c642372fa21383692ab Mon Sep 17 00:00:00 2001 From: assiduous Date: Sun, 14 Feb 2021 19:22:08 -0800 Subject: PipelineResourceSignatureD3D12Impl: fixed issue with binding combined samplers --- .../GraphicsEngineD3D12/src/PipelineResourceSignatureD3D12Impl.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'Graphics/GraphicsEngineD3D12') diff --git a/Graphics/GraphicsEngineD3D12/src/PipelineResourceSignatureD3D12Impl.cpp b/Graphics/GraphicsEngineD3D12/src/PipelineResourceSignatureD3D12Impl.cpp index fe9f17f5..fd6dddf1 100644 --- a/Graphics/GraphicsEngineD3D12/src/PipelineResourceSignatureD3D12Impl.cpp +++ b/Graphics/GraphicsEngineD3D12/src/PipelineResourceSignatureD3D12Impl.cpp @@ -258,8 +258,6 @@ void PipelineResourceSignatureD3D12Impl::CreateLayout() { VERIFY_EXPR(ResDesc.ResourceType == SHADER_RESOURCE_TYPE_TEXTURE_SRV); SrcImmutableSamplerInd = ResourceToImmutableSamplerInd[AssignedSamplerInd]; - if (SrcImmutableSamplerInd >= 0) - AssignedSamplerInd = ResourceAttribs::InvalidSamplerInd; } const auto DescriptorRangeType = ResourceTypeToD3D12DescriptorRangeType(ResDesc.ResourceType); @@ -1563,8 +1561,7 @@ void BindResourceHelper::BindResource(IDeviceObject* pObj) const case SHADER_RESOURCE_TYPE_SAMPLER: //DEV_CHECK_ERR(Signature.IsUsingSeparateSamplers(), "Samplers should not be set directly when using combined texture samplers"); - if (Signature.IsUsingSeparateSamplers()) - CacheSampler(pObj); + CacheSampler(pObj); break; case SHADER_RESOURCE_TYPE_ACCEL_STRUCT: -- cgit v1.2.3