diff options
author | Kae <80987908+Novaenia@users.noreply.github.com> | 2024-12-31 14:49:51 +1100 |
---|---|---|
committer | Kae <80987908+Novaenia@users.noreply.github.com> | 2024-12-31 14:49:51 +1100 |
commit | 874ab3dd48a53c0cda6bb1faaeea27b52d2c1df2 (patch) | |
tree | 86c2d0d24e98b849f6bd7dd1e7abdb95baed4abe /source/core/StarImageScaling.cpp | |
parent | 9beadf3e2c6f06f43259e48629598fe77c365797 (diff) |
?saturation discrepancies: fixed mostly on GCC, 100% (seemingly?) on Clang
Diffstat (limited to 'source/core/StarImageScaling.cpp')
-rw-r--r-- | source/core/StarImageScaling.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/source/core/StarImageScaling.cpp b/source/core/StarImageScaling.cpp index 96837aa..aa94359 100644 --- a/source/core/StarImageScaling.cpp +++ b/source/core/StarImageScaling.cpp @@ -33,8 +33,7 @@ Image scaleBilinear(Image const& srcImage, Vec2F const& scale) { auto ipart = Vec2I::floor(pos); auto fpart = pos - Vec2F(ipart); - auto result = lerp(fpart[1], lerp(fpart[0], Vec4F(srcImage.clamp(ipart[0], ipart[1])), Vec4F(srcImage.clamp(ipart[0] + 1, ipart[1]))), lerp(fpart[0], - Vec4F(srcImage.clamp(ipart[0], ipart[1] + 1)), Vec4F(srcImage.clamp(ipart[0] + 1, ipart[1] + 1)))); + auto result = lerp(fpart[1], lerp(fpart[0], Vec4F(srcImage.clamp(ipart[0], ipart[1])), Vec4F(srcImage.clamp(ipart[0] + 1, ipart[1]))), lerp(fpart[0], Vec4F(srcImage.clamp(ipart[0], ipart[1] + 1)), Vec4F(srcImage.clamp(ipart[0] + 1, ipart[1] + 1)))); destImage.set({x, y}, Vec4B(result)); } |