Jump to content
  • Advertisement
Sign in to follow this  
HeWhoDarez

November 2008 DXSDK - DirectSound

This topic is 3625 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

Hi guys, Just started playing with direct sound today. I created the device as directed but keep recieving E_INVALID ARGS when I call SetCooperativeLevel().

static LPDIRECTSOUND8 lpDS;  //this is a pointer to the DirectSound Object 
static HWND hMainWnd;  //handle to your programs main window 

//////////////////////////////////////////////////////////////////////

//Then the following:

if (DS_OK==DirectSoundCreate8(NULL,&lpDS,NULL)) //create direct sound object
{
        
lpDS->Initialize(NULL);

// Set CoOp level here
HRESULT coopStatus = lpDS->SetCooperativeLevel(hMainWnd, DSSCL_PRIORITY);

//error handling stuff here

}


Is there any way to find which of the arguments is invalid or even why? I speculate that because Im using the new SDK, MS are trying to get us using XACT/XAudio2 but neither support microphones so the option isnt there for me. Besides the methods are still in the header files etc.. I am using Vista with an on board creative card. Any Ideas?

Share this post


Link to post
Share on other sites
Advertisement
Does or did it work with an earlier SDK? Can you revert to an earlier SDK if it helps? If it does work, you might want to let Microsoft know, it might be a bug.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • 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!