
Ask HN: Unsure which image extraction techniques to utilise - zemanel
For a side project i’m taking a look at how to extract information from Apex Legends (for starters) game play videos. Example screenshot:<p>https:&#x2F;&#x2F;www.gameprime.org&#x2F;wp-content&#x2F;uploads&#x2F;2019&#x2F;02&#x2F;gp-apexlegends-6.jpg<p>There is a log on top right corner and player status on bottom left corner (health&#x2F;shields).<p>Id like to:<p>- extract &lt;player A username&gt; killed &lt;player B username&gt; with &lt;weapon name&gt; (at time mm:ss) from log, and other information displayed on that log<p>- from player health extract health&#x2F;shields percentage (at what time)<p>Also detect game start&#x2F;end screens and possibly extract info from them like which characters compose the current player squads.<p>Apart from OCR, what kind or specific techniques should i learn to implement this ?
======
PaulHoule
If the text is in a predictable position on the screen, this should be easy.

An image processing pipeline like this usually has a filter up front that
drops out the environment and leaves a monochrome image of just the text and
associated graphics. The text is white and is usually on a background that
provides a lot of contrast since it designed to be readable by you!

~~~
zemanel
Yep makes sense. For the OCR part a colleague suggested something like
Tesseract or Google Vision but, what about the shapes, like weapon (type)
symbol on top right and health/shield bar percentages and etc ?

Maybe i should just get started small with the OCR part

~~~
PaulHoule
The weapons symbols are just very big characters.

The health and shield bar percentages could be measured by counting pixels.
For instance you could draw a horizontal line across the bar and see how many
pixels are lit up.

