2020-02-03 10:52:39 -08:00
|
|
|
#version 330
|
|
|
|
|
2020-06-01 16:21:18 -07:00
|
|
|
uniform mat4 to_screen_space;
|
|
|
|
|
2020-02-05 14:45:42 -08:00
|
|
|
in vec3 point;
|
2020-06-03 17:10:33 -07:00
|
|
|
in vec3 unit_normal;
|
2020-02-03 10:52:39 -08:00
|
|
|
in vec4 color;
|
2020-05-31 17:02:05 -07:00
|
|
|
in float fill_all; // Either 0 or 1
|
2020-06-02 16:18:44 -07:00
|
|
|
in float gloss;
|
2020-02-03 10:52:39 -08:00
|
|
|
|
2020-02-16 10:53:16 -08:00
|
|
|
out vec3 bp; // Bezier control point
|
2020-06-03 17:10:33 -07:00
|
|
|
out vec3 v_global_unit_normal;
|
2020-02-03 10:52:39 -08:00
|
|
|
out vec4 v_color;
|
2020-02-07 09:31:57 -08:00
|
|
|
out float v_fill_all;
|
2020-06-02 16:18:44 -07:00
|
|
|
out float v_gloss;
|
2020-02-03 10:52:39 -08:00
|
|
|
|
2020-06-01 16:21:18 -07:00
|
|
|
// To my knowledge, there is no notion of #include for shaders,
|
|
|
|
// so to share functionality between this and others, the caller
|
|
|
|
// replaces this line with the contents of named file
|
|
|
|
#INSERT position_point_into_frame.glsl
|
2020-02-16 10:53:16 -08:00
|
|
|
|
2020-02-03 10:52:39 -08:00
|
|
|
void main(){
|
2020-06-01 16:21:18 -07:00
|
|
|
bp = position_point_into_frame(point);
|
2020-06-04 11:29:36 -07:00
|
|
|
v_global_unit_normal = normalize(position_point_into_frame(unit_normal));
|
2020-02-03 10:52:39 -08:00
|
|
|
v_color = color;
|
2020-02-07 09:31:57 -08:00
|
|
|
v_fill_all = fill_all;
|
2020-06-02 16:18:44 -07:00
|
|
|
v_gloss = gloss;
|
2020-02-03 10:52:39 -08:00
|
|
|
}
|