Jump to content

How does the Pixel Search Function work?


Recommended Posts

So I've been playing around is the pixel search function but I don't quite understand how to change the search function to search in a certain area. I'll list the example from the forum below. So if we broke the screen into four halves how could I have the pixel search only search between the two center quarters of the screen. The idea was to minimize the time and usage of searching for a certain pixel. 

; Find a pure red pixel in the range 0,0-20,300
Local $aCoord = PixelSearch(0, 0, 20, 300, 0xFF0000)
If Not @error Then
    MsgBox($MB_SYSTEMMODAL, "", "X and Y are: " & $aCoord[0] & "," & $aCoord[1])
EndIf
Link to comment
Share on other sites

so you dont understand left, top, right, bottom?  or what exactly about the limited area is the issue?

i thought i understood 'four halves', but i do not understand where the 'center quarters' of four halves would be, which makes me think i dont understand four halves.  using the window info tool and specifying the exact area you are trying to capture with coordinates would be easier than word problems.

,-. .--. ________ .-. .-. ,---. ,-. .-. .-. .-.
|(| / /\ \ |\ /| |__ __||| | | || .-' | |/ / \ \_/ )/
(_) / /__\ \ |(\ / | )| | | `-' | | `-. | | / __ \ (_)
| | | __ | (_)\/ | (_) | | .-. | | .-' | | \ |__| ) (
| | | | |)| | \ / | | | | | |)| | `--. | |) \ | |
`-' |_| (_) | |\/| | `-' /( (_)/( __.' |((_)-' /(_|
'-' '-' (__) (__) (_) (__)

Link to comment
Share on other sites

  • Moderators

The idea was to minimize the time and usage of searching for a certain pixel. 

My question would be, what application is so difficult to manipulate that you're forced to resort to a pixel search? This function is known for its instability; 99% of the time there is a better way.

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...