[directmusic] Re: Why can't I get MIXIN_BUFFER interfaces?

  • From: "James Dooley" <jdooley@xxxxxxxxxxxxx>
  • To: <directmusic@xxxxxxxxxxxxx>
  • Date: Fri, 27 Sep 2002 13:39:58 -0700

This is a nuance of the GetObjectInPath method.  Mixin buffers aren't
channel specific, so you need to pass 0 instead of DMUS_PCHANNEL_ALL for
dwPChannel.  It does say this in the "Remarks" section of the
documentation for IDirectMusicAudioPath8::GetObjectInPath, but it's easy
to miss.  You have to notice that DMUS_PATH_MIXIN_BUFFER is not in the
list of channel-specific stages (which means that you must pass 0 for
dwPChannel when using that stage).

-james

This posting is provided "AS IS" with no warranties, and confers no
rights.

-----Original Message-----
From: Andrew Clark [mailto:andrewclarkis@xxxxxxxxxxx]=20
Sent: Friday, September 27, 2002 12:53 PM
To: directmusic@xxxxxxxxxxxxx
Subject: [directmusic] Why can't I get MIXIN_BUFFER interfaces?



Hey gang! Another DX8.1 API question for the c++ gurus.

I don't seem to be able to get MIXIN_BUFFER interfaces with=20
pAudiopath->GetObjectInPath().  Here is the audiopath I'm trying to use:

Audiopath Designer:

Mix Group       Bus     Buffer                  Effects List
Shared Verb---- None    User Defined (shared)   I3DL2Reverb2
Shared Echo---- None    User Defined (shared)   Echo1 | Send(Shared
Verb)
1: Mix Group--- Stereo  User Defined            Custom DMO | Send
(Shared Verb) | Send=20
(Shared Echo)

I can get an interface to my custom DMO no problem with=20
GetObjectInPath(DMUS_PATH_BUFFER_DMO), but try as I might I can't get an

interface to the Echo1 DMO with DMUS_PATH_MIXIN_BUFFER_DMO.  As a matter
of=20
fact, I can't even get an IDirectSoundBUffer interface with=20
DMUS_PATH_MIXIN_BUFFER.

Does anyone have any idea what might be going on? (Is it because I have
the=20
buffer flagged as shared between audiopaths?)

Cheers,
Andrew

--------------------------------------------------------

sample code that doesn't work:

IDirectSoundBuffer* pBuff =3D NULL;

if(SUCCEEDED(hr =3D pAudioPath->GetObjectInPath(DMUS_PCHANNEL_ALL,
        DMUS_PATH_MIXIN_BUFFER, i,
        GUID_NULL, 0, IID_IDirectSoundBuffer,
        (LPVOID*) &pBuff)))
{
        Log("For some reason this never happens.");
}


_________________________________________________________________
Send and receive Hotmail on your mobile device: http://mobile.msn.com



Other related posts: