← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #264958]: Count number of same images that are horizontally parallel in the screen

 

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

    Status: Open => Answered

RaiMan proposed the following answer:
again this has nothing to do with SikuliX, it is Python basics list
handling and hence can be found in the Python docs or any tutorial, that
talks about list handling.

--- sorts the matches from top left, to bottom right, am I right?
surely not.
after the sort, the first element will be that with the smallest m.y value and the last element will be that with the largest m.y value. Usually with sorting when two matches have the same m.y value, the sequence is either unpredictable or unchanged.
I do not know, how Python sorted() handles that.

I do not have the time currently to solve that, but you have to turn the
list into a 2-dimensional list somehow.

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