Is it possible for AHK to scan the screen faster than its frame rate?

Ask gaming related questions (AHK v1.1 and older)
Ernest
Posts: 2
Joined: 24 Mar 2018, 10:08

Is it possible for AHK to scan the screen faster than its frame rate?

28 Mar 2018, 09:32

For example we have a web page with 10 buttons. When we click on one of them, some colors appear at different places on this web page. Let's say, we need to find the green color. So we do PixelSearch. But because frames change only once in 16,7 ms (for 60Hz screens), we have to use Sleep command and wait until the color appears on the screen. Is it possible somehow to reduce these 16,7ms? Or somehow else reduce the time between clicking a button and executing PixelSearch?
TygerByte
Posts: 96
Joined: 12 Aug 2016, 05:22

Re: Is it possible for AHK to scan the screen faster than its frame rate?

31 Mar 2018, 21:50

I've only ever been able to get my pixel scan as low as about 30ms give or take a few ms. This was for use in trigger bots and just general constant scanning of the screen where a new scan has to be done frequently. Maybe someone else can help you out.
neverlevel
Posts: 60
Joined: 13 Apr 2016, 22:02

Re: Is it possible for AHK to scan the screen faster than its frame rate?

02 Apr 2018, 21:03

I don't think ahk cares how fast your screen can change color..pixelgetcolor from a specific pixel location... I know green shows up here...would be fastest I can think of... if you have to scan big areas it takes much longer
User avatar
evilC
Posts: 4824
Joined: 27 Feb 2014, 12:30

Re: Is it possible for AHK to scan the screen faster than its frame rate?

03 Apr 2018, 12:07

Use my CGDipSnapshot library.
This will allow you to take a "Snapshot" of your screen, then do any number of PixelSearches on the snapshot as you wish, ensuring that all PixelSearches do the check on the same frame of animation.

Return to “Gaming Help (v1)”

Who is online

Users browsing this forum: No registered users and 92 guests