From 05b8deb22af80f6fdd0d669538c04d686633bfcf Mon Sep 17 00:00:00 2001 From: "Carl.Kenner" Date: Wed, 27 May 2009 18:40:32 +0000 Subject: [PATCH] Fix for issue 102. Colour can be turned on and off freely. --- source/ngc/menu.cpp | 4 ++++ source/ngc/vbasupport.cpp | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/source/ngc/menu.cpp b/source/ngc/menu.cpp index 3c6d9fd..74aa89f 100644 --- a/source/ngc/menu.cpp +++ b/source/ngc/menu.cpp @@ -47,8 +47,10 @@ GuiImageData * pointer[4]; static int MenuPalette(); void gbSetPalette(u32 RRGGBB[]); +void StopColorizing(); extern char RomTitle[17]; + static GuiButton * btnLogo = NULL; static GuiImage * gameScreenImg = NULL; static GuiImage * bgImg = NULL; @@ -2778,6 +2780,8 @@ static int MenuSettingsVideo() case 5: if (GCSettings.colorize) GCSettings.colorize = 0; else GCSettings.colorize = 1; + if (GCSettings.colorize) LoadPalette(RomTitle); + else StopColorizing(); break; case 6: diff --git a/source/ngc/vbasupport.cpp b/source/ngc/vbasupport.cpp index 095a176..7c8ed39 100644 --- a/source/ngc/vbasupport.cpp +++ b/source/ngc/vbasupport.cpp @@ -792,7 +792,8 @@ static void gbApplyPerImagePreferences() // look for matching palettes if a monochrome gameboy game // (or if a Super Gameboy game, but the palette will be ignored later in that case) if ((Colour != 0x80) && (Colour != 0xC0)) { - LoadPalette(RomTitle); + if (GCSettings.colorize) LoadPalette(RomTitle); + else StopColorizing(); } }