blob: 4f541f8249408afed4b7da194789dfbd657ea3d0 [file] [log] [blame]
#version 460
#extension GL_EXT_ray_tracing : enable
hitAttributeEXT vec3 attribs;
layout(location = 0) rayPayloadInEXT vec3 hitValue;
layout(set = 0, binding = 0, r32i) uniform iimage3D result;
void main()
{
float k = 1048576.0f;
int ndx = -1;
for (int col = 0; col < 3; col++)
for (int row = 0; row < 4; row++)
{
ndx++;
ivec3 p = ivec3(gl_LaunchIDEXT.xy, ndx);
float r = k * gl_WorldToObject3x4EXT[col][row];
ivec4 c = ivec4(int(r),0,0,1);
imageStore(result, p, c);
}
}