jamegon Posted May 30, 2018 Posted May 30, 2018 Hello I need to read a graphic file and know if a determinate point the color is green. If the graphic is in the screen I can use PixelGetColor(). Can I read the graphic whitout show it in the screen? Thanks Javier
Xandy Posted May 30, 2018 Posted May 30, 2018 (edited) I don't have all the exact commands in my head at the moment, but you can do it with something like. #include <GDIPlus.au3> ; Initialize GDI+ library _GDIPlus_Startup() ; Some color, maybe even 0, 0, 0 black $pixelDave = 4278190080 $hBMP = _GDIPlus_BitmapCreateFromFile($rect_file) If _GDIPlus_BitmapGetPixel($hBMP, $x, $y) <> $pixelDave Then ConsoleWrite("Dave's not here") Else ConsoleWrite("Dave") EndIf _GDIPlus_Shutdown() Something like this does what you want to do. Edited May 30, 2018 by Xandy Human Male Programmer (-_-) Xandy About (^o^) Discord - Xandy Programmer MapIt (Tile world editor, Image Tile Extractor, and Game Maker)
junkew Posted May 31, 2018 Posted May 31, 2018 https://www.autoitscript.com/wiki/FAQ#How_can_I_search_an_image_in_another_image.3F FAQ 31 How to click some elements, FAQ 40 Test automation with AutoIt, Multithreading CLR .NET Powershell CMDLets
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