Simple Direct X ?
Hello, I am simply trying to create a directdraw object. I have the correct ddraw(.h,.lib) file links in the source code, but my compiler WILL NOT get past this line of code.
____________________________________
LPDIRECTDRAW7 lpdd = NULL;
___________________________________
this are the errors pertaining to this line of code.
''LPDIRECTDRAW7'' : undeclared identifier
E:\My Documents\c++\Simple Animation\Simple Animation.cpp(210) : error C2146: syntax error : missing '';'' before identifier ''lpdd''
If I cannot get past this point I cannot go any further.
Please help this direct x newbie....
Job description : Duct Tape
I''m pretty sure that LPDIRECTDRAW7 isn''t a valid identifier. Try LPDIRECTDRAW4.
I pulled that line of code straight out of the DirectX 7 SDK. (changed varaible name, but call is identical).
Job description : Duct Tape
Are you are doing:
#include ddraw.h
with the proper ddraw.h which has dx7 stuff?
open it and make sure, also if you compiler finds multiple ddraw.h files it might not be useing the one you want it to.
But your right the syntax is fine it sounds like a header file problem.
Edited by - Atavist on 1/25/00 6:51:58 PM
#include ddraw.h
with the proper ddraw.h which has dx7 stuff?
open it and make sure, also if you compiler finds multiple ddraw.h files it might not be useing the one you want it to.
But your right the syntax is fine it sounds like a header file problem.
Edited by - Atavist on 1/25/00 6:51:58 PM
Just because the church was wrong doesn't mean Galileo wasn't a heretic.It just means he was a heretic who was right.
Crap, there a 2 ddraw(.h, .lib) files on my system. One is in visual studio dir and the other in the mssdk(7). How do I make sure it is using the right one. I have the ''Project->Settings->Link'' set to include stuff from c:\mssdk\lib, butif the files also exist in my root lib dir how do I exclude the default?
Job description : Duct Tape
I think I figured it out. Took ddraw.h from mssdk(7) and copied it to my project folder. I don''t like this option because I dislike haveing to duplicate files on my system. Is there a way to do this from a path setting within VC++?
Job description : Duct Tape
Yeah
In the option part where you setup paths just drag the path you want to use first to the top of the list. The compiler uses the first file in finds according to that list.

In the option part where you setup paths just drag the path you want to use first to the top of the list. The compiler uses the first file in finds according to that list.
Just because the church was wrong doesn't mean Galileo wasn't a heretic.It just means he was a heretic who was right.
Thats Tools -> Options / directories tab for those that can't read minds 
There's a pull down there that allows you to select executable, include, and library paths. The include path setup is where the path setup you want is.
Edited by - Oofnish on 1/26/00 9:26:58 AM

There's a pull down there that allows you to select executable, include, and library paths. The include path setup is where the path setup you want is.
Edited by - Oofnish on 1/26/00 9:26:58 AM
*oof*
you can also just copy the .lib and .h files from the SDK to \lib and if you don''t plan on using the version of DX that shipped with VC++ ( i think it''s DX5 in VC++6).
-Justin
AIM: Just6979
e-mail: jowhite@bigfoot.com
www.bigfoot.com/~jowhite
-Justin
AIM: Just6979
e-mail: jowhite@bigfoot.com
www.bigfoot.com/~jowhite
-JustinAIM: Just6979e-mail: jowhite@bigfoot.comwww.bigfoot.com/~jowhite
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement