Microsoft DirectX 8.0 (C++) |
The IDirectMusic8::Activate method activates or deactivates all ports created from this interface.
HRESULT Activate( BOOL fEnable );
If the method succeeds, the return value is S_OK.
If it fails, the method can return DSERR_NODRIVER, indicating that no sound driver is present.
Applications should call IDirectMusic8::Activate(FALSE) when they lose input focus if they do not need to play music in the background. This allows another application that has the input focus to have access to the ports. When the application has input focus again, it should call Activate(TRUE) to enable all its allocated ports.
Header: Declared in dmusicc.h.