diff --git a/src/deh_tables.c b/src/deh_tables.c index 1aa971571fc905921475b4ef20cf34d2dea3f69d..1474296f9207ad1c64593f570047015795017a12 100644 --- a/src/deh_tables.c +++ b/src/deh_tables.c @@ -4397,8 +4397,6 @@ const char *COLOR_ENUMS[] = { "INTERMISSION1", "INTERMISSION2", "INTERMISSION3", - - "COLORPROFILE", }; const char *const KARTHUD_LIST[] = { diff --git a/src/doomdef.h b/src/doomdef.h index fa81f38c3a686fdb24171f29ed4a3225ef63c55f..69faba1a003ab0c121c104533a0e9c8b2846e888 100644 --- a/src/doomdef.h +++ b/src/doomdef.h @@ -387,8 +387,6 @@ typedef enum SKINCOLOR_INTERMISSION1, SKINCOLOR_INTERMISSION2, SKINCOLOR_INTERMISSION3, - - SKINCOLOR_COLORPROFILE, SKINCOLOR_FIRSTFREESLOT, SKINCOLOR_LASTFREESLOT = SKINCOLOR_FIRSTFREESLOT + NUMCOLORFREESLOTS - 1, diff --git a/src/info.c b/src/info.c index fa8125dc77bf9388e84b602c980bd906d8e50f05..ffdf5daf8d2f952e4fd5799991595f43142250fd 100644 --- a/src/info.c +++ b/src/info.c @@ -22265,7 +22265,6 @@ skincolor_t skincolors[MAXSKINCOLORS] = { {"Intermission 1", { 0, 80, 80, 80, 81, 81, 81, 84, 84, 85, 86, 86, 87, 87, 246, 248}, SKINCOLOR_NONE, 0, 0, false, UINT16_MAX}, // SKINCOLOR_INTERMISSION1 {"Intermission 2", { 0, 81, 81, 81, 88, 88, 88, 89, 89, 140, 140, 141, 141, 142, 142, 142}, SKINCOLOR_NONE, 0, 0, false, UINT16_MAX}, // SKINCOLOR_INTERMISSION2 {"Intermission 3", { 0, 144, 144, 144, 129, 129, 129, 130, 130, 146, 147, 147, 14, 16, 17, 19}, SKINCOLOR_NONE, 0, 0, false, UINT16_MAX}, // SKINCOLOR_INTERMISSION3 - {"Color Profile", { 35, 35, 73, 73, 112, 112, 255, 255, 152, 152, 181, 181, 181, 181, 0, 0}, SKINCOLOR_NONE, 0, 0, false, UINT16_MAX}, // SKINCOLOR_COLORPROFILE }; /** Patches the mobjinfo, state, and skincolor tables. diff --git a/src/k_menu.h b/src/k_menu.h index 22cd3e40d6f86990ee4c9541404d4e0aabe2d1a6..fbb34dcc886e4061971aedc1d31b526416768f21 100644 --- a/src/k_menu.h +++ b/src/k_menu.h @@ -1359,6 +1359,7 @@ void M_DrawPlaybackMenu(void); // Options menus: void M_DrawOptionsCogs(void); +void M_DrawOptionsColorProfile(void); void M_DrawOptionsMovingButton(void); // for sick transitions... void M_DrawOptions(void); void M_DrawGenericOptions(void); diff --git a/src/k_menudraw.c b/src/k_menudraw.c index a9f48161fc34d30011306a1a203f20aa7a197823..9edf05c526cc1420344b82177e8d7558d2865080 100644 --- a/src/k_menudraw.c +++ b/src/k_menudraw.c @@ -4377,6 +4377,57 @@ void M_DrawOptionsCogs(void) } } +// Hacking up M_DrawOptionsCogs to try and make something better suited for changing the color profile. - Freaky Mutant Man +void M_DrawOptionsColorProfile(void) +{ + boolean eggahack = ( + currentMenu->prevMenu == &PLAY_MP_HostDef + || ( + currentMenu->prevMenu + && currentMenu->prevMenu->prevMenu == &PLAY_MP_HostDef + ) + ); + boolean solidbg = M_GameTrulyStarted() && !eggahack; + UINT32 tick = ((optionsmenu.ticker/10) % 3) + 1; + + // the background isn't drawn outside of being in the main menu state. + if (gamestate == GS_MENU && solidbg) + { + patch_t *back = W_CachePatchName(va("OPT_BC%u", tick), PU_CACHE); + INT32 tflag = 0; + UINT8 *c; + UINT8 *c2; // colormap for the one we're changing + + if (optionsmenu.fade) + { + c2 = R_GetTranslationColormap(TC_DEFAULT, optionsmenu.lastcolour, GTC_CACHE); + V_DrawFixedPatch(0, 0, FRACUNIT, 0, back, c2); + + // prepare fade flag: + tflag = min(V_90TRANS, (optionsmenu.fade)<<V_ALPHASHIFT); + + } + c = R_GetTranslationColormap(TC_DEFAULT, optionsmenu.currcolour, GTC_CACHE); + V_DrawFixedPatch(0, 0, FRACUNIT, tflag, back, c); + } + // Given the need for accessibility, I don't want the background to be drawn transparent here - a clear color reference is needed for proper utilization. - Freaky Mutant Man + else + { + if (eggahack) + { + M_DrawEggaChannelAlignable(true); + } + + patch_t *back_pause = W_CachePatchName(va("OPT_BAC%u", tick), PU_CACHE); + V_DrawFixedPatch(0, 0, FRACUNIT, 0, back_pause, NULL); + + if (!solidbg) + { + V_DrawFixedPatch(0, 0, FRACUNIT, 0, back_pause, NULL); + } + } +} + void M_DrawOptionsMovingButton(void) { patch_t *butt = W_CachePatchName("OPT_BUTT", PU_CACHE); diff --git a/src/menus/options-video-colorprofile.c b/src/menus/options-video-colorprofile.c index 56ca88aadc8dc7a79559b889357e542f49931eea..d9a9065048f4cafcede8f89995f05aa4174f00cc 100644 --- a/src/menus/options-video-colorprofile.c +++ b/src/menus/options-video-colorprofile.c @@ -18,10 +18,10 @@ menuitem_t OPTIONS_VideoColorProfile[] = { - {IT_STRING | IT_CVAR, "Global Saturation", "Reduce the saturation of the displayed image.", + {IT_STRING | IT_CVAR, "Saturation", "Reduce the saturation of the displayed image.", NULL, {.cvar = &cv_globalsaturation}, 0, 0}, - {IT_STRING | IT_CVAR, "Global Gamma", "Increase or decrease the brightness of the displayed image.", + {IT_STRING | IT_CVAR, "Gamma", "Increase or decrease the brightness of the displayed image.", NULL, {.cvar = &cv_globalgamma}, 0, 0}, {IT_NOTHING|IT_SPACE, NULL, NULL, @@ -30,73 +30,73 @@ menuitem_t OPTIONS_VideoColorProfile[] = {IT_HEADER, "Red...", NULL, NULL, {NULL}, 0, 0}, - {IT_STRING | IT_CVAR, "Red Saturation", "Reduce the saturation of red in the displayed image.", + {IT_STRING | IT_CVAR, "Saturation", "Reduce the saturation of red in the displayed image.", NULL, {.cvar = &cv_rsaturation}, 0, 0}, - {IT_STRING | IT_CVAR, "Red Gamma", "Increase or decrease the brightness of red in the displayed image.", + {IT_STRING | IT_CVAR, "Gamma", "Increase or decrease the brightness of red in the displayed image.", NULL, {.cvar = &cv_rgamma}, 0, 0}, - {IT_STRING | IT_CVAR, "Red Hue", "Adjust the hue of red in the displayed image.", + {IT_STRING | IT_CVAR, "Hue", "Adjust the hue of red in the displayed image.", NULL, {.cvar = &cv_rhue}, 0, 0}, {IT_HEADER, "Yellow...", NULL, NULL, {NULL}, 0, 0}, - {IT_STRING | IT_CVAR, "Yellow Saturation", "Reduce the saturation of yellow in the displayed image.", + {IT_STRING | IT_CVAR, "Saturation", "Reduce the saturation of yellow in the displayed image.", NULL, {.cvar = &cv_ysaturation}, 0, 0}, - {IT_STRING | IT_CVAR, "Yellow Gamma", "Increase or decrease the brightness of yellow in the displayed image.", + {IT_STRING | IT_CVAR, "Gamma", "Increase or decrease the brightness of yellow in the displayed image.", NULL, {.cvar = &cv_ygamma}, 0, 0}, - {IT_STRING | IT_CVAR, "Yellow Hue", "Adjust the hue of yellow in the displayed image.", + {IT_STRING | IT_CVAR, "Hue", "Adjust the hue of yellow in the displayed image.", NULL, {.cvar = &cv_yhue}, 0, 0}, {IT_HEADER, "Green...", NULL, NULL, {NULL}, 0, 0}, - {IT_STRING | IT_CVAR, "Green Saturation", "Reduce the saturation of green in the displayed image.", + {IT_STRING | IT_CVAR, "Saturation", "Reduce the saturation of green in the displayed image.", NULL, {.cvar = &cv_gsaturation}, 0, 0}, - {IT_STRING | IT_CVAR, "Green Gamma", "Increase or decrease the brightness of green in the displayed image.", + {IT_STRING | IT_CVAR, "Gamma", "Increase or decrease the brightness of green in the displayed image.", NULL, {.cvar = &cv_ggamma}, 0, 0}, - {IT_STRING | IT_CVAR, "Green Hue", "Adjust the hue of green in the displayed image.", + {IT_STRING | IT_CVAR, "Hue", "Adjust the hue of green in the displayed image.", NULL, {.cvar = &cv_ghue}, 0, 0}, {IT_HEADER, "Cyan...", NULL, NULL, {NULL}, 0, 0}, - {IT_STRING | IT_CVAR, "Cyan Saturation", "Reduce the saturation of cyan in the displayed image.", + {IT_STRING | IT_CVAR, "Saturation", "Reduce the saturation of cyan in the displayed image.", NULL, {.cvar = &cv_csaturation}, 0, 0}, - {IT_STRING | IT_CVAR, "Cyan Gamma", "Increase or decrease the brightness of cyan in the displayed image.", + {IT_STRING | IT_CVAR, "Gamma", "Increase or decrease the brightness of cyan in the displayed image.", NULL, {.cvar = &cv_cgamma}, 0, 0}, - {IT_STRING | IT_CVAR, "Cyan Hue", "Adjust the hue of cyan in the displayed image.", + {IT_STRING | IT_CVAR, "Hue", "Adjust the hue of cyan in the displayed image.", NULL, {.cvar = &cv_chue}, 0, 0}, {IT_HEADER, "Blue...", NULL, NULL, {NULL}, 0, 0}, - {IT_STRING | IT_CVAR, "Blue Saturation", "Reduce the saturation of blue in the displayed image.", + {IT_STRING | IT_CVAR, "Saturation", "Reduce the saturation of blue in the displayed image.", NULL, {.cvar = &cv_bsaturation}, 0, 0}, - {IT_STRING | IT_CVAR, "Blue Gamma", "Increase or decrease the brightness of blue in the displayed image.", + {IT_STRING | IT_CVAR, "Gamma", "Increase or decrease the brightness of blue in the displayed image.", NULL, {.cvar = &cv_bgamma}, 0, 0}, - {IT_STRING | IT_CVAR, "Blue Hue", "Adjust the hue of blue in the displayed image.", + {IT_STRING | IT_CVAR, "Hue", "Adjust the hue of blue in the displayed image.", NULL, {.cvar = &cv_bhue}, 0, 0}, {IT_HEADER, "Magenta...", NULL, NULL, {NULL}, 0, 0}, - {IT_STRING | IT_CVAR, "Magenta Saturation", "Reduce the saturation of magenta in the displayed image.", + {IT_STRING | IT_CVAR, "Saturation", "Reduce the saturation of magenta in the displayed image.", NULL, {.cvar = &cv_msaturation}, 0, 0}, - {IT_STRING | IT_CVAR, "Magenta Gamma", "Increase or decrease the brightness of magenta in the displayed image.", + {IT_STRING | IT_CVAR, "Gamma", "Increase or decrease the brightness of magenta in the displayed image.", NULL, {.cvar = &cv_mgamma}, 0, 0}, - {IT_STRING | IT_CVAR, "Magenta Hue", "Adjust the hue of magenta in the displayed image.", + {IT_STRING | IT_CVAR, "Hue", "Adjust the hue of magenta in the displayed image.", NULL, {.cvar = &cv_mhue}, 0, 0}, }; @@ -106,13 +106,13 @@ menu_t OPTIONS_VideoColorProfileDef = { &OPTIONS_VideoDef, 0, OPTIONS_VideoColorProfile, - 48, 80-8, - SKINCOLOR_COLORPROFILE, 0, + 96, 80-8, + SKINCOLOR_WHITE, 0, MBF_DRAWBGWHILEPLAYING, NULL, 2, 5, M_DrawGenericOptions, - M_DrawOptionsCogs, + M_DrawOptionsColorProfile, M_OptionsTick, NULL, NULL,