Do you know if I can access to windows HWND of Unity? Like when I call :
BOOL TOUCH_API InitInstance(HINSTANCE hInstance, int nCmdShow)
{
HWND hWnd;
hInst = hInstance; // Store instance handle in our global variable
hWnd = CreateWindow(szWindowClass, szTitle, WS_OVERLAPPEDWINDOW,
CW_USEDEFAULT, 0, CW_USEDEFAULT, 0, NULL, NULL, hInstance, NULL);
if (!hWnd) {
return FALSE;
}
and change RegisterTouchWindow to :
// register the window for touch instead of gestures
RegisterTouchWindow(hWnd, 0);
// the following code initializes the points
for (int i=0; i< MAXPOINTS; i++){
points*[0] = -1;*
_points*[1] = -1;*_
<em>_idLookup *= -1;*_</em>
<em>_*}*_</em>
<em>_*ShowWindow(hWnd, nCmdShow);*_</em>
<em>_*UpdateWindow(hWnd);*_</em>
<em>_*return TRUE;*_</em>
<em>_*}*_</em>
<em>_*```*_</em>
<em>_*<hr>*_</em>
<em>_*<p>because the Dll works perfectly if I disable this part of script : </p>*_</em>
<em>_*<hr>*_</em>
<em>_*```*_</em>
<em><em>*hWnd = CreateWindow(szWindowClass, szTitle, WS_OVERLAPPEDWINDOW,*</em></em>
<em><em>*CW_USEDEFAULT, 0, CW_USEDEFAULT, 0, NULL, NULL, hInstance, NULL);*</em></em>
<em>_*```*_</em>