Replies: 2 comments 1 reply
-
vsg::TraceRays just encapsulates vkCmdTraceRays: https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/vkCmdTraceRaysKHR.html This doesn't have a dedicate shadow shader group, if this is what you were expecting. I don't know what your expectations and what specifically you trying to do in your code and why so I can't say what you should be doing. If you are trying to follow a 3rd party Viulkan raytracing examplet and are trying to implement this with the VSG then provide a link to the example/tutorial so we can see where you are coming from and see if we can spot what you should do. |
Beta Was this translation helpful? Give feedback.
-
I refer to https://github.com/SaschaWillems/Vulkan/blob/master/examples/raytracingshadows/raytracingshadows.cpp There is a ShaderBindingTable, and the code is as follows However, there is no processing in vsg for two Missshaders (miss.rmiss shadow.rmiss). I ran the following tests in vsg. Then it worked |
Beta Was this translation helpful? Give feedback.
-
vsgraytracing demo, I want to add shadow.rmiss, but it hasn't been connected. Here's my code. I don't know how to connect shadow.rmiss in traceRays.
// fallback to spv shaders if GLSL variants can't be loaded
auto raygenShader = vsg::ShaderStage::read(VK_SHADER_STAGE_RAYGEN_BIT_KHR, "main", "shaders/raygen.rgen.spv", options);
auto missShader = vsg::ShaderStage::read(VK_SHADER_STAGE_MISS_BIT_KHR, "main", "shaders/miss.rmiss.spv", options);
auto shadowthitShader = vsg::ShaderStage::read(VK_SHADER_STAGE_MISS_BIT_KHR, "main", "shaders/shadow.rmiss.spv", options);
auto closesthitShader = vsg::ShaderStage::read(VK_SHADER_STAGE_CLOSEST_HIT_BIT_KHR, "main", "shaders/closesthit.rchit.spv", options);
Beta Was this translation helpful? Give feedback.
All reactions