Archive commit

This commit is contained in:
Erik McClure
2019-08-28 21:15:02 -07:00
commit 735845746e
1435 changed files with 140724 additions and 0 deletions
+31
View File
@@ -0,0 +1,31 @@
// VERTEX
attribute vec2 position;
attribute vec2 texcoords;
attribute vec4 vertexColor;
uniform mat4 transform;
uniform vec4 lighting;
varying vec2 textureCoord;
varying vec4 vColor;
void main() {
textureCoord = texcoords;
vColor = vertexColor * lighting;
gl_Position = transform * vec4(position, 0, 1);
}
// FRAGMENT
precision mediump float;
uniform sampler2D sampler1;
uniform float textureSize;
varying vec2 textureCoord;
varying vec4 vColor;
void main() {
gl_FragColor = texture2D(sampler1, textureCoord / textureSize) * vColor;
}