mirror of
https://github.com/scummvm/scummvm.git
synced 2025-04-02 10:52:32 -04:00
OGLES2 doesn't support uniform booleans so we use macros to make it use integers in this case. For other platforms, this change should be a noop. OGLES2 doesn't like float suffix for constants, remove it as well.
18 lines
269 B
Text
18 lines
269 B
Text
in vec2 Texcoord;
|
|
in vec3 Color;
|
|
|
|
OUTPUT
|
|
|
|
uniform UBOOL textured;
|
|
uniform vec3 color;
|
|
uniform sampler2D tex;
|
|
|
|
void main() {
|
|
outColor = vec4(Color, 1.0);
|
|
|
|
if (UBOOL_TEST(textured)) {
|
|
outColor *= texture(tex, Texcoord);
|
|
} else {
|
|
outColor *= vec4(color, 1.0);
|
|
}
|
|
}
|