aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/kyra/eobcommon.h2
-rw-r--r--engines/kyra/gui_eob.cpp20
2 files changed, 11 insertions, 11 deletions
diff --git a/engines/kyra/eobcommon.h b/engines/kyra/eobcommon.h
index 810b792eb2..8d740f1f4d 100644
--- a/engines/kyra/eobcommon.h
+++ b/engines/kyra/eobcommon.h
@@ -765,6 +765,8 @@ protected:
uint8 _charExchangeSwap;
bool _configHpBarGraphs;
+ Graphics::Surface _thumbNail;
+
// text
void setupDialogueButtons(int presetfirst, int numStr, va_list &args);
void initDialogueSequence();
diff --git a/engines/kyra/gui_eob.cpp b/engines/kyra/gui_eob.cpp
index cdc5fba5c1..eaefa50c1e 100644
--- a/engines/kyra/gui_eob.cpp
+++ b/engines/kyra/gui_eob.cpp
@@ -777,12 +777,20 @@ int EoBCoreEngine::clickedCamp(Button *button) {
}
_screen->copyPage(0, 7);
+
+ // Create a thumbnail from the screen for a possible savegame.
+ // This ensures that all special rendering (EGA dithering, 16bit rendering, Japanese font rendering) will be visible on the thumbnail.
+ ::createThumbnailFromScreen(&_thumbNail);
+
_screen->copyRegion(0, 120, 0, 0, 176, 24, 0, 12, Screen::CR_NO_P_CHECK);
_gui->runCampMenu();
_screen->copyRegion(0, 0, 0, 120, 176, 24, 12, 2, Screen::CR_NO_P_CHECK);
_screen->setScreenDim(cd);
+
+ _thumbNail.free();
+
drawScene(0);
for (int i = 0; i < 6; i++)
@@ -2645,17 +2653,7 @@ bool GUI_EoB::transferFileMenu(Common::String &targetName, Common::String &selec
}
void GUI_EoB::createScreenThumbnail(Graphics::Surface &dst) {
- uint8 *screenPal = new uint8[768];
- _screen->getRealPalette(0, screenPal);
- uint16 width = Screen::SCREEN_W;
- uint16 height = Screen::SCREEN_H;
- if (_vm->gameFlags().useHiRes) {
- width <<= 1;
- height <<= 1;
- }
-
- ::createThumbnail(&dst, _screen->getCPagePtr(7), width, height, screenPal);
- delete[] screenPal;
+ dst.copyFrom(_vm->_thumbNail);
}
void GUI_EoB::simpleMenu_initMenuItemsMask(int menuId, int maxItem, int32 menuItemsMask, int itemOffset) {