question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Use OCR for more info during loading screen

See original GitHub issue

Hey there. I’m also a C# developer, and I have been looking into OCR possibilities for locating players position on the loading screen, as well as determining which hero they are playing.

As source, I used your screenshot of HotsStats.

I tried tesseract OCR, which gave me garbage results. I then tried this: https://msdn.microsoft.com/en-us/library/windows/apps/windows.media.ocr.aspx

Unfortunately, it’s for WinRT (windows 8+ apps), but I managed to implement it in a sample console application on my windows 10 machine. I reckon I can implement it on this app, but it will only run on windows 8 or higher.

The results were pretty impressive. Here is the result from running OCR on your screenshot (as one long text string):

Li-Ming Mudak Greymane caspeR Illidö 20 WELCOME TO SKY TEMPLE Link Defend the Temples Guardians will try to wrest control of their temples from your team. Hold them off to keep the temple's power for yourselves! Abathur SpincOck Greymane Re41ity Azmodan Grindex Thrall xUmidumix Zeratul DenBennyyy 24 12 Player Mudak AdrianTony obZen Buja MMR 3253 2151 2050 2750 3988 Link Player Grindex SpincOck Re41ity xUmidumix Den Bennyyy MMR 2065 4019 3067 1588 2170 Average MMR: 2838 Average MMR: 2581 Capture the Temples Temples will periodically activate. Stand within their grounds to capture their power! j 20 AdrianTony Raynor obZen Abathur Buja Hold the Temples Stand firm and the temple will unleash a blistering onslaught on your enemy's forts!

I still have a few reference problems that is causing troubles with some of the types involved, but I also believe these are fixable (I just don’t know how yet).

If you want to test the capabilities of this OCR, without writing code, this website is built upon the same assembly: https://ocr.space/

Issue Analytics

  • State:open
  • Created 8 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
pomacommented, Mar 15, 2016

having heroes and map data at loading screen will allow to create many useful features like showing top builds for your hero and tips how to play with or against certain heroes from hotscounters.com and showing objective timers next to map info

0reactions
Inregocommented, Mar 15, 2016

Hmm… That is true. I do have a lot on my hands at the moment… I could send you the code I have for pre-processing the pictures for good OCR results if you want to pursue down this road. I was planning to use the webservice for doing the actual OCR, as the free api allows quite a lot of requests - and gives you the same information as using the assembly yourself. It has the added advantage that we don’t have to mess around with implementing a WinRT assembly - and still supporting OS lower than Win8.

Read more comments on GitHub >

github_iconTop Results From Across the Web

how to perform OCR on running program window
I need to extract information, text and numbers, from a running program, let's say a game. So I was wondering if there is...
Read more >
Waiting for OCR checkpoint to appear as screen loads
I'm using a OCR checkpoint to wait for a Citrix application and display a login prompt. When the window appears there's a brief...
Read more >
Automatically Detecting Loading / Ending Screens
Quick OCR. The approach used sets a start time, an end time and a step, generates frames for those, then OCR's the frames...
Read more >
OCR sample - Code Samples
Shows how to use the optical character recognition (OCR) API to extract text in the specific language from an image.
Read more >
How to Build Optical Character Recognition (OCR) in Python
Optical character recognition (OCR) is a tool that can recognize text in images. Here's how to build an OCR engine in Python.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found