0

hi im trying to create a script that will let me pinpoint the location of an image on screen that is nearest to completion

enter image description here

so in the picture above image (2,1) should be picked first

Im clueless at the moment on what libraries to look upon as pyautogui.locateOnScreen I believe only searches for exact match can I ask for opinions on how to possibly implement this the easiest?

*btw the green filled ones should be discarded

Kelv1nG
  • 37
  • 5
  • Your question is quite unclear, but I think you are looking for the largest yellowish contour.... OpenCV `findContours()` springs to mind. – Mark Setchell Apr 27 '20 at 08:11
  • Ok thanks ill take a look at it, yes that is exactly what I want to look for the picture with the most yellow fills – Kelv1nG Apr 27 '20 at 08:13
  • If you change the numbers to suit your yellows (instead of the browns I was using) you can find all yellows like this https://stackoverflow.com/a/50215020/2836621 – Mark Setchell Apr 27 '20 at 08:24
  • Thanks man appreciate, ill post it once I figured it out – Kelv1nG Apr 27 '20 at 08:49

0 Answers0