From c9930ea56ce0d3d9783d4d2482edb91cb765109e Mon Sep 17 00:00:00 2001 From: jsmall-nvidia Date: Wed, 27 Mar 2019 12:25:43 -0400 Subject: GLSL half texture access (#931) * * Added $c macro - that will do casting to target type. Used here to cast texture reads back to half. Works in tandem with $z which will close parens. * half-texture.slang test * Make binding failing if TextureView fails * Simplify logic around parens. * Improve comment around $c macro. * Test against hlsl output to avoid error on CI. --- tools/render-test/shader-renderer-util.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'tools/render-test/shader-renderer-util.cpp') diff --git a/tools/render-test/shader-renderer-util.cpp b/tools/render-test/shader-renderer-util.cpp index 3dc717c5b..13effdd08 100644 --- a/tools/render-test/shader-renderer-util.cpp +++ b/tools/render-test/shader-renderer-util.cpp @@ -392,6 +392,11 @@ static RefPtr _createSamplerState( texture, viewDesc); + if (!textureView) + { + return SLANG_FAIL; + } + descriptorSet->setResource(rangeIndex, 0, textureView); if(srcEntry.isOutput) -- cgit v1.2.3