mirror of
https://github.com/KhronosGroup/glslang
synced 2024-11-09 20:10:06 +00:00
e11a2c8bec
* update spirv-headers and fix handling of gl_HitTEXT Update spirv-headers known_good to f027d53ded7e230e008d37c8b47ede7cd308e19d and update SPIRV/spirv.hpp to copy from that version as well. In GLSL gl_HitTNV/gl_HitTEXT is defined as an alias of gl_RayTmaxNV/gl_RayTmaxEXT SPV_NV_ray_tracing has a dedicated HitTNV which gl_HitTNV maps to. For SPV_KHR_ray_tracing, gl_HitTEXT gets mapped to a RayTmaxKHR decoraged variable to simplify the SPIRV consumer. This change fixes the mapping for the GL_EXT_ray_tracing extension, and updates the test results to match. * update MissNV shader test to not use ObjectRay builtins They shouldn't existing in the miss stage because there is no object intersected
17 lines
532 B
GLSL
17 lines
532 B
GLSL
#version 460
|
|
#extension GL_NV_ray_tracing : enable
|
|
layout(binding = 0, set = 0) uniform accelerationStructureNV accNV;
|
|
layout(location = 0) rayPayloadNV vec4 localPayload;
|
|
layout(location = 1) rayPayloadInNV vec4 incomingPayload;
|
|
void main()
|
|
{
|
|
uvec3 v0 = gl_LaunchIDNV;
|
|
uvec3 v1 = gl_LaunchSizeNV;
|
|
vec3 v2 = gl_WorldRayOriginNV;
|
|
vec3 v3 = gl_WorldRayDirectionNV;
|
|
uint v4 = gl_IncomingRayFlagsNV;
|
|
float v6 = gl_RayTminNV;
|
|
float v7 = gl_RayTmaxNV;
|
|
traceNV(accNV, 0u, 1u, 2u, 3u, 0u, vec3(0.5f), 0.5f, vec3(1.0f), 0.75f, 1);
|
|
}
|