2024-11-04 17:51:10 -07:00
|
|
|
#version 450
|
|
|
|
#extension GL_EXT_buffer_reference : require
|
|
|
|
|
|
|
|
#include "hex_common.glsl"
|
|
|
|
|
|
|
|
layout(location = 0) flat out vec4 color;
|
|
|
|
|
|
|
|
void main() {
|
2024-11-24 21:44:36 -07:00
|
|
|
if(gl_VertexIndex == 0) {
|
|
|
|
gl_Position = pc.context.proj * pc.context.view * pc.context.rays.r[gl_InstanceIndex].start;
|
2024-11-04 17:51:10 -07:00
|
|
|
} else {
|
2024-11-24 21:44:36 -07:00
|
|
|
gl_Position = pc.context.proj * pc.context.view * pc.context.rays.r[gl_InstanceIndex].end;
|
2024-11-04 17:51:10 -07:00
|
|
|
}
|
2024-11-24 21:44:36 -07:00
|
|
|
color = pc.context.rays.r[gl_InstanceIndex].color;
|
2024-11-04 17:51:10 -07:00
|
|
|
}
|