The main class for utilizing the Yobe BioListener functionality.
More...
#include <yobe_bio_listener.hpp>
The main class for utilizing the Yobe BioListener functionality.
This class provides an interface to use the Yobe BioListener algorithm for processing audio samples. The algorithm analyzes the audio to detect biological signals and can be used to determine the presence of a human voice.
◆ Init() [1/2]
virtual Status Yobe::BioListener::Init |
( |
const char * |
license | ) |
|
|
pure virtual |
Initializes the Yobe BioListener algorithm.
This function initializes the internals of the Yobe BioListener algorithm. It takes a license as a parameter, which must be provided by Yobe. If the initialization fails, the returned status will indicate the cause of failure.
- Parameters
-
[in] | license | A license provided by Yobe. |
- Returns
- The status of the Yobe BioListener algorithm after initialization.
◆ Init() [2/2]
virtual Status Yobe::BioListener::Init |
( |
const char * |
license, |
|
|
VoiceTarget |
voice_target |
|
) |
| |
|
pure virtual |
Initializes the Yobe BioListener algorithm for a specific voice target.
This function initializes the internals of the Yobe BioListener algorithm for a specific voice target. It takes a license and a voice target as parameters. If the initialization fails, the returned status will indicate the cause of failure.
- Parameters
-
[in] | license | A license provided by Yobe. |
[in] | voice_target | The near or far voice target. |
- Returns
- The status of the Yobe BioListener algorithm after initialization.
◆ Deinit()
virtual Status Yobe::BioListener::Deinit |
( |
| ) |
|
|
pure virtual |
Cleans up the internals of the Yobe BioListener algorithm.
This function deinitializes the internals of the Yobe BioListener algorithm. If the deinitialization fails, the returned status will indicate the cause of failure.
- Returns
- The status of the Yobe BioListener algorithm after deinitialization.
◆ GetStatus()
virtual Status Yobe::BioListener::GetStatus |
( |
| ) |
const |
|
pure virtual |
◆ GetVoiceTarget()
virtual VoiceTarget Yobe::BioListener::GetVoiceTarget |
( |
| ) |
const |
|
pure virtual |
Gets the voice target status for the Yobe BioListener algorithm.
This function returns the voice target status for the Yobe BioListener algorithm, depending on the package.
- Returns
- The voice target status for the Yobe BioListener algorithm.
◆ ProcessBuffer() [1/2]
virtual Status Yobe::BioListener::ProcessBuffer |
( |
const int16_t * |
in_samples, |
|
|
int16_t * |
out_samples, |
|
|
uint32_t |
in_sample_count, |
|
|
uint32_t * |
out_sample_count |
|
) |
| |
|
pure virtual |
ProcessBuffer processes two channel interleaved audio and populates the output buffer with the processed audio.
This function takes two channel interleaved audio as input and applies processing to the audio. The processed audio is then written to the output buffer in interleaved format. The size of the output buffer should be pre-allocated to hold the processed audio samples.
- Parameters
-
[in] | in_samples | A pointer to the buffer containing the interleaved input audio samples. |
[out] | out_samples | A pre-allocated buffer for the interleaved processed audio samples. |
[in] | in_sample_count | The number of audio samples in the input buffer. |
[in,out] | out_sample_count | A pointer to the number of audio samples in the output buffer. The actual number of processed audio samples will be written to this variable by the function. |
- Returns
- The status of the Yobe BioListener library after processing the audio buffer.
- Note
- If the input buffer size is not the correct size, the library will return a NEEDS_MORE_DATA error code.
-
In case of any error, the value pointed to by out_sample_count will be set to 0.
◆ ProcessBuffer() [2/2]
virtual Status Yobe::BioListener::ProcessBuffer |
( |
const double * |
in_samples, |
|
|
double * |
out_samples, |
|
|
uint32_t |
in_sample_count, |
|
|
uint32_t * |
out_sample_count |
|
) |
| |
|
pure virtual |
ProcessBuffer processes two channel interleaved audio and populates the output buffer with the processed audio.
This function takes two channel interleaved audio as input and applies processing to the audio. The processed audio is then written to the output buffer in interleaved format. The size of the output buffer should be pre-allocated to hold the processed audio samples.
- Parameters
-
[in] | in_samples | A pointer to the buffer containing the interleaved input audio samples. |
[out] | out_samples | A pre-allocated buffer for the interleaved processed audio samples. |
[in] | in_sample_count | The number of audio samples in the input buffer. |
[in,out] | out_sample_count | A pointer to the number of audio samples in the output buffer. The actual number of processed audio samples will be written to this variable by the function. |
- Returns
- The status of the Yobe BioListener library after processing the audio buffer.
- Note
- If the input buffer size is not the correct size, the library will return a NEEDS_MORE_DATA error code.
-
In case of any error, the value pointed to by out_sample_count will be set to 0.
The documentation for this struct was generated from the following file: