mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 07:28:11 +02:00
mesa: Upload boolean uniforms using UniformBooleanTrue.
Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
This commit is contained in:
parent
e0f955abd3
commit
6df0fd8fe9
1 changed files with 2 additions and 2 deletions
|
|
@ -799,9 +799,9 @@ _mesa_uniform(struct gl_context *ctx, struct gl_shader_program *shProg,
|
|||
|
||||
for (i = 0; i < elems; i++) {
|
||||
if (basicType == GLSL_TYPE_FLOAT) {
|
||||
dst[i].i = src[i].f != 0.0f ? 1 : 0;
|
||||
dst[i].i = src[i].f != 0.0f ? ctx->Const.UniformBooleanTrue : 0;
|
||||
} else {
|
||||
dst[i].i = src[i].i != 0 ? 1 : 0;
|
||||
dst[i].i = src[i].i != 0 ? ctx->Const.UniformBooleanTrue : 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue