Sign in to follow this  
ridefast42

directx and dev c++

Recommended Posts

In the very near future I plan to learn how to use the directx sdk because all of my games have been using allegro and I thought I might step it up a little. I figured learning how to compile programs using directx might be a good idea before I start programming with it. I know what libraries I need to link and all of that. I also assume that you must copy all of the include files and libs from the sdk into the dev c++ include folder and lib folder. My questions are as follows:Am I right so far? and why won't the directx samples compile?

Share this post


Link to post
Share on other sites
Copying the include and lib files is not a good idea.
All decent IDE's should let you add the dxsdk include and lib directories to some list.

But the shitty thing is that the compiler that comes with Dev-C++ uses different lib files than those shipped with directx sdk. Dev-C++ uses something called devpacks. I know there is a devpack out there with directx sdk files suited for Dev-C++, but I suspect that installing them correctly could be a slight challenge (since quite a few complaints about doing that ends up here at GD). People seem generally unsatisfied with the devpack system. Then again I havent tried it so I wouldnt realy know.

If you run into trubble using DirectX with Dev-Cpp I suggest you download and install Visual C++ 2005 express and the Platform SDK from Microsoft.
Both downloads is huge, and the IDE is bigger and slower than Dev-Cpp but it will cooperate with the default directx sdk ^^

Share this post


Link to post
Share on other sites
Ok, good deal. I think I might just have my parents buy me the full version of visual c/c++. It seems like a better idea than just downloading the free version. I did notice that dev c++ libraries are *.a files but I thought it could cope with the regular lib files. Thanks for the help!

Share this post


Link to post
Share on other sites
The free Express Edition is fully-featured, even including an optimizing compiler. I highly doubt you'd use many of the additional features garnered from actually purchasing the commercial editions. The only thing you'd actually lack which you might use is the resource editor, but that is a very minor portion of programming your game.

Share this post


Link to post
Share on other sites
Hi,

I had been using dev-cpp for a long time but i actually stopped using it because of the fact that i couldn't import DirectX .libs.

Instead of Visual C++ Express, you may want to look at Code::blocks editor in combination with Microsoft Toolkit (Compiler). The specs needed to run MSVC++ Express made me dizzy :) and i don't feel comfortable with its IDE. I got my engine (using directinput) running using code::blocks, and it works great. It is also free and is less than 4 mb in stead of MSVC++ 500 MB (or 1.3GB for full install).

http://www.codeblocks.org/

Greetings

Share this post


Link to post
Share on other sites
it actually can load the lib files and link them but it just hassel to get it working proper.

I know since i have followed the andy pike tutorials with directx 9.

Share this post


Link to post
Share on other sites
Quote:
Original post by Limitz
Hi,

I had been using dev-cpp for a long time but i actually stopped using it because of the fact that i couldn't import DirectX .libs.

Instead of Visual C++ Express, you may want to look at Code::blocks editor in combination with Microsoft Toolkit (Compiler).
Same here. These two tools are my favourite compiler IDE combo ever. Using DirectX is very easy with it, you just have to add the folders with the headers and libs to the list, and it's never an issue again. The good people at the Code::Blocks forums can help get you set up further.



Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this