summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: fac3eb9)
raw | patch | inline | side by side (parent: fac3eb9)
author | buliabyak <buliabyak@users.sourceforge.net> | |
Wed, 5 Sep 2007 02:38:36 +0000 (02:38 +0000) | ||
committer | buliabyak <buliabyak@users.sourceforge.net> | |
Wed, 5 Sep 2007 02:38:36 +0000 (02:38 +0000) |
src/display/sp-canvas.cpp | patch | blob | history |
index 1e7b8051f147a701e8da70a246fa4f6a22487769..57a6ac269b4e84a089ff6cf5a70002c7e37bd6d6 100644 (file)
// Tiles are a way to minimize the number of redraws, eliminating too small redraws.
// The canvas stores a 2D array of ints, each representing a TILE_SIZExTILE_SIZE pixels tile.
// If any part of it is dirtied, the entire tile is dirtied (its int is nonzero) and repainted.
-#define TILE_SIZE 32
+#define TILE_SIZE 16
enum {
RENDERMODE_NORMAL,
The default for now is the strips mode.
*/
- if (bw < bh) {
+ if (bw < bh || bh < 2 * TILE_SIZE) {
int mid = (this_rect.x0 + this_rect.x1) / 2;
// Make sure that mid lies on a tile boundary
mid = (mid / TILE_SIZE) * TILE_SIZE;