python-imagesearch icon indicating copy to clipboard operation
python-imagesearch copied to clipboard

No image color verification

Open cola6969 opened this issue 6 years ago • 5 comments

cola6969 avatar Dec 20 '19 11:12 cola6969

Indeed, images are converted to grey in order to speed up search. I don't have the time right now but when I'll do maintenance I'll add the option to check colors

drov0 avatar Dec 20 '19 11:12 drov0

@drov0 Ok ;C but can we do this with color verification? Because in my test i have two dots with two different colors.

cola6969 avatar Dec 20 '19 11:12 cola6969

Came here looking for this issue as I am also experiencing it. Basically if you have a button with a default disabled state, (which is typically gray), and is a different color when enabled/active, the library will detect the disabled button right away but what we are searching for is the colorful active button. I would imagine this must be a common scenario to encounter

NoPantsPirate avatar Apr 15 '20 14:04 NoPantsPirate

So I've gotten around this by using the included pyautogui.locate() method. I've set an optional parameter for color to make use of it instead of the existing route. I'll tidy it up and consider a PR

NoPantsPirate avatar Apr 16 '20 12:04 NoPantsPirate

Cool ! that would be nice

drov0 avatar Apr 17 '20 15:04 drov0