1

I'm trying to build an app like StrokePlus using bitmap to be able to check between two images if they're the same visually. The user can draw on the whole screen.

For now when the user draw a tiny L (12x56) or a big L (177x177) it gets transformed in a bitmap by the size. But now i've to compare with a 25x25 bitmap with a L shape draw on it.

I've tried to resize the user draw to 25x25 and compare them but i'm loosing too much pixel when resizing to get good results.

I also tried to resize it multiple time (ex : 50x50 to 40x40 to 30x30) I'm more precise but still not enough

How can i compare my Userdraw and bitmapdefined to be sure they're very similar ?

Example of user draw : UserDraw

Example of L shape 25x25 : BitmapDefined

Edit : Changed image color

Edit2 : Added new try

  • You know what's missing here? – ProgrammingLlama May 06 '22 at 08:08
  • 1
    Visually comparing images is a fairly tricky subject. The human brain is *great* at pattern recognition, computers not so much. So you probably need to simplify the problem quite a bit, and describe how you intend to approach the problem, what you have tried, and what does not work in greater detail. – JonasH May 06 '22 at 08:25
  • I don't think so – LeandroCamilo May 06 '22 at 08:26
  • I've used [this](https://stackoverflow.com/questions/35151067/algorithm-to-compare-two-images-in-c-sharp) to compare them with the same size but i dont have enough pixel similar to get good result – LeandroCamilo May 06 '22 at 08:33
  • This is one of the topics that seem very trivial at the first glance, but quite difficult in reality. Even though it is closed, this question has some answers that can be a starting point for you: https://stackoverflow.com/questions/25977/how-can-i-measure-the-similarity-between-two-images – mcy May 06 '22 at 08:46
  • You forgot to ask a question. – Palle Due May 06 '22 at 09:03

0 Answers0