Have stroke/fill vert shaders take in 3d points

This commit is contained in:
Grant Sanderson 2020-02-05 14:45:42 -08:00
parent 025f6d9524
commit 0a82229ac1
2 changed files with 8 additions and 8 deletions

View file

@ -1,6 +1,6 @@
#version 330
in vec2 point;
in vec3 point;
in vec4 color;
in float fill_type;
@ -10,7 +10,7 @@ out float v_fill_type;
void main(){
bp = point;
bp = point.xy; // TODO
v_color = color;
v_fill_type = fill_type;
}

View file

@ -1,8 +1,8 @@
#version 330
in vec2 point;
in vec2 prev_point;
in vec2 next_point;
in vec3 point;
in vec3 prev_point;
in vec3 next_point;
in float stroke_width;
in vec4 color;
@ -24,7 +24,7 @@ void main(){
v_color = color;
v_joint_type = joint_type;
bp = point;
prev_bp = prev_point;
next_bp = next_point;
bp = point.xy; // TODO, apply some kind of 3d rotation or shift first
prev_bp = prev_point.xy;
next_bp = next_point.xy;
}