overte-HifiExperiments/libraries/render-utils/src/standardDrawTexture.slf
2015-08-01 14:43:52 -07:00

31 lines
777 B
Text

<@include gpu/Config.slh@>
<$VERSION_HEADER$>
// Generated on <$_SCRIBE_DATE$>
// standardDrawTexture.frag
// fragment shader
//
// Created by Sam Gateau on 6/10/15.
// Copyright 2015 High Fidelity, Inc.
//
// Distributed under the Apache License, Version 2.0.
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
// the texture
uniform sampler2D colorMap;
in vec3 _position;
in vec3 _normal;
in vec2 _texCoord0;
in vec4 _color;
out vec4 _fragColor;
void main(void) {
vec4 color = texture(colorMap, _texCoord0);
// FIXME CORE this isn't working
//_fragColor = color * _color;
//_fragColor = vec4(color.rgb, color.a * _color.a);
//_fragColor = vec4(color.rgb * _color.rgb, color.a);
_fragColor = color;
}