Added init struct (resource loading helpers)

This commit is contained in:
2020-04-21 19:04:08 +02:00
parent 7165f9ee89
commit a519a9696c
13 changed files with 81 additions and 14 deletions

View File

@@ -0,0 +1,9 @@
precision mediump float;
uniform sampler2D u_texture;
varying vec2 v_texcoord;
void main() {
gl_FragColor = texture2D(u_texture, v_texcoord);
}

View File

@@ -0,0 +1,11 @@
attribute vec4 position;
attribute vec2 texcoord;
uniform mat4 u_matrix;
varying vec2 v_texcoord;
void main() {
gl_Position = u_matrix * position;
v_texcoord = texcoord;
}