Added vdp color overrides.
All checks were successful
Run test asserts / Test-Asserts (push) Successful in -10s

This commit is contained in:
Willem Cazander 2024-06-30 16:13:44 +02:00
parent d23db7734b
commit 7734175826
5 changed files with 34 additions and 8 deletions

View file

@ -177,4 +177,5 @@ Current set is WIP.
* Doesn't work on windows * Doesn't work on windows
* Missing C and mixed support * Missing C and mixed support
* If no SDL or SDLGL-PP than screenshots or videos don't work * If no SDL or SDLGL-PP than screenshots or videos don't work
* boot_exec_color_vdp does not work on MSX1 vdp

View file

@ -51,7 +51,7 @@ define mb_autoexec_write_default
$(if $(filter 40,$(2)),$(call mb_autoexec_append_cmd,$(1),mode 40),$(call mb_autoexec_append_cmd,$(1),mode 80)) $(if $(filter 40,$(2)),$(call mb_autoexec_append_cmd,$(1),mode 40),$(call mb_autoexec_append_cmd,$(1),mode 80))
$(call mb_autoexec_append_echo,$(1),==== MSXBUILD ====) $(call mb_autoexec_append_echo,$(1),==== MSXBUILD ====)
$(if $(filter 40,$(2)),$(call mb_autoexec_append_echo,$(1),Boot mode 40),$(call mb_autoexec_append_echo,$(1),Boot mode 80)) $(if $(filter 40,$(2)),$(call mb_autoexec_append_echo,$(1),Boot mode 40),$(call mb_autoexec_append_echo,$(1),Boot mode 80))
$(call mb_autoexec_append_cmd,$(1),omsxctl boot_exec_color_dark) $(call mb_autoexec_append_cmd,$(1),omsxctl boot_exec_color_vdp)
$(if $(filter on,$(MB_FLIGHT_VIDEO)),$(call mb_autoexec_append_save_video,$(1))) $(if $(filter on,$(MB_FLIGHT_VIDEO)),$(call mb_autoexec_append_save_video,$(1)))
$(call mb_autoexec_append_cmd,$(1),omsxctl fail_after $(MB_AUTOEXEC_STARTUP_TIMEOUT) seconds failed_exec $(MB_AUTOEXEC_STARTUP_EXITCODE)) $(call mb_autoexec_append_cmd,$(1),omsxctl fail_after $(MB_AUTOEXEC_STARTUP_TIMEOUT) seconds failed_exec $(MB_AUTOEXEC_STARTUP_EXITCODE))
$(if $(filter on,$(MB_AUTOEXEC_VERSION)),$(call mb_autoexec_append_cmd,$(1),ver)) $(if $(filter on,$(MB_AUTOEXEC_VERSION)),$(call mb_autoexec_append_cmd,$(1),ver))

View file

@ -9,6 +9,8 @@ MB_OPENMSX_SCALE_FACTOR ?= 3
MB_OPENMSX_THROTTLE ?= off MB_OPENMSX_THROTTLE ?= off
MB_OPENMSX_HEADLESS ?= on MB_OPENMSX_HEADLESS ?= on
MB_OPENMSX_RENDERER ?= SDLGL-PP MB_OPENMSX_RENDERER ?= SDLGL-PP
MB_OPENMSX_VDP_FG ?= 151
MB_OPENMSX_VDP_BG ?= 000
define mb_openmsx_setup define mb_openmsx_setup
$(if $(wildcard $(1)-omsx),,$(call mb_mkdir,$(1)-omsx)) $(if $(wildcard $(1)-omsx),,$(call mb_mkdir,$(1)-omsx))
@ -43,6 +45,8 @@ define _mb_openmsx_run
NF_PREFIX=$(MB_FLIGHT_PREFIX) \ NF_PREFIX=$(MB_FLIGHT_PREFIX) \
NF_SEPERATOR=$(MB_FLIGHT_SEPERATOR) \ NF_SEPERATOR=$(MB_FLIGHT_SEPERATOR) \
NF_RECORD_FLAG=$(MB_FLIGHT_RECORD_FLAG) \ NF_RECORD_FLAG=$(MB_FLIGHT_RECORD_FLAG) \
VDP_FG=$(MB_OPENMSX_VDP_FG) \
VDP_BG=$(MB_OPENMSX_VDP_BG) \
OPENMSX_HOME="$(1)-omsx" \ OPENMSX_HOME="$(1)-omsx" \
$(PATH_OPENMSX)/openmsx \ $(PATH_OPENMSX)/openmsx \
-machine $(2) \ -machine $(2) \

View file

@ -1,6 +1,6 @@
# boot_exec -- Helper command to autoexec.bat boot scripts. # boot_exec -- Helper commands to autoexec.bat boot scripts.
# #
# Adds the following command to openMSX; # Adds the following commands to openMSX;
# #
# 'boot_exec_color_dark' # 'boot_exec_color_dark'
# Sets the VDP colors to dark color tones. # Sets the VDP colors to dark color tones.
@ -8,11 +8,24 @@
# 'boot_exec_config_info' # 'boot_exec_config_info'
# Displays machine and openMSX version on one line. # Displays machine and openMSX version on one line.
# #
# Supported environment variables by this script;
#
# VDP_FG=111
# Override the default vdp foreground color.
#
# VDP_BG=369
# Override the default vdp background color.
#
proc boot_exec_color_dark {} { set boot_exec_color_vdp_fg "777"
setcolor 4 000 set boot_exec_color_vdp_bg "000"
setcolor 15 777
return "Boot color dark" proc boot_exec_color_vdp {} {
global boot_exec_color_vdp_fg
global boot_exec_color_vdp_bg
setcolor 15 $boot_exec_color_vdp_fg
setcolor 4 $boot_exec_color_vdp_bg
return "Boot color vdp fg $boot_exec_color_vdp_fg bg $boot_exec_color_vdp_bg"
} }
proc boot_exec_config_info {} { proc boot_exec_config_info {} {
@ -22,3 +35,11 @@ proc boot_exec_config_info {} {
append result [openmsx_info version] append result [openmsx_info version]
return $result return $result
} }
if {[info exists ::env(VDP_FG)] && ([string trim $::env(VDP_FG)] != "")} {
set boot_exec_color_vdp_fg [string trim $::env(VDP_FG)]
}
if {[info exists ::env(VDP_BG)] && ([string trim $::env(VDP_BG)] != "")} {
set boot_exec_color_vdp_bg [string trim $::env(VDP_BG)]
}

View file

@ -1,6 +1,6 @@
# night_flight -- Setup the travel for night flight black box recorder for build pipelines. # night_flight -- Setup the travel for night flight black box recorder for build pipelines.
# #
# Adds the following command to openMSX; # Adds the following commands to openMSX;
# #
# 'night_flight_save_screenshot' # 'night_flight_save_screenshot'
# Takes an screenshot with optional prefix parameter. # Takes an screenshot with optional prefix parameter.