Sign in to follow this  
Followers 0
fataly

Read this.

5 posts in this topic

i need scan large area. i can use if pixelgetcolor(x,y) = oxfffff then XXXXX but its scan only 1 pixel.

how i can make it scan like 50x50 pixel areas?

Share this post


Link to post
Share on other sites



PixelSearch(1,1,50,50, Color) these 50,50 means areas?

and 1,1 y and x axels?

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

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

Share this post


Link to post
Share on other sites

#5 ·  Posted (edited)

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

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