Closed rishavsingla closed 3 years ago
You need to edit (decrease) some values in scanlibrary -> src -> main -> jni -> scan.cpp scroll down or find (Ctrl + F) and search for BW scrol little bit down you will see these lines
// cvtColor(mbgra, dst, CV_BGR2GRAY);
float alpha = 2.2;
float beta = 0;
float gama = 2.2;
dst.convertTo(dst, -1, gama, beta);
threshold(dst,dst,0,255,THRESH_BINARY | THRESH_OTSU);
Edit them and test up to best levels I have edited on my own but these are not best values
I have made changes to above values, but they are not visible in the app. I have even tried cleaning the project.
You should do an NDK build after changing the scan.cpp
I am new to ndk build. Can you please tell me how to do it?
@jhansireddy
I tried B&W filter. It does not work for me. Black Ink spread whereever the image is. So please help me