mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2024-12-23 10:09:43 +01:00
Remove duplicate color-clamping code from Graphics::bigrprint()
For some reason, there's some color-clamping code in this function directly after already-existing color-clamping code. This code dates back to 2.2. And also, there's a smaller lower-bound of -1 for the red channel, despite the fact that this smaller value doesn't matter because the red would get clamped to 0 by the first code anyway. So even if this was put here for some strange reason, it doesn't matter because it doesn't do anything anyway.
This commit is contained in:
parent
a6a8173e20
commit
efc9d4ea80
1 changed files with 0 additions and 8 deletions
|
@ -3000,14 +3000,6 @@ void Graphics::bigrprint(int x, int y, std::string& t, int r, int g, int b, bool
|
||||||
|
|
||||||
x -= (len(t));
|
x -= (len(t));
|
||||||
|
|
||||||
if (r < -1) r = -1;
|
|
||||||
if (g < 0) g = 0;
|
|
||||||
if (b < 0) b = 0;
|
|
||||||
if (r > 255) r = 255;
|
|
||||||
if (g > 255) g = 255;
|
|
||||||
if (b > 255) b = 255;
|
|
||||||
ct.colour = getRGB(r, g, b);
|
|
||||||
|
|
||||||
if (cen)
|
if (cen)
|
||||||
{
|
{
|
||||||
x = std::max(160 - (int((len(t)/ 2.0)*sc)), 0 );
|
x = std::max(160 - (int((len(t)/ 2.0)*sc)), 0 );
|
||||||
|
|
Loading…
Reference in a new issue