summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMatthias Schiffer <mschiffer@universe-factory.net>2015-02-02 01:47:16 +0100
committerMatthias Schiffer <mschiffer@universe-factory.net>2015-02-02 01:47:16 +0100
commit8db3a5b94f2a5d6728c62c7e76653f413f7a786d (patch)
tree46874d3bcc43b4bf85843cb93c16c551403fba5f /src
parent8c1629af42a10ff7e23bb40100a259bf334a9c60 (diff)
downloadMinedMap-8db3a5b94f2a5d6728c62c7e76653f413f7a786d.tar
MinedMap-8db3a5b94f2a5d6728c62c7e76653f413f7a786d.zip
Use DIM constant as PNG dimension
Diffstat (limited to 'src')
-rw-r--r--src/MinedMap.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/MinedMap.cpp b/src/MinedMap.cpp
index 3af634d..371e009 100644
--- a/src/MinedMap.cpp
+++ b/src/MinedMap.cpp
@@ -75,8 +75,8 @@ static void writePNG(const char *filename, const uint32_t data[DIM][DIM]) {
png_init_io(png_ptr, f);
- png_set_IHDR(png_ptr, info_ptr, World::Region::SIZE*World::Chunk::SIZE, World::Region::SIZE*World::Chunk::SIZE,
- 8, PNG_COLOR_TYPE_RGB_ALPHA, PNG_INTERLACE_NONE, PNG_COMPRESSION_TYPE_DEFAULT, PNG_FILTER_TYPE_DEFAULT);
+ png_set_IHDR(png_ptr, info_ptr, DIM, DIM, 8, PNG_COLOR_TYPE_RGB_ALPHA,
+ PNG_INTERLACE_NONE, PNG_COMPRESSION_TYPE_DEFAULT, PNG_FILTER_TYPE_DEFAULT);
uint8_t *row_pointers[World::Region::SIZE*World::Chunk::SIZE];
for (size_t i = 0; i < World::Region::SIZE*World::Chunk::SIZE; i++)