Files
manim/manimlib/shaders/set_gl_Position.glsl
2020-02-14 10:52:39 -08:00

12 lines
355 B
GLSL

// Assumes theese uniforms exist in the surrounding context
// uniform float scale;
// uniform float aspect_ratio;
// uniform float frame_center;
void set_gl_Position(vec3 point){
// TODO, orient in 3d based on certain rotation matrices
point -= frame_center;
point /= scale;
point.x /= aspect_ratio;
gl_Position = vec4(point, 1.0);
}