diff --git a/src/k_menu.h b/src/k_menu.h index 116caa793..22cd3e40d 100644 --- a/src/k_menu.h +++ b/src/k_menu.h @@ -462,6 +462,9 @@ extern menu_t OPTIONS_VideoDef; extern menuitem_t OPTIONS_VideoModes[]; extern menu_t OPTIONS_VideoModesDef; +extern menuitem_t OPTIONS_VideoColorProfile[]; +extern menu_t OPTIONS_VideoColorProfileDef; + extern menuitem_t OPTIONS_VideoAdvanced[]; extern menu_t OPTIONS_VideoAdvancedDef; diff --git a/src/menus/CMakeLists.txt b/src/menus/CMakeLists.txt index 80d3c261e..c2e57a66e 100644 --- a/src/menus/CMakeLists.txt +++ b/src/menus/CMakeLists.txt @@ -28,6 +28,7 @@ target_sources(SRB2SDL2 PRIVATE options-sound.cpp options-video-1.c options-video-advanced.c + options-video-colorprofile.c options-video-modes.c play-1.c play-char-select.c diff --git a/src/menus/options-profiles-edit-accessibility.cpp b/src/menus/options-profiles-edit-accessibility.cpp index a4d00c7fa..14dd0643d 100644 --- a/src/menus/options-profiles-edit-accessibility.cpp +++ b/src/menus/options-profiles-edit-accessibility.cpp @@ -137,9 +137,6 @@ menuitem_t OPTIONS_ProfileAccessibility[] = { {IT_STRING | IT_CVAR, "Input Display", "Show virtual controller on the HUD.", NULL, {.cvar = &cv_drawinput}, 0, 0}, - - {IT_STRING | IT_CVAR, "It's a me", "Hi hi hello.", - NULL, {.cvar = &cv_globalsaturation}, 0, 0}, }; menu_t OPTIONS_ProfileAccessibilityDef = { diff --git a/src/menus/options-video-1.c b/src/menus/options-video-1.c index e4965ca29..884121ab1 100644 --- a/src/menus/options-video-1.c +++ b/src/menus/options-video-1.c @@ -36,6 +36,9 @@ menuitem_t OPTIONS_Video[] = {IT_STRING | IT_CVAR, "Screen Effect", "Uses a special effect when displaying the game.", NULL, {.cvar = &cv_scr_effect}, 0, 0}, + + {IT_STRING | IT_SUBMENU, "Color Profile...", "Adjust the color profile of the game's display.", + NULL, {.submenu = &OPTIONS_VideoColorProfileDef}, 0, 0}, {IT_NOTHING|IT_SPACE, NULL, NULL, NULL, {NULL}, 0, 0}, diff --git a/src/menus/options-video-colorprofile.c b/src/menus/options-video-colorprofile.c new file mode 100644 index 000000000..12fd0dbdb --- /dev/null +++ b/src/menus/options-video-colorprofile.c @@ -0,0 +1,120 @@ +// DR. ROBOTNIK'S RING RACERS +//----------------------------------------------------------------------------- +// Copyright (C) 2024 by Kart Krew. +// This file created by Freaky Mutant Man. +// +// This program is free software distributed under the +// terms of the GNU General Public License, version 2. +// See the 'LICENSE' file for more details. +//----------------------------------------------------------------------------- +/// \file menus/options-video-colorprofile.c +/// \brief Color Profile Options + +#include "../k_menu.h" +#include "../v_video.h" // cv_globalgamma +#include "../r_fps.h" // fps cvars + +// color profile menu +menuitem_t OPTIONS_VideoColorProfile[] = +{ + + {IT_STRING | IT_CVAR, "Global 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.", + NULL, {.cvar = &cv_globalgamma}, 0, 0}, + + {IT_NOTHING|IT_SPACE, NULL, NULL, + NULL, {NULL}, 0, 0}, + + {IT_HEADER, "Red...", NULL, + NULL, {NULL}, 0, 0}, + + {IT_STRING | IT_CVAR, "Red 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.", + NULL, {.cvar = &cv_rgamma}, 0, 0}, + + {IT_STRING | IT_CVAR, "Red 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.", + NULL, {.cvar = &cv_ysaturation}, 0, 0}, + + {IT_STRING | IT_CVAR, "Yellow 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.", + 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.", + NULL, {.cvar = &cv_gsaturation}, 0, 0}, + + {IT_STRING | IT_CVAR, "Green 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.", + 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.", + NULL, {.cvar = &cv_csaturation}, 0, 0}, + + {IT_STRING | IT_CVAR, "Cyan 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.", + 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.", + NULL, {.cvar = &cv_bsaturation}, 0, 0}, + + {IT_STRING | IT_CVAR, "Blue 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.", + 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.", + NULL, {.cvar = &cv_msaturation}, 0, 0}, + + {IT_STRING | IT_CVAR, "Magenta 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.", + NULL, {.cvar = &cv_mhue}, 0, 0}, + +}; + +menu_t OPTIONS_VideoColorProfileDef = { + sizeof (OPTIONS_VideoColorProfile) / sizeof (menuitem_t), + &OPTIONS_VideoDef, + 0, + OPTIONS_VideoColorProfile, + 48, 80-8, + SKINCOLOR_LAVENDER, 0, + MBF_DRAWBGWHILEPLAYING, + NULL, + 2, 5, + M_DrawGenericOptions, + M_DrawOptionsCogs, + M_OptionsTick, + NULL, + NULL, + NULL, +};