From 83e2570d3c8da9920d66a00c4bdf5650fe1b3336 Mon Sep 17 00:00:00 2001 From: Akshay Nair Date: Wed, 25 Dec 2024 22:33:03 +0530 Subject: Parallel ocr evaluation for sections of screen + many refactorings --- include/image.h | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 include/image.h (limited to 'include/image.h') diff --git a/include/image.h b/include/image.h new file mode 100644 index 0000000..ecbc255 --- /dev/null +++ b/include/image.h @@ -0,0 +1,19 @@ +#pragma once +#include + +namespace image { +// Preprocessing configuration +static const float contrast = 0.3; +static const float sharpness = 0.7; +static const float scaleFactor = 1; +static const float grayscaleWeightRed = 0.114; +static const float grayscaleWeightGreen = 0.587; +static const float grayscaleWeightBlue = 0.299; + +Pix *loadImage(const char *imagePath); +} // namespace image + +#define INLINE_IMAGE_PROC(process) \ + temp = process; \ + pixDestroy(image); \ + *image = temp; -- cgit v1.3.1