aboutsummaryrefslogtreecommitdiff
path: root/engines/glk/frotz
diff options
context:
space:
mode:
authorPaul Gilbert2019-01-05 18:00:17 -0800
committerPaul Gilbert2019-01-05 18:00:17 -0800
commitcde7a021644774262f25d833303507ca180d8508 (patch)
treeb4b303aaec8848bf819158c1fe08afab65396b0d /engines/glk/frotz
parent81541a5f049c4dd8ec10a9c13b163cf478bdc921 (diff)
downloadscummvm-rg350-cde7a021644774262f25d833303507ca180d8508.tar.gz
scummvm-rg350-cde7a021644774262f25d833303507ca180d8508.tar.bz2
scummvm-rg350-cde7a021644774262f25d833303507ca180d8508.zip
GLK: FROTX: Draw pictures at the correct position
Diffstat (limited to 'engines/glk/frotz')
-rw-r--r--engines/glk/frotz/glk_interface.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/engines/glk/frotz/glk_interface.cpp b/engines/glk/frotz/glk_interface.cpp
index cf90ddc93e..959ab31064 100644
--- a/engines/glk/frotz/glk_interface.cpp
+++ b/engines/glk/frotz/glk_interface.cpp
@@ -498,11 +498,15 @@ void GlkInterface::showBeyondZorkTitle() {
}
void GlkInterface::os_draw_picture(int picture, const Common::Point &pos) {
- glk_image_draw(_wp._background, picture, pos.x - 1, pos.y - 1);
+ glk_image_draw(_wp._background, picture,
+ (pos.x - 1) * g_conf->_monoInfo._cellW,
+ (pos.y - 1) * g_conf->_monoInfo._cellH);
}
void GlkInterface::os_draw_picture(int picture, const Common::Rect &r) {
- glk_image_draw_scaled(_wp._background, picture, r.left, r.top, r.width(), r.height());
+ Point cell(g_conf->_monoInfo._cellW, g_conf->_monoInfo._cellH);
+ glk_image_draw_scaled(_wp._background, picture, (r.left - 1) * cell.x, (r.top - 1) * cell.y,
+ r.width() * cell.x, r.height() * cell.y);
}
zchar GlkInterface::os_read_key(int timeout, bool show_cursor) {