|
VoiceSDK
5.3.0
|
Speech endpoint detector class (interface), intended to detect speech end in the audio stream. More...
#include <voicesdk/media/speech.h>
Public Types | |
| using | Ptr = std::shared_ptr< SpeechEndpointDetector > |
Public Member Functions | |
| virtual void | reset ()=0 |
| Resets detector state. More... | |
| virtual void | addSamples (const uint8_t *bytes, size_t bytesNum)=0 |
| Adds PCM16 audio samples to process. More... | |
| virtual void | addSamples (const float *samples, size_t samplesNum)=0 |
| Adds float audio samples to process. More... | |
| virtual void | addSamples (const int16_t *samples, size_t samplesNum)=0 |
| Adds PCM16 audio samples to process. More... | |
| virtual bool | isSpeechEnded ()=0 |
| Returns detection state. More... | |
| virtual | ~SpeechEndpointDetector ()=default |
Static Public Member Functions | |
| static SpeechEndpointDetector::Ptr | create (size_t minSpeechLengthMs, size_t maxSilenceLengthMs, size_t sampleRate) |
| Factory method for creating SpeechEndpointDetector instance. More... | |
Speech endpoint detector class (interface), intended to detect speech end in the audio stream.
| using voicesdk::SpeechEndpointDetector::Ptr = std::shared_ptr<SpeechEndpointDetector> |
|
virtualdefault |
|
pure virtual |
Adds float audio samples to process.
| samples | pointer to array containing normalized (from -1 to 1) float audio samples |
| samplesNum | size of array with samples |
| std::runtime_error | if runtime error occurred |
| voicesdk::LicenseException | if license error occurred |
|
pure virtual |
Adds PCM16 audio samples to process.
| samples | pointer to array with samples |
| samplesNum | size of array with samples |
| std::runtime_error | if runtime error occurred |
| voicesdk::LicenseException | if license error occurred |
|
pure virtual |
Adds PCM16 audio samples to process.
| bytes | pointer to array with samples |
| bytesNum | size of array with samples |
| std::runtime_error | if runtime error occurred |
| voicesdk::LicenseException | if license error occurred |
|
static |
Factory method for creating SpeechEndpointDetector instance.
| minSpeechLengthMs | minimum speech length required to begin speech end detection (ms) |
| maxSilenceLengthMs | silence after speech threshold used to determine if speech is already ended (ms) |
| sampleRate | input signal sampling rate |
| std::runtime_error | if runtime error occurred |
| voicesdk::LicenseException | if license error occurred |
|
pure virtual |
Returns detection state.
|
pure virtual |
Resets detector state.
1.8.17