IBasicAudio::put_Volume method

The put_Volume method sets the volume (amplitude) of the audio signal.

Syntax

HRESULT put_Volume(
  long lVolume
);

Parameters

lVolume

Specifies the volume, as a number from –10,000 to 0, inclusive. Full volume is 0, and –10,000 is silence. Multiply the desired decibel level by 100. For example, –10,000 = –100 dB.

Return Value

Returns an HRESULT value. Possible values include the following.

Return code Description
E_FAIL
The underlying audio device returned an error.
E_INVALIDARG
The value of lVolume is invalid.
E_NOTIMPL
The filter graph does not contain an audio renderer filter. (Possibly the source does not contain an audio stream.)
S_OK
Success.

Requirements

   
Minimum supported client Windows 2000 Professional [desktop apps only]
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header control.h (include Dshow.h)
Library Strmiids.lib

See Also

Error and Success Codes

IBasicAudio Interface