Copyright © 2006-2019 MultiMedia Soft

SetInputDeviceChannelVolume method

Previous pageReturn to chapter overviewNext page

Remarks

 

Sets the new volume for the given channel on the given input device

 

The chosen channel's current volume can be retrieved using the GetInputDeviceChannelVolume method.

 

The total number of available input channels for the given input device can be obtained using the GetInputDeviceChannelsCount method.

 

IMPORTANT NOTE ABOUT THE WINDOWS VERSION: This method is only intended for usage when the operating system is Windows XP or older versions; for Windows Vista and higher versions it's recommended using methods exposed by the CoreAudioDevicesMan class.

 

 

Syntax

 

[Visual Basic]

Public Function SetInputDeviceChannelVolume (

nInputDevice as Int16,

nInputChannel as Int16,

nVolume as Int16

) as Int16


 

[C#]

public Int16 SetInputDeviceChannelVolume (

Int16 nInputDevice,

Int16 nInputChannel,

Int16 nVolume

);


 

[C++]

public: Int16 SetInputDeviceChannelVolume (

Int16 nInputDevice,

Int16 nInputChannel,

Int16 nVolume

);


 

 

Parameter

Description

 

 

nInputDevice

Number representing the zero-based index of the input device

nInputChannel

Number representing the zero-based index of the requested input channel (Microphone, Stereo Mix, Line-In, etc.)

nVolume

The new channel's volume: can be a value between 0 and 100

 

 

 

Return value

 

Value

Meaning

 

 

Negative value

An error occurred. Check the LastError property value in order to see the last error.

enumErrorCodes.ERR_NOERROR (0)

The method call was successful.