aboutsummaryrefslogtreecommitdiff
path: root/Ryujinx.Graphics.Shader/CodeGen
diff options
context:
space:
mode:
Diffstat (limited to 'Ryujinx.Graphics.Shader/CodeGen')
-rw-r--r--Ryujinx.Graphics.Shader/CodeGen/Glsl/TypeConversion.cs5
1 files changed, 3 insertions, 2 deletions
diff --git a/Ryujinx.Graphics.Shader/CodeGen/Glsl/TypeConversion.cs b/Ryujinx.Graphics.Shader/CodeGen/Glsl/TypeConversion.cs
index 7adc5ad3..b13a74f4 100644
--- a/Ryujinx.Graphics.Shader/CodeGen/Glsl/TypeConversion.cs
+++ b/Ryujinx.Graphics.Shader/CodeGen/Glsl/TypeConversion.cs
@@ -37,8 +37,9 @@ namespace Ryujinx.Graphics.Shader.CodeGen.Glsl
{
switch (dstType)
{
- case VariableType.S32: return $"floatBitsToInt({expr})";
- case VariableType.U32: return $"floatBitsToUint({expr})";
+ case VariableType.Bool: return $"(floatBitsToInt({expr}) != 0)";
+ case VariableType.S32: return $"floatBitsToInt({expr})";
+ case VariableType.U32: return $"floatBitsToUint({expr})";
}
}
else if (dstType == VariableType.F32)