When sampling an sRGB texture format, we have a vector of 16-bit elements where 0xFF00 represents 1.0, but we were using a lookup table which produced results in a 0xFFFF base. Also on linear to sRGB conversion, precision was lost due to truncating to 12-bit. Adding a rounding factor before truncating preserves precision. Bug: b/149574741 Change-Id: I19218c958867c4b5e97dc3b62b4ea83f37161134 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/41268 Presubmit-Ready: Nicolas Capens <nicolascapens@google.com> Tested-by:Nicolas Capens <nicolascapens@google.com> Kokoro-Presubmit: Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
| Name |
Last commit
|
Last update |
|---|---|---|
| .. | ||
| Linux | Loading commit data... | |
| BUILD.gn | Loading commit data... | |
| Build.cpp | Loading commit data... | |
| Build.hpp | Loading commit data... | |
| CPUID.cpp | Loading commit data... | |
| CPUID.hpp | Loading commit data... | |
| Configurator.cpp | Loading commit data... | |
| Configurator.hpp | Loading commit data... | |
| Debug.cpp | Loading commit data... | |
| Debug.hpp | Loading commit data... | |
| GrallocAndroid.cpp | Loading commit data... | |
| GrallocAndroid.hpp | Loading commit data... | |
| Half.cpp | Loading commit data... | |
| Half.hpp | Loading commit data... | |
| Math.cpp | Loading commit data... | |
| Math.hpp | Loading commit data... | |
| Memory.cpp | Loading commit data... | |
| Memory.hpp | Loading commit data... | |
| SharedLibrary.hpp | Loading commit data... | |
| Socket.cpp | Loading commit data... | |
| Socket.hpp | Loading commit data... | |
| Synchronization.hpp | Loading commit data... | |
| Timer.cpp | Loading commit data... | |
| Timer.hpp | Loading commit data... | |
| Types.hpp | Loading commit data... |