About WaitScreenImage>

Technical support and scripting issues

Moderators: Dorian (MJT support), JRL

Post Reply
pantik
Junior Coder
Posts: 45
Joined: Sun Dec 13, 2009 5:52 pm

About WaitScreenImage>

Post by pantik » Mon Oct 05, 2015 6:11 pm

I know that with "FindImagePos>" i can use the variable FIP_SCANPIXELS to set the numer of pixels to scan to something different than 100 (default value). How WaitScreenImage> works? I would like the script waits for the EXACT image,i.e. 100% match.
Since i am guessing that WaitScreenImage search on the full screen... So...Could i get better performance if i know where the image can appear, and using ScreenCapture to capture that area and checking with Comparebitmaps> or GetRectCheckSum> in a loop ?

What about Comparebitmaps>? I have noticed the if you make a light change of 1 pixel in an image, you can still get result=100 (match 100%).
And.. the last one... can really GetRectCheckSum> be used to check 100% matchs?

Sorry for my english :))

User avatar
Marcus Tettmar
Site Admin
Posts: 7391
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Re: About WaitScreenImage>

Post by Marcus Tettmar » Tue Oct 06, 2015 9:31 am

Same, WaitScreenImage is a wrapper for a loop containing FindImagePos. So just set FIP_SCANPIXELS in the same way.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

pantik
Junior Coder
Posts: 45
Joined: Sun Dec 13, 2009 5:52 pm

Re: About WaitScreenImage>

Post by pantik » Tue Oct 06, 2015 12:35 pm

Ok but... I can get better valuabe performance or speed if i know the imagen will be shown in a small rectanble in stead of capture de full screen? i dont know this, maybe WaitScreenImage is enough optimized.

If i build a loop myself with FindimagePosition , is there some way to save the captured image in memory stead of the hard disk?

User avatar
Marcus Tettmar
Site Admin
Posts: 7391
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Re: About WaitScreenImage>

Post by Marcus Tettmar » Tue Oct 06, 2015 1:05 pm

Yes you can make your own FindImagePos loop which looks at a portion of the screen or just a specific window.

Not sure how keeping the haystack in memory would help - you want to monitor changes, so you will have to keep re-capturing it.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

pantik
Junior Coder
Posts: 45
Joined: Sun Dec 13, 2009 5:52 pm

Re: About WaitScreenImage>

Post by pantik » Tue Oct 06, 2015 1:27 pm

would not be faster if you get the captured image to be compare from memory stead of hard disk ? i mean writting and reading from memory is faster than hard disk. For example, i noticed big difference between storing captured bmp files in hard disk and storing in SSD disks.

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts