← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #186977]: Is non-rectangular matching possible?

 

Question #186977 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/186977

    Status: Open => Answered

RaiMan proposed the following answer:
Allowing patterns with transparency to ignore parts of the image is not
a feature yet (but already a request bug).

The only possibility is to make the captured rectangle so that is
contains as little of the background (less than 20% of the whole area)
as possible.

To be sure you found the right match, you might want to restrict the
region to the area, where your searched image should most probably be.

A bit tricky, but usually it is possible to find a setup of the form

reg.find(Pattern(<some-mostly-unique-image.png>).similar(0.95)

where the 3 parts (reg, some-mostly-unique-image.png and the similarity)
have to be optimized for a reliable result.

-- 
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.