diff options
author | Filippos Karapetis | 2009-10-06 21:41:20 +0000 |
---|---|---|
committer | Filippos Karapetis | 2009-10-06 21:41:20 +0000 |
commit | e4c3cbbd791962118ee6aedd47864f1aa2ff49c8 (patch) | |
tree | 202f2e55be056bed1d1d1c7e8d337fbb4026add4 /engines/sci/gfx/gfx_driver.cpp | |
parent | f533e0ad9e1704a67397ffdf0117f9a693ee79c9 (diff) | |
download | scummvm-rg350-e4c3cbbd791962118ee6aedd47864f1aa2ff49c8.tar.gz scummvm-rg350-e4c3cbbd791962118ee6aedd47864f1aa2ff49c8.tar.bz2 scummvm-rg350-e4c3cbbd791962118ee6aedd47864f1aa2ff49c8.zip |
Reverted the priority line drawing code in the current GUI (with some cleanup) to use the FreeSCI line drawing code, which was removed in #44692. Apparently, Sierra's implementation of the Bresenham line drawing algorithm was a bit different than ours, which resulted in problems with flood fill
svn-id: r44721
Diffstat (limited to 'engines/sci/gfx/gfx_driver.cpp')
-rw-r--r-- | engines/sci/gfx/gfx_driver.cpp | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/engines/sci/gfx/gfx_driver.cpp b/engines/sci/gfx/gfx_driver.cpp index 1d8eb6f01f..0010983779 100644 --- a/engines/sci/gfx/gfx_driver.cpp +++ b/engines/sci/gfx/gfx_driver.cpp @@ -59,13 +59,6 @@ static void drawProc(int x, int y, int c, void *data) { memcpy(p + (y * drv->_screen->_width * drv->getMode()->scaleFactor + x), &col, 1); } -static void drawProcPriority(int x, int y, int c, void *data) { - GfxDriver *drv = (GfxDriver *)data; - byte *p = drv->_screen->_priorityScreen; - uint8 col = c; - memcpy(p + (y * drv->_screen->_width + x), &col, 1); -} - void GfxDriver::drawLine(Common::Point start, Common::Point end, gfx_color_t color, gfx_line_mode_t line_mode, gfx_line_style_t line_style) { uint32 scolor = color.visual.getParentIndex(); @@ -87,7 +80,7 @@ void GfxDriver::drawLine(Common::Point start, Common::Point end, gfx_color_t col Graphics::drawLine(nstart.x, nstart.y, nend.x, nend.y, scolor, drawProc, this); if (color.mask & GFX_MASK_PRIORITY) { - Graphics::drawLine(nstart.x, nstart.y, nend.x, nend.y, color.priority, drawProcPriority, this); + gfx_draw_line_buffer(_screen->_priorityScreen, 1, 1, nstart, nend, color.priority); } } } |