diff --git a/tools/shaderc/shaderc_hlsl.cpp b/tools/shaderc/shaderc_hlsl.cpp index ed30c1e70..f3c54252c 100644 --- a/tools/shaderc/shaderc_hlsl.cpp +++ b/tools/shaderc/shaderc_hlsl.cpp @@ -513,7 +513,7 @@ namespace bgfx { namespace hlsl hr = reflect->GetResourceBindingDesc(ii, &bindDesc); if (SUCCEEDED(hr) ) { - if (D3D_SIT_SAMPLER == bindDesc.Type) + if (D3D_SIT_SAMPLER == bindDesc.Type || D3D_SIT_TEXTURE == bindDesc.Type) { BX_TRACE("\t%s, %d, %d, %d" , bindDesc.Name @@ -523,7 +523,10 @@ namespace bgfx { namespace hlsl ); bx::StringView end = bx::strFind(bindDesc.Name, "Sampler"); - if (!end.isEmpty() ) + if (end.isEmpty()) + end = bx::strFind(bindDesc.Name, "Texture"); + + if (!end.isEmpty()) { Uniform un; un.name.assign(bindDesc.Name, (end.getPtr() - bindDesc.Name) ); @@ -534,6 +537,10 @@ namespace bgfx { namespace hlsl _uniforms.push_back(un); } } + else + { + BX_TRACE("\t%s, unknown bind data", bindDesc.Name); + } } }