[GPU] Fix CPU-side float24 conversion broken recently

This commit is contained in:
Triang3l 2022-06-22 20:47:44 +03:00
parent cbf0476d42
commit a7885ae1a4
1 changed files with 1 additions and 1 deletions

View File

@ -146,7 +146,7 @@ uint32_t Float32To20e4(float f32, bool round_to_nearest_even) {
f32u32 += 0xC8000000u;
}
if (round_to_nearest_even) {
f32u32 += f32u32 + 3 + ((f32u32 >> 3) & 1);
f32u32 += 3 + ((f32u32 >> 3) & 1);
}
return (f32u32 >> 3) & 0xFFFFFF;
}