• Advertisement

Archived

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

DirectSound header problems

This topic is 6665 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 think you need to include mmsystem.h
(before dsound.h)

-ns

[This message has been edited by NightShade (edited October 22, 1999).]

Share this post


Link to post
Share on other sites
Advertisement
Well, sometimes I don't include the mmsystem.h file and the dsound.h works fine, too?!

Share this post


Link to post
Share on other sites
Yeah, some other files include mmsystem.h,
such as Windows.h. Sometimes under certain circumstances it will or will not include the file (e.g. if WIN32_LEAN_AND_MEAN is defined, Windows.h won't include mmsystem)

-ns

Share this post


Link to post
Share on other sites
Putting mmsystem.h before dsound.h worked, but putting it after didn't. Now I'm getting an error in mmsystem.h!!!

c:\microsoft visual studio\vc98\include\mmsystem.h(113) : error C2146: syntax error : missing ';' before identifier 'MMVERSION'
c:\microsoft visual studio\vc98\include\mmsystem.h(113) : fatal error C1004: unexpected end of file found

Any clues about this?! This is starting to piss me off!

Thanks everyone!

[This message has been edited by Machaira (edited October 22, 1999).]

Share this post


Link to post
Share on other sites
I've created a class as a wrapper for DirectSound and included the dsound.h When I compile I get a huge number of errors in the dsound.h file:

d:\directx7 sdk\include\dsound.h(61) : error C2143: syntax error : missing ';' before '*'
d:\directx7 sdk\include\dsound.h(61) : error C2501: 'LPCWAVEFORMATEX' : missing storage-class or type specifiers
d:\directx7 sdk\include\dsound.h(128) : error C2146: syntax error : missing ';' before identifier 'lpwfxFormat'
d:\directx7 sdk\include\dsound.h(128) : error C2501: 'LPWAVEFORMATEX' : missing storage-class or type specifiers
d:\directx7 sdk\include\dsound.h(128) : error C2501: 'lpwfxFormat' : missing storage-class or type specifiers
d:\directx7 sdk\include\dsound.h(142) : error C2146: syntax error : missing ';' before identifier 'lpwfxFormat'
d:\directx7 sdk\include\dsound.h(142) : error C2501: 'LPWAVEFORMATEX' : missing storage-class or type specifiers
d:\directx7 sdk\include\dsound.h(142) : error C2501: 'lpwfxFormat' : missing storage-class or type specifiers
d:\directx7 sdk\include\dsound.h(193) : error C2146: syntax error : missing ';' before identifier 'lpwfxFormat'
d:\directx7 sdk\include\dsound.h(193) : error C2501: 'LPWAVEFORMATEX' : missing storage-class or type specifiers
d:\directx7 sdk\include\dsound.h(193) : error C2501: 'lpwfxFormat' : missing storage-class or type specifiers
d:\directx7 sdk\include\dsound.h(337) : error C2061: syntax error : identifier 'LPWAVEFORMATEX'
d:\directx7 sdk\include\dsound.h(346) : error C2061: syntax error : identifier 'LPCWAVEFORMATEX'
d:\directx7 sdk\include\dsound.h(607) : error C2061: syntax error : identifier 'LPWAVEFORMATEX'

Any clues anyone?!

Thanks

Share this post


Link to post
Share on other sites
I think I've got it fixed. I included windows.h in the sound class's header. DUH!

Thanks again all.

[This message has been edited by Machaira (edited October 22, 1999).]

Share this post


Link to post
Share on other sites

  • Advertisement