-
Notifications
You must be signed in to change notification settings - Fork 9.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
peculiarities when running text2image on windows #380
Comments
fixes some of the windows issue with text2image, see #380
None of these issues has been solved. At least the first one probably affects Tesseract running in MinGW and Mac.
https://github.com/GNOME/pango/blob/master/pango/pangocairo-fontmap.c#L48 Something like this should be put in
Should be tested on Mac and MinGW before committing this code. |
I think this issue should be reopened. |
AFAIK vidiecan is using VS. Is there any report from mingw users? |
He fixed number (1) in his list in one place in the code. That piece of code did cause a crash on Windows+VS, MinGW(64) and Mac. |
Here is the problematic line: You need to use |
The dotted_circle changes in #381 caused problems (in Linux at least). |
@vidiecan : Are points 2. and 3. still valid? If yes, do you have PR for it? |
fixes some of the windows issue with text2image, see tesseract-ocr#380
fixes some of the windows issue with text2image, see tesseract-ocr#380
fixes some of the windows issue with text2image, see tesseract-ocr#380
fixes some of the windows issue with text2image, see tesseract-ocr#380
The relevant code was rewritten in Tesseract 5.0. Do you know if all the issues that were mentioned by the OP were solved? |
No, I don't know that and would have to run tests first. @vidiecan, did you test with the latest installer for Windows? |
(this is more of a comment than an issue but more issues can follow and the discussion might be useful; nevertheless, it might be closed after the PR for 1. )
fc
backend e.g,:tesseract/training/pango_font_info.cpp
Line 356 in ba2ea39
but if pango is compiled with win32 support, you get the win32 font map first
and nasty crashes follow because of the wrong reinterpret cast.
Fast Solution: specify
fc
backendSolution: a simple patch will follow that fixes the behaviour for, at least, the most important functionality.
2. If fontconfig is linked as dll, putenv does not get propagated to fontconfig
tesseract/training/pango_font_info.cpp
Line 151 in ba2ea39
Solution: specify it as environmental variable
3. You cannot use disk paths (e.g., c:) in
FONTCONFIG_PATH
because fontconfig strips slashes from path (FcStrCanonAbsoluteFilename) and then useswithout the slash and that function, interestingly, behaves like this
Solution: specify a sane directory
The text was updated successfully, but these errors were encountered: