aboutsummaryrefslogtreecommitdiff
path: root/cpp/libchelleport.cpp
diff options
context:
space:
mode:
authorAkshay Nair <phenax5@gmail.com>2024-12-28 20:27:04 +0530
committerAkshay Nair <phenax5@gmail.com>2024-12-28 20:27:04 +0530
commitb305546950a6742f25023e2ffece423905e1bda8 (patch)
tree279f16bc685d4d3ac90b947dbaa1bfd8ef17265f /cpp/libchelleport.cpp
parent568923344f0941b2771459dd8dbe935ac971a968 (diff)
downloadchelleport-b305546950a6742f25023e2ffece423905e1bda8.tar.gz
chelleport-b305546950a6742f25023e2ffece423905e1bda8.zip
Refactor mode data type
Diffstat (limited to 'cpp/libchelleport.cpp')
-rw-r--r--cpp/libchelleport.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/cpp/libchelleport.cpp b/cpp/libchelleport.cpp
index 5845bc4..53ba64e 100644
--- a/cpp/libchelleport.cpp
+++ b/cpp/libchelleport.cpp
@@ -13,12 +13,12 @@ extern "C" OCRMatch *findWordCoordinates(const char *image_path, int *size) {
OCRMatchSet matches;
MEASURE("OCR", { matches = extractTextMatches(image_path); });
- std::cout << "Match count: " << matches.size() << std::endl;
-
static OCRMatch *ptr = new OCRMatch[matches.size()];
std::copy(matches.begin(), matches.end(), ptr);
*size = matches.size();
+ std::cout << "Match count: " << *size << std::endl;
+
return ptr;
}