Assorted edits. Created new shaders.

This commit is contained in:
2014-05-06 16:36:46 -04:30
parent f04c5806d1
commit 31dd89f30e
7 changed files with 30 additions and 4 deletions

View File

@@ -0,0 +1,17 @@
#ifdef GL_ES
precision mediump float;
#endif
// Light color.
uniform vec3 u_lightColor;
// Diffuse surface color.
uniform vec3 u_diffColor;
// Specular color.
uniform vec3 u_specColor;
// Ambient light color.
uniform vec3 u_ambColor;
void main(){
// TODO: Implement per pixel diffuse lighting.
gl_FragColor = vec4(u_diffColor, 1.0);
}

View File

@@ -0,0 +1,9 @@
// Model-view matrix.
uniform mat4 u_projTrans;
// Vertex position in world coordinates.
attribute vec4 a_position;
void main(){
gl_Position = u_projTrans * a_position;
}