// imitation of the Unreal Engine 1.x ambient glow effect // plus brightmapping void SetupMaterial( inout Material mat ) { mat.Base = getTexel(vTexCoord.st); float bright = texture(brighttex,vTexCoord.st).x; float glow = .25+.2*sin(timer*8.); mat.Bright = vec4(vec3(min(1.,bright+glow)),1.); mat.Normal = ApplyNormalMap(vTexCoord.st); }