Sign in to follow this  
Followers 0
Sgraffite

Timing PixelSearch

5 posts in this topic

I was trying to time a PixelSearch Operation for a game running in 800x600 but I'm getting negative results using the timer functions. Running this I consistently get like -125.xxxx milliseconds. Here is the code:

Dim $begin1 = TimerInit()
Dim $pixel = PixelSearch ( 0, 0, 802, 624, -1, 0, 1)
Dim $end1 = TimerDiff ($begin1)
MsgBox ( 1, "PixelSearch Time", $end1 )

Am I doing this wrong?

Share this post


Link to post
Share on other sites



I have @AUTOITVERSION = "3.2.0.1" .. and am getting positive results as expected.

What is your @AUTOITVERSION?

Share this post


Link to post
Share on other sites

I have @AUTOITVERSION = "3.2.0.1" .. and am getting positive results as expected.

What is your @AUTOITVERSION?

I have version 3.2.0.1 as well.

Share this post


Link to post
Share on other sites

Other than the machine and operating system (mine is Win2K-pro), the only difference appears to be that you're running it on a game console. Perhaps that's where the difference lies?

Do you always get negative values, or are there circumstances which yield expected results?

What happens when you run your test script above on other resolutions?

What happens if you run it when there is no game running?

HTH

:)

Share this post


Link to post
Share on other sites

It seems kind of random when it happens now. If I run it consecutively sometimes it is negative, sometimes not. I also ran it on my other desktop and the asme issues arise, except I've seen it up to -1500 on my second computer. Having the game running or not seems to have no effect. It's really hard to tell which search functions give the best results when they are negative half the time.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0