Meshes can display textures

This commit is contained in:
Julian Nießner
2018-05-06 17:35:07 +02:00
parent aa9b1a1949
commit 7d616b6ce0
7 changed files with 74 additions and 25 deletions

View File

@@ -1,8 +1,13 @@
#version 300 es
precision mediump float;
in vec2 TexCoord;
out vec4 FragColor;
uniform sampler2D theTexture;
void main() {
FragColor = vec4(1.f, 0.5f, 0.2f, 1.0f);
//FragColor = vec4(1.f, 0.5f, 0.2f, 1.0f);
FragColor = texture(theTexture, TexCoord);
}