|
Post by iamjag on Dec 17, 2017 23:26:35 GMT
Hi All,
I was expecting that this question should have been ask before, but I was not able to find it, or may be I just missed it. But anyway, here is the question:
Is there a way to compare two Patterns. The two patterns are not found in the screen. This are cache patterns and would like to compare if the two object are the same or if the smallest one is found in a bigger pattern.
Regards, jAGHere
|
|
|
Post by AnkuLua on Dec 18, 2017 1:36:48 GMT
No. It's not supported now. Please give us some examples.
|
|
|
Post by iamjag on Dec 18, 2017 22:49:11 GMT
It's something like the following.
local img1 = Pattern("img1.png") local img2 = Pattern("img2.png")
--Compare img1 to img2 if img1==img2 then ... end
|
|
|
Post by AnkuLua on Dec 18, 2017 23:26:43 GMT
|
|
|
Post by iamjag on Dec 20, 2017 1:10:13 GMT
This are actually saved images from different region and different screens. My scenario is that, as the game progresses, I need to save images from different screens and then compare one or two images in order to determine the next action. Please take a look at the algorithm below.
Screen 1, at region1 save img1 Screen 2, at region2 save img2 Screen 3, at region3 save img3 Screen 4, if region4 image is equal to searchImage then compare img1 to img2 if result is equal then do this... elseif not equal compare img1 to img3 if result is equal then do other stuff... else do that... end end
|
|