Release Notes
-
Image Capture
- Allows users to capture a screenshot or an active window for translation.
-
Image Preprocessing
- Converts the image to grayscale, thresholds it to binary, denoises it, and sharpens it for better text extraction results.
-
Text Extraction
- Uses the Tesseract OCR library to extract Japanese text from the image. Supports both horizontal and vertical text.
-
Text Translation
- Translates the extracted Japanese text to English using the Google Cloud Translate API.
-
HTML Entity Decoding
- Decodes HTML entities in the translated text for better readability.
Dependencies
- Tesseract OCR
- OpenCV
- Google Cloud Translate API
- cURL
- nlohmann/json
- Boost
- stb_image_write
Usage
- Clone the repository and open the project in Visual Studio.
- Install the required dependencies.
- Obtain a Google Cloud Translate API key.
- Press 1 for active window capture or 2 to capture a screenshot using click and drag method (Works best for Emulators)
- View the translated text in the console.
License
MIT License
Disclaimer
- This application is far from complete and inaccuracies in translation and text extraction are normal. It's intended for personal use and should not be relied upon for critical tasks.