projects
/
swan-dev
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
30704f1
)
tools: bmp2tiles correct substraction of columns
author
Robin Krens
<robin@robinkrens.nl>
Tue, 14 Jun 2022 18:53:54 +0000
(20:53 +0200)
committer
Robin Krens
<robin@robinkrens.nl>
Tue, 14 Jun 2022 18:53:54 +0000
(20:53 +0200)
tools/bmp2tiles/bmp2tiles.c
patch
|
blob
|
history
diff --git
a/tools/bmp2tiles/bmp2tiles.c
b/tools/bmp2tiles/bmp2tiles.c
index
b005365
..
380481e
100644
(file)
--- a/
tools/bmp2tiles/bmp2tiles.c
+++ b/
tools/bmp2tiles/bmp2tiles.c
@@
-88,7
+88,7
@@
void generate_4bpp_tile(unsigned char *buf, swan_gfx_t * gfx,
if (!packed)
ptr += 8;
else {
- ptr += (8 * (gfx->
row
_tiles-1));
+ ptr += (8 * (gfx->
col
_tiles-1));
}
}
}
@@
-170,7
+170,7
@@
int main(int argc, char *argv[])
gfx->data += 8; /* next column */
//printf("\n");
}
- gfx->data += (gfx->col_tiles * 64) -
16
;
+ gfx->data += (gfx->col_tiles * 64) -
(8 * gfx->col_tiles)
;
}
palstream = fopen("out.pal", "w");