Jump to content

Read this.


fataly
 Share

Recommended Posts

Searches a rectangle of pixels for the pixel color provided.

PixelSearch ( left, top, right, bottom, color [, shade-variation] [, step]] )

left: left coordinate of rectangle.

top: top coordinate of rectangle.

right: right coordinate of rectangle.

bottom: bottom coordinate of rectangle.

colour: Colour value of pixel to find (in decimal or hex).

shade-variation [optional]: A number between 0 and 255 to indicate the allowed number of shades of variation of the red, green, and blue components of the colour. Default is 0 (exact match).

step [optional]: Instead of searching each pixel use a value larger than 1 to skip pixels (for speed). E.g. A value of 2 will only check every other pixel. Default is 1.

Edited by Jex
Link to comment
Share on other sites

Func _AreaGetColors($top, $left, $bottom, $right)
    Local $result[$bottom-$top+1][$right-$left+1], $x, $y
    For $x = $top to $bottom
        For $y = $left to $right
            $result[$x-$top][$y-$left] = PixelGetColor($x, $y)
        Next
    Next
    Return $result
EndFuncoÝ÷ Øù^jǧ¢×­êÞÉèr)àûazö¥¹ë­êâHMú¶e·Múnm¢j+Ó~¥yûe·Mú®(*.ßÙeëZê뢴áÇîËb¢|"[Z楢ڶ)ö¥j¸j·Ë¬yÞ;ï}fYb±ç(Û¢¶µÓn1ﯭæÅ©©êºÇºÚ"µÍÚ[ÛYH  Ð^K]LÉÝÂÐ^^JÐXQÙ]ÛÛÜÊ
L
L
K   ][Ý×ÐXQÙ]ÛÛÜÈØ[I][ÝÊ

Edited by TomZ
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...