# Simple DirectX app in VC++ Express 2005

## Recommended Posts

flashinpan    100
Can someone point me to some sample code that demonstrates a simple DirectX application in Visual C++ Express 2005? I just downloaded both VC++ Express 2005 as well as DirectX. I just want to introduce them to each other and create a very simple application that uses DirectX. What application type do I pick, for example? Is it a WinForm application that I want? Thank you, Tom

##### Share on other sites
GDKnight    302
Have you checked the DirectX SDK?
It has examples of just about anything. Generally speaking all the VS2003 projects should be backwards compatible with VS2005.

I don't believe you want a "win forms" project you probably want a win32 project. At least thats what I use, im sure its possible to do with winforms but I wouldn't recommend it unless your doing tool development. Often times not even if your doing tool development, WinForms is for business applications more often then games.

If your not looking for the SDK versions some places I would recommend are:
http://www.ultimategameprogramming.com
http://www.gametutorials.com/
http://www.andypike.com/tutorials/directx8/

##### Share on other sites
_goat    804
First of all, GDKnight, that's forwards compatibility, hehe.

Secondly, OP, you'd probably just want a console application. The compiler will spit out Win32 binaries, so it'll run, and it's easy to set up. Watch!
int main(){}
Haha, I'm done.

##### Share on other sites
flashinpan    100
I tried to run one of the tutorials

and I get the following error:

------ Build started: Project: D3DIntroNET, Configuration: Debug Win32 ------
Compiling...
D3DIntro.cpp
c:\program files\microsoft directx 9.0 sdk (june 2005)\include\d3d9.h(40) : fatal error C1083: Cannot open include file: 'objbase.h': No such file or directory
Build log was saved at "file://c:\Documents and Settings\Syndi\Desktop\D3D_Intro\D3DIntro\Debug\BuildLog.htm"
D3DIntroNET - 1 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

##### Share on other sites
GDKnight    302
Looks like you have your DirectX SDK installed incorrectly or something, consider reinstalling it.

##### Share on other sites
flashinpan    100
Quote:
 Original post by GDKnightLooks like you have your DirectX SDK installed incorrectly or something, consider reinstalling it.

Yeah...I had to move a bunch of includes and lib files from the Platform SDK folders to the DirectX SDK folders, and it seemed to work that way. It compiles and runs now.

##### Share on other sites
Guest Anonymous Poster
also... even if you install the directX sdk properly it doesn't auto add the include directory to the include directories searched with visual studio 2005. I think you can add them by going to the properties and then the input tab. Also, i have a question kind of related to the subject: Does anyone know of a way to manage a list of DX meshes? I've used my own type of pointer list thing, but it frequently crashes my computer because of random problems where the pointers get screwed up.