From 29db810c54ebdfe8cfd04614a04e180ffb9d9498 Mon Sep 17 00:00:00 2001 From: Alug Date: Tue, 9 Sep 2025 18:16:52 +0200 Subject: [PATCH] delet remaining "highcolor" stuff --- src/android/i_video.c | 4 ---- src/dedicated/i_video.c | 4 +--- src/i_video.h | 5 ----- src/r_data.c | 44 ----------------------------------------- src/r_data.h | 3 --- src/screen.c | 4 ++-- src/screen.h | 2 +- src/sdl/i_video.c | 2 -- 8 files changed, 4 insertions(+), 64 deletions(-) diff --git a/src/android/i_video.c b/src/android/i_video.c index 4db66afe0..bbe1cf3a3 100644 --- a/src/android/i_video.c +++ b/src/android/i_video.c @@ -10,12 +10,8 @@ rendermode_t rendermode = render_soft; -boolean highcolor = false; - boolean allow_fullscreen = false; - - consvar_t cv_vidwait = {"vid_wait", "Off", CV_SAVE, CV_OnOff, NULL, 0, NULL, NULL, 0, 0, NULL}; void I_StartupGraphics(void){} diff --git a/src/dedicated/i_video.c b/src/dedicated/i_video.c index 8f8781e9e..e2a712995 100644 --- a/src/dedicated/i_video.c +++ b/src/dedicated/i_video.c @@ -29,8 +29,6 @@ rendermode_t rendermode = render_none; -boolean highcolor = false; - // synchronize page flipping with screen refresh consvar_t cv_vidwait = {"vid_wait", "On", CV_SAVE, CV_OnOff, NULL, 0, NULL, NULL, 0, 0, NULL}; @@ -153,7 +151,7 @@ boolean I_UseNativeKeyboard(void) return false; } -void I_SetBorderlessWindow(void) +void I_SetBorderlessWindow(void) { } diff --git a/src/i_video.h b/src/i_video.h index 88d295ed9..d9bb9e1ce 100644 --- a/src/i_video.h +++ b/src/i_video.h @@ -40,11 +40,6 @@ typedef enum */ extern rendermode_t rendermode; - -/** \brief use highcolor modes if true -*/ -extern boolean highcolor; - /** \brief setup video mode */ void I_StartupGraphics(void); diff --git a/src/r_data.c b/src/r_data.c index 688b03972..0b4b153e4 100644 --- a/src/r_data.c +++ b/src/r_data.c @@ -121,10 +121,6 @@ UINT8 invertmap[256]; // for debugging/info purposes size_t flatmemory, spritememory, texturememory; // gotta play by 2.2 rules to get this to work -// highcolor stuff -INT16 color8to16[256]; // remap color index to highcolor rgb value -INT16 *hicolormaps; // test a 32k colormap remaps high -> high - // Blends two pixels together, using the equation // that matches the specified alpha style. UINT32 ASTBlendPixel(RGBA_t background, RGBA_t foreground, int style, UINT8 alpha) @@ -1661,40 +1657,6 @@ const char *R_ColormapNameForNum(INT32 num) } -// -// build a table for quick conversion from 8bpp to 15bpp -// - -// -// added "static inline" keywords, linking with the debug version -// of allegro, it have a makecol15 function of it's own, now -// with "static inline" keywords,it sloves this problem ;) -// -FUNCMATH static inline int makecol15(int r, int g, int b) -{ - return (((r >> 3) << 10) | ((g >> 3) << 5) | ((b >> 3))); -} - -static void R_Init8to16(void) -{ - UINT8 *palette; - int i; - - palette = W_CacheLumpName("PLAYPAL",PU_CACHE); - - for (i = 0; i < 256; i++) - { - // PLAYPAL uses 8 bit values - color8to16[i] = (INT16)makecol15(palette[0], palette[1], palette[2]); - palette += 3; - } - - // test a big colormap - hicolormaps = Z_Malloc(16384*sizeof(*hicolormaps), PU_STATIC, NULL); - for (i = 0; i < 16384; i++) - hicolormaps[i] = (INT16)(i<<1); -} - // // R_InitData // @@ -1703,12 +1665,6 @@ static void R_Init8to16(void) // void R_InitData(void) { - if (highcolor) - { - CONS_Printf("InitHighColor...\n"); - R_Init8to16(); - } - CONS_Printf("R_LoadTextures()...\n"); R_LoadTextures(); diff --git a/src/r_data.h b/src/r_data.h index 58afc34d0..2a74d591c 100644 --- a/src/r_data.h +++ b/src/r_data.h @@ -69,9 +69,6 @@ extern fixed_t *textureheight; // needed for texture pegging UINT32 ASTBlendPixel(RGBA_t background, RGBA_t foreground, int style, UINT8 alpha); UINT32 ASTBlendTexturePixel(RGBA_t background, RGBA_t foreground, int style, UINT8 alpha); -extern INT16 color8to16[256]; // remap color index to highcolor -extern INT16 *hicolormaps; // remap high colors to high colors.. - extern CV_PossibleValue_t Color_cons_t[]; // Load TEXTURE1/TEXTURE2/PNAMES definitions, create lookup tables diff --git a/src/screen.c b/src/screen.c index a8a3ca78b..4d239e186 100644 --- a/src/screen.c +++ b/src/screen.c @@ -8,7 +8,7 @@ // See the 'LICENSE' file for more details. //----------------------------------------------------------------------------- /// \file screen.c -/// \brief Handles multiple resolutions, 8bpp/16bpp(highcolor) modes +/// \brief Handles multiple resolutions #include "doomdef.h" #include "doomstat.h" @@ -37,7 +37,7 @@ // global video state // ------------------ viddef_t vid; -INT32 setmodeneeded; //video mode change needed if > 0 (the mode number to set + 1) +INT32 setmodeneeded; // video mode change needed if > 0 (the mode number to set + 1) static CV_PossibleValue_t shittyscreen_cons_t[] = {{0, "Okay"}, {1, "Shitty"}, {2, "Extra Shitty"}, {0, NULL}}; diff --git a/src/screen.h b/src/screen.h index 38483b28d..42bc6c144 100644 --- a/src/screen.h +++ b/src/screen.h @@ -8,7 +8,7 @@ // See the 'LICENSE' file for more details. //----------------------------------------------------------------------------- /// \file screen.h -/// \brief Handles multiple resolutions, 8bpp/16bpp(highcolor) modes +/// \brief Handles multiple resolutions #ifndef __SCREEN_H__ #define __SCREEN_H__ diff --git a/src/sdl/i_video.c b/src/sdl/i_video.c index 8e19b33ac..389e086e2 100644 --- a/src/sdl/i_video.c +++ b/src/sdl/i_video.c @@ -113,8 +113,6 @@ unsigned msaa = 0; boolean a2c = false; #endif -boolean highcolor = false; - static void KeyboardLayout_OnChange(void) { HU_Shiftform();