← Back to team overview

sikuli-driver team mailing list archive

[Question #171253]: Using Regions and Match efficiently

 

New question #171253 on Sikuli:
https://answers.launchpad.net/sikuli/+question/171253

I am trying to code my Sikuli program as efficiently as possible.

If I have already calculated a match (mat) within a region (reg), then is it quicker to click using the region, or not using the region?

#With region reg:
reg.click(mat, 0)

#Without region:
click(mat, 0)

Logically, I could see it either way.  The region will narrow the area of the screen that Sikuli has to work with, and in general makes processing faster.  However, if I have already found the match, then does using the region make any difference at all?  If not, then I would imagine that the overhead of using the reg object could actually make the click() operation slightly slower.

Which way is recommended?

Thanks!


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