cpu usage waitforimage

Technical support and scripting issues

Moderators: Dorian (MJT support), JRL

Post Reply
cvlr
Newbie
Posts: 18
Joined: Thu Jun 07, 2018 4:40 pm

cpu usage waitforimage

Post by cvlr » Thu Sep 27, 2018 6:39 pm

I find that on multiple machines which are all otherwise at least midrange that waitforimgae causes cpu usage to go to 26 percent and pretty much sit there. This is enough to cause slowdowns on the machines being used. We a re trapping a certain thing as the user uses the pc.

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

Re: cpu usage waitforimage

Post by Marcus Tettmar » Fri Sep 28, 2018 5:56 pm

Yes I would expect that. Image recognition is resource intensive and WaitScreenImage is a tight loop. You could try creating your own FindImagePos loop with a short delay in it so it's not as tight.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

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

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