#include <string>
#include <sstream>
#include <iostream>
std::string printColor(HWND hwnd,int x,int y)
{
HDC dc = GetDC(hwnd);
COLORREF colorref = GetPixel(dc, x, y);
std::string out;
std::stringstream xx;
xx << std::hex << colorref;
xx >> out;
return out;
}
获取并打印Win32窗口的像素点
于 2023-04-21 12:02:12 首次发布