Windows has, for example, GDI (graphical device interface): with GDI you can easily get the device context with HDC dc = GetDC(NULL); And then to read the pixel values using COLORREF color = GetPixel(dc, x, y); , y); . But be careful: after that you must free the device context (when all the GetPixel actions of your program are completed) using ReleaseDC(NULL, dc); - otherwise you will be a memory leak. See also here for more details.
However, for such tasks, I suggest you use: Auto-it . It is simple, easy to use, and fairly simple (after all, it is just designed for such operations).
Local $color = PixelGetColor(200, 300) MsgBox(0, "The color is ", $color )
source share