I never felt this satisfied in my entire life,
So I was working on an open-source org where people can come and read books online for free. But they were facing the challenge of making books text selectable with the mouse pointer. But the problem was that their website renders scanned images of the books so it is impossible to select text from it.
So I solved this problem by building a small prototype that could do it. All of the books that they have in their database are having XML files associated with them which contains the coordinates of each word. So the logic was simple - select a rectangular region to pass its coordinates and check whether the coordinates of a word are lying in that rectangular region or not and display them. This trick is helpful because most of the OCR generates a similar XML file.
So if you wish to use this prototype for your own projects - you can check my GitHub repository https://github.com/ishank-dev/...
please star it if you like.

Add Comment