#version 460 #extension GL_EXT_ray_tracing : enable // Benchmark closest-hit: shade from the hit's barycentric coordinates. // SponzaBench deliberately avoids the descriptor-heap texture sample the // interactive Sponza example uses — the point here is to measure the // ray-tracing traversal + frame-loop cost, not texturing, and a // texture-free hit keeps the host setup portable across library // revisions (issue #155). hitAttributeEXT vec2 hitAttrs; layout(location = 0) rayPayloadInEXT vec3 hitValue; void main() { vec3 bary = vec3(1.0 - hitAttrs.x - hitAttrs.y, hitAttrs.x, hitAttrs.y); hitValue = bary; }