11 ms·
neat. why not screenshot and tesseract (videos/images/viewport/etc)
by purplecats 23d ago
neat. why not screenshot and tesseract (videos/images/viewport/etc)
- latexr 23d agoProject reasons aside, macOS has perfectly capable, local, native OCR that you can access programmatically, without having to install something else.
- hzwanip 23d agoOCR starts from screenshots though. This only grabs text via accessibility APIs, before rendering or any screenshots.
- latexr 23d agoYes, I know. Like I said: “Project reasons aside”. I’m not suggesting OCR for this, I’m imparting the general information to be used in other situations that in macOS you can OCR without requiring third-party tools.
- hzwanip 23d agoFair! It is actually new and interesting information for me (not into macOS dev)
- Dramatize 23d agoBecause you then have the macOS orange screen sharing warning/icon. I don't really want to record my screen, just the text is enough.
- hetsaraiya 23d agoAgree
- jasonjmcghee 23d agoWhen I built rem, I spent significant effort getting screenshot -> ocr + screenshot -> ffmpeg loop energy efficient, but it definitely is more expensive than accessibility API. You also save a lot of disk space and writes to disk. That being said, you lose the cool swipe to go back in time and search through history and visually see, features. And situations where accessibility isn't supported. And as others have mentioned, built in ocr is definitely better than tesseract.