diff --git a/spirv_hlsl.cpp b/spirv_hlsl.cpp index 5c885bd8..23ad2bf1 100644 --- a/spirv_hlsl.cpp +++ b/spirv_hlsl.cpp @@ -3494,9 +3494,9 @@ void CompilerHLSL::emit_texture_op(const Instruction &i, bool sparse) else { auto &imgformat = get(imgtype.image.type); - if (imgformat.basetype != SPIRType::Float) + if (hlsl_options.shader_model < 67 && imgformat.basetype != SPIRType::Float) { - SPIRV_CROSS_THROW("Sampling non-float textures is not supported in HLSL."); + SPIRV_CROSS_THROW("Sampling non-float textures is not supported in HLSL SM < 6.7."); } if (hlsl_options.shader_model >= 40)