SaraMclaren Posted February 8, 2016 Share Posted February 8, 2016 Hi, I've been searching various API of autoit and GDI and I'm still confused. I'm trying to use autoit to run some tests. I'd like to search the screen for a given known image (eg: a button with specific size/text). We take screen shots during a known good state, and want to make sure these sections are visible when the script is run. I was thinking something to the line of: 1. take screenshot 2. open "button_special.png" 3. Scan screenshot for button_special.png existenace: a. Loop through all pixels in button_special.png b. find matching pattern in screenshot I guess I'm stuck on the basics of reading pixels out of button_special.png. Is there a clean way to do this? Could someone provide sample code to help me get started? Thanks! Sara Link to comment Share on other sites More sharing options...
AutoBert Posted February 8, 2016 Share Posted February 8, 2016 The best way to getting started is to read the help to understand the basics. After understood this you should also read the UDF-Part of the help, specialy GDIPlus Reference. And you should read about fileformat of png, for example: https://en.wikipedia.org/wiki/Portable_Network_Graphics Link to comment Share on other sites More sharing options...
JohnOne Posted February 8, 2016 Share Posted February 8, 2016 ImageSearch? AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
SaraMclaren Posted February 9, 2016 Author Share Posted February 9, 2016 Just saw images each thread. Thanks john! I wished it hadn't relied on compiled dll though. Link to comment Share on other sites More sharing options...
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