diff options
author | Charles Pigott <charlespigott@googlemail.com> | 2021-01-08 10:16:18 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-08 11:16:18 +0100 |
commit | 9b800a96ed32720ff60b74e498a0e0a6351004f9 (patch) | |
tree | 3f287d339e15c4902ee415556475fd9b2918d33c /src/blitter/32bpp_base.cpp | |
parent | c1fddb9a6ae5c3af6865461a7295788a341011a2 (diff) | |
download | openttd-9b800a96ed32720ff60b74e498a0e0a6351004f9.tar.xz |
Codechange: Remove min/max functions in favour of STL variants (#8502)
Diffstat (limited to 'src/blitter/32bpp_base.cpp')
-rw-r--r-- | src/blitter/32bpp_base.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/blitter/32bpp_base.cpp b/src/blitter/32bpp_base.cpp index 6fe11c235..0678fce38 100644 --- a/src/blitter/32bpp_base.cpp +++ b/src/blitter/32bpp_base.cpp @@ -174,9 +174,9 @@ Colour Blitter_32bppBase::ReallyAdjustBrightness(Colour colour, uint8 brightness /* Reduce overbright strength */ ob /= 2; return Colour( - r >= 255 ? 255 : min(r + ob * (255 - r) / 256, 255), - g >= 255 ? 255 : min(g + ob * (255 - g) / 256, 255), - b >= 255 ? 255 : min(b + ob * (255 - b) / 256, 255), + r >= 255 ? 255 : std::min(r + ob * (255 - r) / 256, 255), + g >= 255 ? 255 : std::min(g + ob * (255 - g) / 256, 255), + b >= 255 ? 255 : std::min(b + ob * (255 - b) / 256, 255), colour.a); } |