Jeff Bolz | 61a0cd1 | 2018-12-14 20:59:53 -0600 | [diff] [blame] | 1 | #version 460 |
| 2 | #extension GL_NV_ray_tracing : enable |
| 3 | layout(binding = 0, set = 0) uniform accelerationStructureNV accNV; |
| 4 | layout(location = 0) rayPayloadNV vec4 payload; |
| 5 | layout(shaderRecordNV) buffer block |
| 6 | { |
Ashwin Lele | afa5671 | 2019-03-04 11:05:55 -0800 | [diff] [blame] | 7 | vec3 dir; |
| 8 | vec3 origin; |
Jeff Bolz | 61a0cd1 | 2018-12-14 20:59:53 -0600 | [diff] [blame] | 9 | }; |
| 10 | void main() |
| 11 | { |
| 12 | uint lx = gl_LaunchIDNV.x; |
| 13 | uint ly = gl_LaunchIDNV.y; |
| 14 | uint sx = gl_LaunchSizeNV.x; |
| 15 | uint sy = gl_LaunchSizeNV.y; |
Ashwin Lele | afa5671 | 2019-03-04 11:05:55 -0800 | [diff] [blame] | 16 | traceNV(accNV, lx, ly, sx, sy, 0u, origin, 0.5f, dir, 0.75f, 1); |
Jeff Bolz | 61a0cd1 | 2018-12-14 20:59:53 -0600 | [diff] [blame] | 17 | } |