[Scummvm-cvs-logs] SF.net SVN: scummvm:[39704] scummvm/trunk/engines/sci/engine/kgraphics.cpp

thebluegr at users.sourceforge.net thebluegr at users.sourceforge.net
Thu Mar 26 22:52:04 CET 2009


Revision: 39704
          http://scummvm.svn.sourceforge.net/scummvm/?rev=39704&view=rev
Author:   thebluegr
Date:     2009-03-26 21:52:04 +0000 (Thu, 26 Mar 2009)

Log Message:
-----------
Added a note about the potential invalid rectangles created when drawing lines

Modified Paths:
--------------
    scummvm/trunk/engines/sci/engine/kgraphics.cpp

Modified: scummvm/trunk/engines/sci/engine/kgraphics.cpp
===================================================================
--- scummvm/trunk/engines/sci/engine/kgraphics.cpp	2009-03-26 20:24:16 UTC (rev 39703)
+++ scummvm/trunk/engines/sci/engine/kgraphics.cpp	2009-03-26 21:52:04 UTC (rev 39704)
@@ -503,6 +503,11 @@
 		          SKPV(2), SKPV(1), SKPV(4), SKPV(3), SKPV(5), SKPV_OR_ALT(6, -1), SKPV_OR_ALT(7, -1), gfxcolor.mask);
 
 		redraw_port = 1;
+
+		// Note: it's quite possible that the coordinates of the line will *not* form a valid rectangle (e.g. it might
+		// have negative width/height). The actual dirty rectangle is constructed in gfxdr_add_dirty().
+		// FIXME/TODO: We need to change the semantics of this call, so that no fake rectangles are used. As it is, it's
+		// not possible change rect_t to Common::Rect, as we assume that Common::Rect forms a *valid* rectangle.
 		ADD_TO_CURRENT_BG_WIDGETS(GFXW(gfxw_new_line(Common::Point(SKPV(2), SKPV(1)), Common::Point(SKPV(4), SKPV(3)),
 		                               gfxcolor, GFX_LINE_MODE_CORRECT, GFX_LINE_STYLE_NORMAL)));
 


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list