AudioSignalProblem Enum

Definition

Important

Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.

Contains a list of possible problems in the audio signal coming in to a speech recognition engine.

C#
public enum AudioSignalProblem
Inheritance
AudioSignalProblem

Fields

Name Value Description
None 0

No problems with audio input.

TooNoisy 1

Audio input has too much background noise.

NoSignal 2

Audio input is not detected.

TooLoud 3

Audio input is too loud.

TooSoft 4

Audio input is too quiet.

TooFast 5

Audio input is too fast.

TooSlow 6

Audio input is too slow.

Examples

The following example defines an event handler that gathers information about an AudioSignalProblemOccurred event.

C#
private SpeechRecognitionEngine sre;  

// Initialize the speech recognition engine.  
private void Initialize()  
{  
  sre = new SpeechRecognitionEngine();  

  // Add a handler for the AudioSignalProblemOccurred event.  
  sre.AudioSignalProblemOccurred += new EventHandler<AudioSignalProblemOccurredEventArgs>(sre_AudioSignalProblemOccurred);  
}  

// Gather information when the AudioSignalProblemOccurred event is raised.  
void sre_AudioSignalProblemOccurred(object sender, AudioSignalProblemOccurredEventArgs e)  
{  
  StringBuilder details = new StringBuilder();  

  details.AppendLine("Audio signal problem information:");  
  details.AppendFormat(  
    " Audio level:               {0}" + Environment.NewLine +  
    " Audio position:            {1}" + Environment.NewLine +  
    " Audio signal problem:      {2}" + Environment.NewLine +  
    " Recognition engine audio position: {3}" + Environment.NewLine,  
    e.AudioLevel, e.AudioPosition, e.AudioSignalProblem,  
    e.recoEngineAudioPosition);  

  // Insert additional event handler code here.  
}  

Remarks

The AudioSignalProblemOccurredEventArgs.AudioSignalProblem property gets a member of this enumeration when the SpeechRecognitionEngine or SpeechRecognizer raises a AudioSignalProblemOccurred event.

Applies to

Product Versions
.NET 8 (package-provided), 9 (package-provided), 10 (package-provided)
.NET Framework 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
.NET Standard 2.0 (package-provided)

See also