16 lines
434 B
GLSL
16 lines
434 B
GLSL
#version 450
|
|
#extension GL_EXT_buffer_reference : require
|
|
|
|
#include "hex_common.glsl"
|
|
|
|
layout(location = 0) flat out vec4 color;
|
|
|
|
void main() {
|
|
if(gl_VertexIndex == 0) {
|
|
gl_Position = pc.context.proj * pc.context.view * pc.context.rays.r[gl_InstanceIndex].start;
|
|
} else {
|
|
gl_Position = pc.context.proj * pc.context.view * pc.context.rays.r[gl_InstanceIndex].end;
|
|
}
|
|
color = pc.context.rays.r[gl_InstanceIndex].color;
|
|
}
|