Microsoft DirectX 8.0 (C++)

IDirectMusicAudioPath8::SetVolume

Sets the audio volume on the path.

HRESULT SetVolume(
  long lVolume,
  DWORD dwDuration
);

Parameters

lVolume
Value that specifies the attenuation, in hundredths of a decibel. This value must be in the range from -9600 to 0. Zero is full volume.
dwDuration
Value that specifies the time, in milliseconds, over which the volume change takes place. A value of 0 ensures maximum efficiency.

Return Values

If the method succeeds, the return value is S_OK.

If it fails, the method can return one of the following error values:

DMUS_E_NOT_INIT
E_INVALIDARG

Requirements

  Header: Declared in dmusici.h.