Pixel Finding Routine and Windows 10

Technical support and scripting issues

Moderators: JRL, Dorian (MJT support)

Post Reply
hanksterman00
Newbie
Posts: 1
Joined: Mon May 09, 2016 8:13 pm

Pixel Finding Routine and Windows 10

Post by hanksterman00 » Mon May 09, 2016 8:38 pm

Been using this type of routine for finding pixel color and placing values to variables for years.
The issue is related to Windows 10 and perhaps 8 also. With the advent of fractional pixeling that Microsoft
first introduced in 8 and carried to 10, it is adding exorbitant scan time to my scripts. This did not occur prior to 8.
Perhaps this is not the issue at all. Time is of the essence for what I am doing with these routines. Any comments or suggestions
would be appreciated. Simple example of the code is attached.

Label>FindSpan1U
GetPixelColor>CalpointerX,CalpointerY,SpanA
MouseMove>CalpointerX,CalpointerY
If>SpanA=9498256,,IncY1U
Let>Green=CalpointerY
Goto>CheckPositionU

Label>IncY1U
Let>CalpointerY=CalpointerY+1
If>CalpointerY>902,,FindSpan1U
Let>CalpointerX=CalpointerX-1
Let>CalpointerY=354
Goto>FindSpan1U

User avatar
JRL
Automation Wizard
Posts: 3531
Joined: Mon Jan 10, 2005 6:22 pm
Location: Iowa

Re: Pixel Finding Routine and Windows 10

Post by JRL » Tue May 10, 2016 12:48 pm

I don't have Win 10 to try this but I've stopped using GetPixelColor> when looping, searching and waiting for a particular colored pixel to show up. FindImagePos> is much faster. I give an example and a routine to create the one color bmp file needed for the FindImagePos> search HERE

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