3 layout( location=0 ) in vec2 vTexCoord;
5 layout( set=1, binding=0, std140 ) uniform FragData
11 float preMultipliedAlpha;
14 layout( set=1, binding=1 ) uniform sampler2D sTexture;
16 layout( location=0 ) out vec4 fragColor;
20 return vec4( mixColor * mix( 1.0, opacity, preMultipliedAlpha ), opacity );
25 vec2 texCoord = clamp( mix( uAtlasRect.xy, uAtlasRect.zw, vTexCoord ), uAtlasRect.xy, uAtlasRect.zw );
26 fragColor = texture( sTexture, texCoord ) * uColor * visualMixColor();