as the title, i want to create a window on unity using winapi.
However i want to put the created window into a unity object.
I searched and couldn’t find any solution for this problem?
Can someone help me with this problem?
Below is my unity code to create a window
[DllImport("CreateWWindow", CallingConvention = CallingConvention.Cdecl)]
public static extern void InitWinodw(IntPtr hWnd);
[DllImport("user32.dll", CharSet = CharSet.Auto, SetLastError = true)]
public static extern IntPtr GetActiveWindow();
void Start()
{
QualitySettings.vSyncCount = 0;
Application.targetFrameRate = 60;
IntPtr hwnd = GetActiveWindow();
InitWinodw(hwnd);
}
Thanks you!