mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-22 04:21:23 +00:00
Merge branch 'fix-opengl-saturation-console' into 'next'
Fix saturation not being applied on console on OpenGL See merge request STJr/SRB2!2149
This commit is contained in:
commit
962b1cb29e
1 changed files with 23 additions and 22 deletions
|
@ -1336,32 +1336,33 @@ void V_DrawFill(INT32 x, INT32 y, INT32 w, INT32 h, INT32 c)
|
|||
// This is now a function since it's otherwise repeated 2 times and honestly looks retarded:
|
||||
static UINT32 V_GetHWConsBackColor(void)
|
||||
{
|
||||
UINT32 hwcolor;
|
||||
UINT8 r, g, b;
|
||||
switch (cons_backcolor.value)
|
||||
{
|
||||
case 0: hwcolor = 0xffffff00; break; // White
|
||||
case 1: hwcolor = 0x80808000; break; // Black
|
||||
case 2: hwcolor = 0xdeb88700; break; // Sepia
|
||||
case 3: hwcolor = 0x40201000; break; // Brown
|
||||
case 4: hwcolor = 0xfa807200; break; // Pink
|
||||
case 5: hwcolor = 0xff69b400; break; // Raspberry
|
||||
case 6: hwcolor = 0xff000000; break; // Red
|
||||
case 7: hwcolor = 0xffd68300; break; // Creamsicle
|
||||
case 8: hwcolor = 0xff800000; break; // Orange
|
||||
case 9: hwcolor = 0xdaa52000; break; // Gold
|
||||
case 10: hwcolor = 0x80800000; break; // Yellow
|
||||
case 11: hwcolor = 0x00ff0000; break; // Emerald
|
||||
case 12: hwcolor = 0x00800000; break; // Green
|
||||
case 13: hwcolor = 0x4080ff00; break; // Cyan
|
||||
case 14: hwcolor = 0x4682b400; break; // Steel
|
||||
case 15: hwcolor = 0x1e90ff00; break; // Periwinkle
|
||||
case 16: hwcolor = 0x0000ff00; break; // Blue
|
||||
case 17: hwcolor = 0xff00ff00; break; // Purple
|
||||
case 18: hwcolor = 0xee82ee00; break; // Lavender
|
||||
case 0: r = 0xff; g = 0xff; b = 0xff; break; // White
|
||||
case 1: r = 0x80; g = 0x80; b = 0x80; break; // Black
|
||||
case 2: r = 0xde; g = 0xb8; b = 0x87; break; // Sepia
|
||||
case 3: r = 0x40; g = 0x20; b = 0x10; break; // Brown
|
||||
case 4: r = 0xfa; g = 0x80; b = 0x72; break; // Pink
|
||||
case 5: r = 0xff; g = 0x69; b = 0xb4; break; // Raspberry
|
||||
case 6: r = 0xff; g = 0x00; b = 0x00; break; // Red
|
||||
case 7: r = 0xff; g = 0xd6; b = 0x83; break; // Creamsicle
|
||||
case 8: r = 0xff; g = 0x80; b = 0x00; break; // Orange
|
||||
case 9: r = 0xda; g = 0xa5; b = 0x20; break; // Gold
|
||||
case 10: r = 0x80; g = 0x80; b = 0x00; break; // Yellow
|
||||
case 11: r = 0x00; g = 0xff; b = 0x00; break; // Emerald
|
||||
case 12: r = 0x00; g = 0x80; b = 0x00; break; // Green
|
||||
case 13: r = 0x40; g = 0x80; b = 0xff; break; // Cyan
|
||||
case 14: r = 0x46; g = 0x82; b = 0xb4; break; // Steel
|
||||
case 15: r = 0x1e; g = 0x90; b = 0xff; break; // Periwinkle
|
||||
case 16: r = 0x00; g = 0x00; b = 0xff; break; // Blue
|
||||
case 17: r = 0xff; g = 0x00; b = 0xff; break; // Purple
|
||||
case 18: r = 0xee; g = 0x82; b = 0xee; break; // Lavender
|
||||
// Default green
|
||||
default: hwcolor = 0x00800000; break;
|
||||
default: r = 0x00; g = 0x80; b = 0x00; break;
|
||||
}
|
||||
return hwcolor;
|
||||
V_CubeApply(&r, &g, &b);
|
||||
return (r << 24) | (g << 16) | (b << 8);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Reference in a new issue