ShatteredSword/public/builtin/shaders/sprite.vshader

13 lines
263 B
Plaintext
Raw Permalink Normal View History

2022-04-12 00:08:57 -04:00
attribute vec4 a_Position;
attribute vec2 a_TexCoord;
uniform mat4 u_Transform;
uniform vec2 u_texShift;
uniform vec2 u_texScale;
varying vec2 v_TexCoord;
void main(){
gl_Position = u_Transform * a_Position;
v_TexCoord = a_TexCoord*u_texScale + u_texShift;
}