<@include gpu/Config.slh@> <$VERSION_HEADER$> // Generated on <$_SCRIBE_DATE$> // // model_translucent_emissive.frag // fragment shader // // Created by Zach Pomerantz on 2/3/2016. // Copyright 2016 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 // <@include model/Material.slh@> uniform sampler2D albedoMap; in vec2 _texCoord0; in vec3 _color; in float _alpha; out vec4 _fragColor; void main(void) { vec4 albedo = texture(albedoMap, _texCoord0); Material mat = getMaterial(); vec3 fragColor = getMaterialAlbedo(mat) * albedo.rgb * _color; float fragOpacity = getMaterialOpacity(mat) * albedo.a * _alpha; _fragColor = vec4(fragColor, fragOpacity); }