Sign in to follow this  

dsound ?

Recommended Posts

Can nobody out there tell me why this might be happening. It seems that the dsound code is there but all the errors are saying everything is undefined (I'm talking vc++ 6.0 by the way and I do have the sdk (as I said the dsound code is coming up))?

Share this post

Link to post
Share on other sites
You need to add a reference to dsound.lib and winmm.lib.

If nothing else, add this to your header file:

#pragma comment ( lib, "dsound.lib" )
#pragma comment ( lib, "winmm.lib" )

(The above #pragmas are an instruction to the compiler to include the library files specified using the standard paths. Non portable, completely, but so is DirectX. :))

Share this post

Link to post
Share on other sites
I have both of those libraries and the include:

strange huh?
I ahve since observed that it seems all 180 errors involve LPCWAVEFORMATEX!

This is the first line in dsound that the compiler doesnt like:


Here are the first few errors:

d:\program files\dxsdk\include\dsound.h(230) : error C2143: syntax error : missing ';' before '*'

d:\program files\dxsdk\include\dsound.h(230) : error C2501: 'LPCWAVEFORMATEX' : missing storage-class or type specifiers

d:\program files\dxsdk\include\dsound.h(349) : error C2146: syntax error : missing ';' before identifier 'lpwfxFormat'

the first 2 relate to the above typedef and the last one applies to this attempt to create a variable using LPCWAVEFORMATEX:


Why is this type creating dramas?
Is my dsound file corrupt or something?

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