Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Chique Geek

Fresh Meat - problems early on

This topic is 5367 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I am trying to set up DirectDraw in a shell win32 application. I have included ddraw.h and added ddraw.lib to my project. All I have written, besides the code that sets up the window, is:
LPDIRECTDRAW7 lpdd7 = NULL;
if(FAILED(DirectDrawCreateEx(NULL,(LPVOID *)&lpdd7,IID_IDirectDraw7,NULL))) PostQuitMessage(0);
followed by a game loop (with no code in it yet). I get no errors when I compile, but I get this error upon building:
Linking...
main.obj : error LNK2001: unresolved external symbol _IID_IDirectDraw7
Debug/Shell.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.
I can''t figure out what''s wrong. I have the latest version of DirectX and everything. I''m using MSVC++ 6, by the way.

Share this post


Link to post
Share on other sites
Advertisement
Guest Anonymous Poster
Link against the DirectX libraries. Including the headers just gives the compiler a bunch of prototypes and definitions, not actual code.

Share this post


Link to post
Share on other sites
quote:
Original post by Anonymous Poster
Link against the DirectX libraries. Including the headers just gives the compiler a bunch of prototypes and definitions, not actual code.

What do you mean by "Link against?" I have added them to my project... do I need to do something more?

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!