- Go to https://github.com/microsoft/vcpkg
- For windows user, follow the Quick Start: Windows instruction.
- Press Window+R, type “cmd“.
- In command prompt, type “cd C:/“
- Then, type “git clone https://github.com/microsoft/vcpkg“
(Note: If your GIT is not installed (GIT != Github), please download and install https://git-scm.com/downloads)
or
if your GIT is not install,
you can download the zip file using this link
https://github.com/microsoft/vcpkg/archive/refs/heads/master.zip
Save and Extract to C:/ directory - After git clone is successful or extraction file is done, got back to the command prompt. Type “.\vcpkg\bootstrap-vcpkg.bat“
- Furthermore, type “.\vcpkg\vcpkg install tesseract:x64-windows“
- Wait for around 15-30 minutes for it to install depends on your computer speed.
- After all is install, type “.\vcpkg\vcpkg integrate install“
- Open your C++ project. Right click & select properties on your main project solution.
- go to C/C++ > General > Additional Include Directories
- Linker > General > Additional Library Dependencies
Add
C:\vcpkg\installed\x64-windows\include
C:\vcpkg\installed\x64-windows\include\leptonica
C:\vcpkg\installed\x64-windows\include\tesseract
Add:
13. Linker > Input> Additional Dependencies
https://eddiehexorz.com/opencv-tesseract-ocr-setup-for-c-in-visual-studio/