We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Same idea as PositiveGpuAVOOB/VertexFragmentMultiEntrypoint/NegativeGpuAVOOB.VertexFragmentMultiEntrypoint (from https://github.com/KhronosGroup/Vulkan-ValidationLayers/pull/7778/files)
PositiveGpuAVOOB/VertexFragmentMultiEntrypoint
NegativeGpuAVOOB.VertexFragmentMultiEntrypoint
We should add a simple RTX test in PositiveGpuAVRayTracing/NegativeGpuAVRayTracing to test we handle this correctly
PositiveGpuAVRayTracing
NegativeGpuAVRayTracing
The biggest issue is the rt::Pipeline::SetRayGenShader test framework interface allows no way to do this currently
rt::Pipeline::SetRayGenShader
Here is a simple HLSL (and SPIR-V) example
// Compile with // dxc -spirv -T lib_6_4 -fspv-target-env=vulkan1.2 -Fo out.spv in.hlsl struct ColorPayload { uint index; }; [shader("miss")] void mainMiss(inout ColorPayload payload) { payload.index = 0; } [shader("closesthit")] void mainClosestHit(inout ColorPayload payload, BuiltInTriangleIntersectionAttributes attr) { payload.index = 1; } RWStructuredBuffer<float> OutBuffer : register(u0); // StorageBuffer (set 0, binding 0) Texture2D MyTextures[] : register(t1); // Texture array (set 0, binding 1) RaytracingAccelerationStructure _tlas; // (set 0, binding 2) [shader("raygeneration")] void mainRaygen() { float2 uv = float2(0.5, 0.5); RayDesc ray; ray.Origin = ray.Origin; ray.TMin = 0; ray.Direction = float3(0.5, 0.5, 0.5); ray.TMax = 1e6; ColorPayload payload; TraceRay(_tlas, -1, RAY_FLAG_NONE, 0, 0, 0, ray, payload); // the index will either be 0 or 1, this can be adjusted, but the main thing is to use this to trigger (or not trigger) descriptor indexing OOB Texture2D tex = MyTextures[NonUniformResourceIndex(payload.index)]; float4 val = tex[uv]; OutBuffer[0] = val.x; }
Spirv
The text was updated successfully, but these errors were encountered:
arno-lunarg
No branches or pull requests
Same idea as
PositiveGpuAVOOB/VertexFragmentMultiEntrypoint
/NegativeGpuAVOOB.VertexFragmentMultiEntrypoint
(fromhttps://github.com/KhronosGroup/Vulkan-ValidationLayers/pull/7778/files)
We should add a simple RTX test in
PositiveGpuAVRayTracing
/NegativeGpuAVRayTracing
to test we handle this correctlyThe biggest issue is the
rt::Pipeline::SetRayGenShader
test framework interface allows no way to do this currentlyHere is a simple HLSL (and SPIR-V) example
Spirv
The text was updated successfully, but these errors were encountered: