-
Fix float to r11g11b10 conversion · 1c9f2426Alexis Hetu authored
Floating point negative values were first converted to half values, followed with a conversion to 11 bit or 10 bit mini floats by chopping the mantissa and removing the sign bit. Negative values were converted to the same values as positive values since removing the sign bit ended up doing the equivalent of an Abs() call. Clamped the value to 0 before the conversion to solve the issue. Bug: b/146223877 b/147900455 Change-Id: I97decae66dc57a68f175b06902eb6725fc7d5794 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/42548 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Tested-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
1c9f2426
×