|
@@ -8,8 +8,6 @@
|
|
// #pragma comment(lib, "d3d11.lib")
|
|
// #pragma comment(lib, "d3d11.lib")
|
|
// #pragma comment(lib, "dxgi.lib")
|
|
// #pragma comment(lib, "dxgi.lib")
|
|
|
|
|
|
-int frameWidth = 2;
|
|
|
|
-int titleBarHeight = 27;
|
|
|
|
|
|
|
|
namespace GAssist
|
|
namespace GAssist
|
|
{
|
|
{
|
|
@@ -1750,9 +1748,10 @@ namespace GameAssist
|
|
}
|
|
}
|
|
};
|
|
};
|
|
|
|
|
|
-namespace GameGlobal {
|
|
|
|
- int frameWidth = 2;
|
|
|
|
- int titleBarHeight = 27;
|
|
|
|
|
|
+namespace GameGlobal
|
|
|
|
+{
|
|
|
|
+ int frameWidth = 2;//6
|
|
|
|
+ int titleBarHeight = 27;//29
|
|
|
|
|
|
TCHAR g_szCurModuleFileName[MAX_PATH];
|
|
TCHAR g_szCurModuleFileName[MAX_PATH];
|
|
TCHAR g_szCurModuleDir[MAX_PATH];
|
|
TCHAR g_szCurModuleDir[MAX_PATH];
|
|
@@ -1975,10 +1974,10 @@ namespace ImgAssist
|
|
|
|
|
|
cv::Rect roi = cv::Rect(lv_nMaxLoc.x, lv_nMaxLoc.y, tempImg.cols, tempImg.rows);
|
|
cv::Rect roi = cv::Rect(lv_nMaxLoc.x, lv_nMaxLoc.y, tempImg.cols, tempImg.rows);
|
|
cv::Mat roiImg = srcImg(roi);
|
|
cv::Mat roiImg = srcImg(roi);
|
|
- cv::imwrite(GameGlobal::BuildImgPath(hWnd, _T("match.bmp")), roiImg);
|
|
|
|
|
|
+ cv::imwrite(GameGlobal::BuildImgPath(hWnd, _T("match")), roiImg);
|
|
|
|
|
|
- rc.left = lv_nMaxLoc.x - frameWidth;
|
|
|
|
- rc.top = lv_nMaxLoc.y - titleBarHeight;
|
|
|
|
|
|
+ rc.left = lv_nMaxLoc.x - GameGlobal::frameWidth;
|
|
|
|
+ rc.top = lv_nMaxLoc.y - GameGlobal::titleBarHeight;
|
|
rc.right = rc.left + tempImg.cols;
|
|
rc.right = rc.left + tempImg.cols;
|
|
rc.bottom = rc.top + tempImg.rows;
|
|
rc.bottom = rc.top + tempImg.rows;
|
|
|
|
|
|
@@ -2016,8 +2015,8 @@ namespace ImgAssist
|
|
cv::Mat roiImg = srcImg(roi);
|
|
cv::Mat roiImg = srcImg(roi);
|
|
//cv::imwrite("G:\\bin\\GameAssist\\match.bmp", roiImg);
|
|
//cv::imwrite("G:\\bin\\GameAssist\\match.bmp", roiImg);
|
|
|
|
|
|
- rc.left = lv_nMaxLoc.x - frameWidth;
|
|
|
|
- rc.top = lv_nMaxLoc.y - titleBarHeight;
|
|
|
|
|
|
+ rc.left = lv_nMaxLoc.x - GameGlobal::frameWidth;
|
|
|
|
+ rc.top = lv_nMaxLoc.y - GameGlobal::titleBarHeight;
|
|
rc.right = rc.left + tempImg.cols;
|
|
rc.right = rc.left + tempImg.cols;
|
|
rc.bottom = rc.top + tempImg.rows;
|
|
rc.bottom = rc.top + tempImg.rows;
|
|
|
|
|
|
@@ -2067,8 +2066,8 @@ namespace ImgAssist
|
|
cv::Mat roiImg = imgROI(roi);
|
|
cv::Mat roiImg = imgROI(roi);
|
|
cv::imwrite(GameGlobal::BuildImgPath(hWnd, _T("match")), roiImg);
|
|
cv::imwrite(GameGlobal::BuildImgPath(hWnd, _T("match")), roiImg);
|
|
|
|
|
|
- matchRect.left = srcRect.left + lv_nMaxLoc.x - frameWidth;
|
|
|
|
- matchRect.top = srcRect.top + lv_nMaxLoc.y - titleBarHeight;
|
|
|
|
|
|
+ matchRect.left = srcRect.left + lv_nMaxLoc.x - GameGlobal::frameWidth;
|
|
|
|
+ matchRect.top = srcRect.top + lv_nMaxLoc.y - GameGlobal::titleBarHeight;
|
|
matchRect.right = matchRect.left + tempImg.cols;
|
|
matchRect.right = matchRect.left + tempImg.cols;
|
|
matchRect.bottom = matchRect.top + tempImg.rows;
|
|
matchRect.bottom = matchRect.top + tempImg.rows;
|
|
|
|
|