About This File
🚀 Quick API Overview of ImageSearch UDF for AutoIt
ImageSearchDLL is an ultra-fast image recognition library for AutoIt, leveraging advanced SIMD (AVX512/AVX2/SSE2) optimizations to deliver lightning-fast pixel-perfect and fuzzy image matching.
🌟 Key Capabilities
This library is designed for performance and flexibility, offering:
-
⚡ Ultra-Fast Performance: Achieved through SIMD-accelerated algorithms.
-
🔍 Fuzzy Matching: Allows tolerance-based color matching (0-255) to handle variations.
-
🖼️ Multi-Scale Search: Enables searching for images scaled from 0.1x to 5.0x.
-
💾 Smart Caching: Location and bitmap caching are used for fast repeated searches.
-
🖥️ Multi-Monitor Support: Fully supports multi-monitor setups.
📚 Core Functions
These are the primary functions for image searching on the screen or within files:
-
_ImageSearch_Startup()
: Initializes the ImageSearch library and loads the DLL. -
_ImageSearch()
: Searches for a target image on the screen, optionally within a specific region, with color tolerance, and can return multiple results. It also supports searching on a specific monitor index. -
_ImageSearch_InImage()
: Searches for a target image inside a source image file without performing a screen capture.
🛠️ Advanced & Utility Functions
For deeper control and performance optimization, the library provides several advanced utilities, particularly involving HBITMAP handles:
-
_ImageSearch_CaptureScreen()
: Captures a specified screen region and returns an HBITMAP handle. -
_ImageSearch_hBitmap()
: Searches for a target HBITMAP inside a source HBITMAP (bypassing file I/O for speed). -
_ImageSearch_hBitmapLoad()
: Loads an image file into an HBITMAP handle, with optional background color specification. -
_ImageSearch_Wait()
: Waits for a specific image to appear on the screen, with customizable timeout and check intervals. -
_ImageSearch_ClearCache()
: Clears all cached bitmaps and location data. -
_ImageSearch_GetVersion()
: Returns the DLL version string. -
_ImageSearch_GetSysInfo()
: Provides detailed system information, including CPU features and cache status. -
_ImageSearch_Shutdown()
: Cleans up and unloads the library.
⚙️ Debugging and Error Handling
-
$g_bImageSearch_Debug
: A global variable that, when set toTrue
, enables debug information in search results. -
$g_sLastDllReturn
: A global variable that holds the debug information string, including timing, backend used, and cache details, from the last search operation. -
Error Codes: All functions set the
@error
variable upon failure, with specific negative integer codes ranging from -1 (Invalid path) to -10 (Invalid monitor index) to help diagnose issues.
ImageSearch UDF is OpenSource, free for both personal and commercial use.
Enjoy my work? Buy me a 🍻 or tip via ❤️ PayPal
Edited by Trong
What's New in Version v3.1
Released