From 8564e125549d64c0f8ecbee13c96d5be7373df60 Mon Sep 17 00:00:00 2001 From: rubidium Date: Wed, 26 Sep 2007 19:27:29 +0000 Subject: (svn r11174) -Codechange: add possibility to show the bounding boxes of sprites using CTRL-B so one can get a better understanding of the used bounding boxes to fix the glitches that still exist. Patch by frosch. Note that this is not completely glitch free, bounding boxes sometimes aren't removed properly. This is due to the fact that the bounding boxes sometimes are larger than the sprite, which causes a smaller part than the bounding box to be redrawn. This is NOT a bug, but a known implementation limit as we do not want to slow down normal games so the debug graphics are always 100% correct. --- src/gfx.h | 1 + 1 file changed, 1 insertion(+) (limited to 'src/gfx.h') diff --git a/src/gfx.h b/src/gfx.h index f54c1fcd9..38d4b3052 100644 --- a/src/gfx.h +++ b/src/gfx.h @@ -268,6 +268,7 @@ void DrawStringRightAlignedUnderline(int x, int y, StringID str, uint16 color); void GfxFillRect(int left, int top, int right, int bottom, int color); void GfxDrawLine(int left, int top, int right, int bottom, int color); +void DrawBox(int x, int y, int dx1, int dy1, int dx2, int dy2, int dx3, int dy3); BoundingRect GetStringBoundingBox(const char *str); uint32 FormatStringLinebreaks(char *str, int maxw); -- cgit v1.2.3-54-g00ecf