summaryrefslogblamecommitdiff
path: root/data/graphics/shaders/simple_frag.glsl
blob: 2c149351a1b435284b5d0d18b01c6534858c3e57 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
            
                 
                  
                      
                   


                       

           
                        


                                                                                                  
        
     
                         
     
 
#version 130
in vec2 Texcoord;
out vec4 outColor;
uniform sampler2D tex;
uniform vec4 color;
uniform float drawType;
uniform float alpha;

void main()
{
    if (drawType >= 0.1)
    {
        outColor = texelFetch(tex, ivec2(Texcoord.x, Texcoord.y), 0) * vec4(1.0, 1.0, 1.0, alpha);
    }
    else
    {
        outColor = color;
    }
}