2020-02-03 10:52:39 -08:00
|
|
|
#version 330
|
|
|
|
|
2020-06-01 16:21:18 -07:00
|
|
|
uniform mat4 to_screen_space;
|
2020-06-08 20:27:07 -07:00
|
|
|
uniform float is_fixed_in_frame;
|
2020-06-01 16:21:18 -07:00
|
|
|
|
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-06-28 12:13:25 -07:00
|
|
|
in float vert_index;
|
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-06-28 12:13:25 -07:00
|
|
|
out float v_vert_index;
|
2020-02-03 10:52:39 -08:00
|
|
|
|
2021-01-07 16:16:20 -08:00
|
|
|
// Analog of import for manim only
|
2020-06-01 16:21:18 -07:00
|
|
|
#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-09 12:34:00 -07:00
|
|
|
v_global_unit_normal = normalize(to_screen_space * vec4(unit_normal, 0)).xyz;
|
2020-02-03 10:52:39 -08:00
|
|
|
v_color = color;
|
2020-06-28 12:13:25 -07:00
|
|
|
v_vert_index = vert_index;
|
2020-02-03 10:52:39 -08:00
|
|
|
}
|