DirectX8.0
Hi all. I am learning DirectX8.0 using Peter Walsh''s Zen of Direct3D Game Programming book. For some reason, I can get the 2D stuff to work (for the most part), but the 3D stuff won''t even initialize the device. I get the D3DERR_INVALIDCALL error when I call CreateDevice like this:
CreateDevice (D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, hWndTarget,
D3DCREATE_SOFTWARE_VERTEXPROCESSING, &d3dpp,
ppDevice);
Where hWndTarget is the handle to my global hWnd object, d3dpp is a local D3DPRESENT_PARAMETERS structure, and ppDevice is a pointer to the address of my global LPDIRECT3DDEVICE8 object.
Does anyone have an idea why I might be getting this error? The code is right from the book. (Not that the book is necessarily correct, but it might be my problem not his).
Thanks for any help you can give me.
November 22, 2002 06:44 PM
post some code. that always helps.
did you set dwSize for your structures?
did you set dwSize for your structures?
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement