if(FAILED(CoCreateInstance(&CLSID_DirectDraw, NULL, CLSCTX_ALL, IID_IDirectDraw4, &lpdd4)))
MessageBox(hWnd, "Failed to create DirectDraw object!", "DX Init Error.", MB_OK | MB_ICONEXCLAMATION);
Generates "cannot convert from ''const struct _GUID *'' to ''const struct _GUID"
I''ve tryed casting it, but to what? ... Nothing I tried works. Am I just missing something painfully obvious?
I know only that which I know, but I do not know what I know.
CoCreateInstance() problem.
I''m using the Tricks Of The Windows Game Programming Gurus to learn DirectX and I''m trying to initialize DirectDraw4 with CoCreateInstance, but I''m getting a mind boggling error.
I keep getting the same error...even in the following.
It still won''t let me pass the IID_IDirectDraw4 GUID.
I know only that which I know, but I do not know what I know.
if(FAILED(lpdd->QueryInterface(IID_IDirectDraw4, &lpdd4))) MessageBox(hWnd, "Failed to create the DirectDraw4 object!", "DX Init Error.", MB_OK | MB_ICONEXCLAMATION);
It still won''t let me pass the IID_IDirectDraw4 GUID.
I know only that which I know, but I do not know what I know.
Now all the previous code will compile... but I'm getting unresolved external on _IID_IDirectDraw4. I've got the ddraw.lib added to the link settings. Could it be that I'm using the DX8SDK?
I know only that which I know, but I do not know what I know.
[edited by - Daishi on June 8, 2002 3:16:35 PM]
I know only that which I know, but I do not know what I know.
[edited by - Daishi on June 8, 2002 3:16:35 PM]
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement