Sign in to follow this  

directX setup

This topic is 4692 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 tried to run this program with vc6++ and directX8 installed. the directdraw tutorials with SDK run as well. I cant get it to compile http://www.gamedev.net/reference/articles/article1838.asp I opened a c++ sourc file ( i thought i needed a win32 app) added these files dxutil.h dxutil.cpp ddutil.h ddutil.cpp are all in the folder with my source file dxguid.lib,ddraw.lib,winmm.lib are supposed to be linked in Project setting right in the Link tab in Object/lib modules area, do I need to add in project options as well 1)why isnt the tools->options->directories enough? 2) where is ddraw.h?

Share this post


Link to post
Share on other sites
ok i got it working but after much trial and error.
i have a few q's if anyone could help me out with thanks

1)how do I know what version of directdraw I am using (it cant be 8 directdraw stopped at 7)

2) why did the directX samples have directdraw in it (when it stopped at 7) and it included the file ddraw.h which the program sample didnt

3)in vc6++ i had to add directX files to file view, project settings/libs, actual directory and regular directory...why is the include paths set up in Options enough

Share this post


Link to post
Share on other sites
1)Depends on how you created it.
If you used 'DirectDrawCreate()' you will get the oldest interface. You will then have to use 'QueryInterface()' with the GUID of the interface you want. In this case, IID_IDirectDraw7.

If you used the COM method with 'CoCreateInstance()' that same GUID I showed above may be passed directly to it.

And finally, in that last release of DirectDraw, MS was nice enough to put a simple wrapper function called 'DirectDrawCreateEx', once again, one of the parameters is the GUID for the interface you want.

2)Perhaps the sample made a mistake. They probably had it included in another header and forgot to list its contents.

3)I'm having trouble understanding that last question. Do you mean, "why do I have to link manually to the DX libs?" The answer is simple. Because you have to. That is how VC6 works.

Share this post


Link to post
Share on other sites
Quote:
Original post by lack o comments
1)Depends on how you created it.
If you used 'DirectDrawCreate()' you will get the oldest interface. You will then have to use 'QueryInterface()' with the GUID of the interface you want. In this case, IID_IDirectDraw7.

If you used the COM method with 'CoCreateInstance()' that same GUID I showed above may be passed directly to it.

And finally, in that last release of DirectDraw, MS was nice enough to put a simple wrapper function called 'DirectDrawCreateEx', once again, one of the parameters is the GUID for the interface you want.

.

thanks for the reply

what do you mean how you created it, none of those staments appear in the code to get a screen up with some text with this

http://www.gamedev.net/reference/articles/article1838.asp

Share this post


Link to post
Share on other sites
Ohhhhhh, I see. In the example they are using a set of utilities written by MS that came with DirectX 8.0 They are classes that abstract the use of DirectDraw a little.

I've never used the libs, I wrote my own so I really don't know much about them. But, it should be safe to assume they are using the lastest interfaces. This probably also explains why they don't include "DDraw.h" in the example,it is probably inside one of the utility headers.

Share this post


Link to post
Share on other sites
Quote:
Original post by lack o comments
Ohhhhhh, I see. In the example they are using a set of utilities written by MS that came with DirectX 8.0 They are classes that abstract the use of DirectDraw a little.

I've never used the libs, I wrote my own so I really don't know much about them. But, it should be safe to assume they are using the lastest interfaces. This probably also explains why they don't include "DDraw.h" in the example,it is probably inside one of the utility headers.


so whats the standard way to use directDraw7 with vc6++,

you writ your own.....i am curious are the libs you wrote a set of classes to help you work with directX....I mean libs in the VB sense

Share this post


Link to post
Share on other sites
Quote:

so whats the standard way to use directDraw7 with vc6++,

you writ your own.....i am curious are the libs you wrote a set of classes to help you work with directX....I mean libs in the VB sense

This is what I call confusion recursion =) Now I'm confused.

What do you mean 'standard way'? I just used the DirectDraw interfaces directly. And eventually, I got tired of writing certain parts over and over so I wrote a libaray full of functions that automated common tasks. Things like: initialization, various blitting routines, etc...

Share this post


Link to post
Share on other sites
Quote:
Original post by lack o comments
Quote:

so whats the standard way to use directDraw7 with vc6++,

you writ your own.....i am curious are the libs you wrote a set of classes to help you work with directX....I mean libs in the VB sense

This is what I call confusion recursion =) Now I'm confused.

What do you mean 'standard way'? I just used the DirectDraw interfaces directly. And eventually, I got tired of writing certain parts over and over so I wrote a libaray full of functions that automated common tasks. Things like: initialization, various blitting routines, etc...


to use the directdraw interfaces directly you just use ddraw.h and start using its functions...


the example i had of using direct draw didnt include ddraw.h and it mentioned they were a shortcut or abstract way. the way direct draw was implmented on the example I can assume this will work with directdraw7 and all standard functions to do with it.

i have used directX7 with VB and found that to be easy with the setup. in c++ i am a newbie with setup directx so thats way i sound ....confused

Share this post


Link to post
Share on other sites

This topic is 4692 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.

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