#version 330

in vec4 v_color0;
in vec2 v_texcoord0;
uniform sampler2D uTexture;

out vec4 FragColor;

void main()
{
	vec4 texColor = texture(uTexture, v_texcoord0);
    vec4 vLightColor = v_color0;
	
    float maxIntensity = 1.0;
    vLightColor.rgb = min(vLightColor.rgb, vec3(maxIntensity));

    FragColor = texColor * vLightColor;
}