From 3e5a20c5047db227e4b6851bf0db90807d9d100e Mon Sep 17 00:00:00 2001 From: "h@di" Date: Fri, 3 Aug 2018 17:51:09 +0430 Subject: [PATCH] Fix bug of not processing last row & column of buckets Fix #25 --- src/main/cpp/tiv.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/cpp/tiv.cpp b/src/main/cpp/tiv.cpp index 8a04581..d63897a 100644 --- a/src/main/cpp/tiv.cpp +++ b/src/main/cpp/tiv.cpp @@ -368,8 +368,8 @@ void emitCodepoint(int codepoint) { void emit_image(const cimg_library::CImg & image, int flags) { - for (int y = 0; y < image.height() - 8; y += 8) { - for (int x = 0; x < image.width() - 4; x += 4) { + for (int y = 0; y <= image.height() - 8; y += 8) { + for (int x = 0; x <= image.width() - 4; x += 4) { CharData charData = flags & FLAG_NOOPT ? getCharData(image, x, y, 0x2584, 0x0000ffff) : getCharData(image, x, y);