abdulrahmanok Posted July 9, 2021 Posted July 9, 2021 My program idea is to get the nearest points of my start mark My Background: -there are no controls in this website to check. - I already tried pixel search, but it has bad accuracy - I think Imagesearch will be also bad. - Already Tried Geocoder sites, but it does not show street number for all coordinates My Code: expandcollapse popupHotKeySet('{f5}', 'start') HotKeySet('{esc}', '_exe') Func _exe() Exit EndFunc While 1 Sleep(3000) Wend Func start() Global $c[2] = [954, 613];My Middle Screen FindYellow(-1,0,-1, 0) ;Search Left EndFunc Func FindYellow($Val_X,$Val_Y , $ChangeX , $ChangeY ) MouseMove( $c[0] , $c[1],0 ) $Val_X = 0 Do $PinX = $c[0] + $Val_X $PinY = $c[1] + $Val_Y ; print('Val_X',$Val_X ) ; print('Val_Y',$Val_Y ) print('$PinY', $PinX) print('$PinY', $PinY) ToolTip('Checking....', 0, 0) Global $Chkcolor = PixelGetColor($PinX,$PinY );0x8F8E65 If $Chkcolor = '12237499' Then ;White Street Line click($PinX,$PinY ) print('FindYellow_ UP Found At: ' , $PinX & ',' & $PinY ) ExitLoop Return True Else ; print('ChkColor', $Hex ) EndIf ;MouseMove( $PinX , $PinY,0 ) Print('Current Color',$Chkcolor ) ; Sleep(2) $Val_X += $ChangeX $Val_Y += $ChangeY ;Sleep(5) Until $PinY <= 0 Or $PinY >= @DesktopHeight Or $PinX >= @DesktopWidth Or $PinX <= 0 ;MouseMove( $PinX , $PinY,0 ) ToolTip('', 0, 0) MsgBox(0, 0, 'Done') EndFunc Func Pix_GroupYellow() Global $Yellow_Array[1] = [0xB9B8B9] Global $Hex = '0x'& Hex($Chkcolor, 6) For $i = 0 To UBound($Yellow_Array) -1 If $Hex = $Yellow_Array[$i] Then MsgBox(0, 0,'Group Pix ok') Return True ExitLoop EndIf Next EndFunc Func Print($Txt,$Func="") ConsoleWrite($Txt& '= ' ) ConsoleWrite($Func &@CRLF) EndFunc Website: https://geoportal.gisqatar.org.qa/qmape/index.html What I need: Some way to checking process faster, Or anyway to achieve the main purpose (click on nearest point of start mark)
abdulrahmanok Posted July 10, 2021 Author Posted July 10, 2021 Im ready to provide any information to make everything clear.
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now