Edit

Share via


ToneController.Send Method

Definition

Overloads

Send(ToneId)

Sends the specified tone at 50% volume.

Send(Int32)

Sends the specified tone at 50% volume.

Send(ToneId, Single)

Sends the specified tone at the specified volume.

Send(Int32, Single)

Sends the specified tone at the specified volume.

Send(ToneId)

Sends the specified tone at 50% volume.

public:
 void Send(Microsoft::Rtc::Collaboration::AudioVideo::ToneId tone);
public void Send (Microsoft.Rtc.Collaboration.AudioVideo.ToneId tone);
member this.Send : Microsoft.Rtc.Collaboration.AudioVideo.ToneId -> unit
Public Sub Send (tone As ToneId)

Parameters

tone
ToneId

The tone to be sent.

Exceptions

Thrown when tone argument is out of range (less than MinTone or greater than MaxTone), or when volume is negative or larger than 100.

Examples

The following example shows how to send a tone through ToneController.

C# Sending a tone through ToneController.


toneController.AttachFlow(audioVideoFlow);
toneController.Send(ToneId.Tone0);



Remarks

Tones will be sent only when all three of the conditions are true. - An active AudioVideoFlow is attached. - AudioVideoFlow.ToneEnabled is equal to true. - AudioVideoFlow.HoldType equals to None.

Applies to

Send(Int32)

Sends the specified tone at 50% volume.

public:
 void Send(int tone);
public void Send (int tone);
member this.Send : int -> unit
Public Sub Send (tone As Integer)

Parameters

tone
Int32

The tone to be sent.

Exceptions

Thrown when tone argument is out of range (less than MinTone or greater than MaxTone).

Remarks

Tones will be sent only when all three of the conditions are true. - An active AudioVideoFlow is attached. - AudioVideoFlow.ToneEnabled is equal to true. - AudioVideoFlow.HoldType equals to None.

Applies to

Send(ToneId, Single)

Sends the specified tone at the specified volume.

public:
 void Send(Microsoft::Rtc::Collaboration::AudioVideo::ToneId tone, float volume);
public void Send (Microsoft.Rtc.Collaboration.AudioVideo.ToneId tone, float volume);
member this.Send : Microsoft.Rtc.Collaboration.AudioVideo.ToneId * single -> unit
Public Sub Send (tone As ToneId, volume As Single)

Parameters

tone
ToneId

The tone to be sent.

volume
Single

The volume, as a percent, of the tone to be sent. This value must be between 50.0 and 100.0, inclusive.

Exceptions

Thrown when the tone is out of range (less than MinTone or greater than MaxTone), or when volume is negative or larger than 100.

Remarks

The minimum volume corresponds to 50 (%) and the maximum volume corresponds to 100 (%). This range of values corresponds to -32 through 0 in decibels (dB), where 0 dB is the maximum volume level. To convert from decibels to the percentage value that is expected by this method, add 63 to the decibel value and divide by 0.63. For example, to send a tone with volume level -10 dB, specify 84.1 (-10 + 63)/0.63.

Applies to

Send(Int32, Single)

Sends the specified tone at the specified volume.

public:
 void Send(int tone, float volume);
public void Send (int tone, float volume);
member this.Send : int * single -> unit
Public Sub Send (tone As Integer, volume As Single)

Parameters

tone
Int32

The tone to be sent.

volume
Single

The volume, as a percent, of the tone to be sent. This value must be between 0 and 100, inclusive.

Exceptions

Thrown when the tone is out of range (less than MinTone or greater than MaxTone), or when volume is negative or larger than 100.

Remarks

The minimum volume corresponds to 50 (%) and the maximum volume corresponds to 100 (%). This range of values corresponds to -32 through 0 in decibels (dB), where 0 dB is the maximum volume level. To convert from decibels to the percentage value that is expected by this method, add 63 to the decibel value and divide by 0.63. For example, to send a tone with volume level -10 dB, specify 84.1 (-10 + 63)/0.63.

Applies to