new to windows graphics programming or what not and am trying to get this include file to work. i cant seem to get it to include like the book says to. i added it to the input folder in the project properties option.
more clearly it said to add this to the project properties then to the input folder in there and the first option to add these files to it and i did and it wont work
2003.net compiler by the way
book said to add. d3d9.lib d3dx9.lib and winmm.lib
thanks
Code:
#include <windows.h>
#include <d3dUtility.h>//THE INCLUDE I CANT GET TO WORK
IDirect3DDevice9* device = 0;
bool setup()
{
return true;
}
void cleanup()
{
}
bool display(float timedelta)
{
if(device)
{
device->Clear(0, 0, D3DCLEAR TARGET | D3DCLEAR ZBUFFER, 0x00000000, 1.0f, 0);
device->Present(0,0,0,0);
}
return true;
}
HRESULT IDirect3DDevice9::Clear(DWORD Count, const D3DRECT* pRects, DWORD Flags, D3DCOLOR Color, float z, DWORD Stencil);
LRESULT CALLBACK d3d::WndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
{
switch(msg)
{
case WM DESTROY:
::PostQuitMessage(0);
break;
case WM KEYDOWN:
if(wParam == VK ESCAPE)
::DestroyWindow(hwnd);
break
}
return ::DefWindowProc(hwnd,msg,wParam,lParam);
}
int WINAPI WinMain(HINSTANCE hinstance, HINSTANCE prevInstance, PSTR cmdLine, int showQmd)
{
if(!d3d::InitD3D(hinstance, 800, 600, true, D3DDEVTYPE HAL, &device));
{
::MessageBox(0, "InitD3D() - Failed",0,0);
return 0;
}
if(!Setup())
{
::MessageBox(0,"Setup() - Failed",0,0);
return 0;
}
d3d::EnterMsgLoop(Display);
Cleanup();
device->Release();
return 0;
}