SOUND4 BIGVOICE.CL Library [1.1.6]
Loading...
Searching...
No Matches
Namespaces | Classes | Typedefs | Functions | Variables
sound4::bigvoice::dyn Namespace Reference

Namespaces

namespace  helper
 

Classes

class  CBus
 Shared Bus. More...
 
class  CDynLib
 Dynamic library interface. More...
 
class  CInstance
 Instance handling class. More...
 
class  CPresetLoader
 Custom preset handler helper. More...
 

Typedefs

using SampleFormat = bigvoice_SampleFormat
 
using LogSeverity = bigvoice_LogSeverity
 
using log_cb_t = std::function< void(LogSeverity, const std::string &)>
 
using PresetChange_Kind = bigvoice_PresetChange_Kind
 

Functions

static std::string GetVersion (CDynLib &dynlib)
 
static unsigned int GetChunkSizeInFrames (CDynLib &dynlib)
 
static std::vector< unsigned int > GetPossibleChunkSizeInFrames (CDynLib &dynlib)
 
static unsigned int GetChannelCount (CDynLib &dynlib)
 
static unsigned int GetAudioInputCount (CDynLib &dynlib)
 
static unsigned int GetAudioOutputCount (CDynLib &dynlib)
 
static unsigned int GetSampleRate (CDynLib &dynlib)
 
static void SanityCheck (CDynLib &dynlib, bool a_bCheckFrames=true)
 
static std::string GetFormatName (CDynLib &dynlib, const SampleFormat fmt)
 
static SampleFormat GetFormatFromName (CDynLib &dynlib, const std::string &name)
 
static unsigned int GetBytesFromFormat (CDynLib &dynlib, const SampleFormat fmt)
 
static void _log_cb_c (bigvoice_LogSeverity severity, const char *c_msg)
 
static void SetLogSeverity (CDynLib &dynlib, LogSeverity severity)
 
static void SetLoggerCallback (CDynLib &dynlib, log_cb_t cb)
 

Variables

static constexpr const char * process_name = "SOUND4 BIGVOICE.CL"
 
static constexpr const char * process_shortname = "bigvoice"
 
const size_t ChunkFrames = 12
 
const size_t InputChannels = 1 * 1
 
const size_t OutputChannels = 1 * 1
 
const size_t InputSampleSize =ChunkFrames*InputChannels
 
const size_t OutputSampleSize =ChunkFrames*OutputChannels
 
const size_t SampleRate = 48000
 
static log_cb_t _log_cb
 

Detailed Description

Dynamic loading namespace

Typedef Documentation

◆ log_cb_t

using sound4::bigvoice::dyn::log_cb_t = typedef std::function<void(LogSeverity,const std::string&)>

Log callback type

Definition at line 842 of file sound4.bigvoice.cl_dyn.hpp.

◆ LogSeverity

Log Severity levels

Definition at line 838 of file sound4.bigvoice.cl_dyn.hpp.

◆ PresetChange_Kind

Definition at line 916 of file sound4.bigvoice.cl_dyn.hpp.

◆ SampleFormat

Definition at line 476 of file sound4.bigvoice.cl_dyn.hpp.

Function Documentation

◆ _log_cb_c()

static void sound4::bigvoice::dyn::_log_cb_c ( bigvoice_LogSeverity  severity,
const char *  c_msg 
)
inlinestatic

Definition at line 849 of file sound4.bigvoice.cl_dyn.hpp.

◆ GetAudioInputCount()

static unsigned int sound4::bigvoice::dyn::GetAudioInputCount ( CDynLib dynlib)
inlinestatic

Get the number of inputs for this process

Remarks
All inputs have GetChannelCount() channels
Parameters
dynlibthe dynamic library
Returns
The process input count

Definition at line 741 of file sound4.bigvoice.cl_dyn.hpp.

◆ GetAudioOutputCount()

static unsigned int sound4::bigvoice::dyn::GetAudioOutputCount ( CDynLib dynlib)
inlinestatic

Get the number of outputs for this process

Remarks
All outputs have GetChannelCount() channels
Parameters
dynlibthe dynamic library
Returns
The process outputs count

Definition at line 754 of file sound4.bigvoice.cl_dyn.hpp.

◆ GetBytesFromFormat()

static unsigned int sound4::bigvoice::dyn::GetBytesFromFormat ( CDynLib dynlib,
const SampleFormat  fmt 
)
inlinestatic

Get the format byte size

Parameters
dynlibthe dynamic library
fmtthe format
Returns
the number of bytes used by this format for a single channel audio sample

Definition at line 830 of file sound4.bigvoice.cl_dyn.hpp.

◆ GetChannelCount()

static unsigned int sound4::bigvoice::dyn::GetChannelCount ( CDynLib dynlib)
inlinestatic

Get the number of channels needed by this process

Parameters
dynlibthe dynamic library
Returns
The process channels count

Definition at line 728 of file sound4.bigvoice.cl_dyn.hpp.

◆ GetChunkSizeInFrames()

static unsigned int sound4::bigvoice::dyn::GetChunkSizeInFrames ( CDynLib dynlib)
inlinestatic

Get the default number of frames in a process chunk.

The output will be available only by chunks of this size.

Note
A Frame is a set of GetChannelCount samples
Deprecated:
Use GetPossibleChunkSizeInFrames
Parameters
dynlibthe dynamic library
Returns
The process chunk size in frame

Definition at line 695 of file sound4.bigvoice.cl_dyn.hpp.

◆ GetFormatFromName()

static SampleFormat sound4::bigvoice::dyn::GetFormatFromName ( CDynLib dynlib,
const std::string &  name 
)
inlinestatic

Convert string to format

Parameters
dynlibthe dynamic library
namethe format string
Returns
the matching format, or INVALID_FORMAT if invalid.

Definition at line 818 of file sound4.bigvoice.cl_dyn.hpp.

◆ GetFormatName()

static std::string sound4::bigvoice::dyn::GetFormatName ( CDynLib dynlib,
const SampleFormat  fmt 
)
inlinestatic

Convert format to string

Parameters
dynlibthe dynamic library
fmtthe format
Returns
the string name of the format

Definition at line 806 of file sound4.bigvoice.cl_dyn.hpp.

◆ GetPossibleChunkSizeInFrames()

static std::vector< unsigned int > sound4::bigvoice::dyn::GetPossibleChunkSizeInFrames ( CDynLib dynlib)
inlinestatic

Get the possibles number of frames in a process chunk.

The output will be available only by chunks of this size.

Note
A Frame is a set of GetChannelCount samples
Parameters
dynlibthe dynamic library
Returns
An vector of possible process chunk size in frame

Definition at line 709 of file sound4.bigvoice.cl_dyn.hpp.

◆ GetSampleRate()

static unsigned int sound4::bigvoice::dyn::GetSampleRate ( CDynLib dynlib)
inlinestatic

Get the processing sample-rate

Remarks
For now, always return 48000, but should be checked for backward compatibility
Parameters
dynlibthe dynamic library
Returns
The process sample-rate in Hz

Definition at line 767 of file sound4.bigvoice.cl_dyn.hpp.

◆ GetVersion()

static std::string sound4::bigvoice::dyn::GetVersion ( CDynLib dynlib)
inlinestatic

Get the process version string

Parameters
dynlibthe dynamic library
Returns
version string

Definition at line 679 of file sound4.bigvoice.cl_dyn.hpp.

◆ SanityCheck()

static void sound4::bigvoice::dyn::SanityCheck ( CDynLib dynlib,
bool  a_bCheckFrames = true 
)
inlinestatic

Checks for library compatibility with const/defines

Exceptions
std::runtime_erroron failure
Parameters
dynlibthe dynamic library
a_bCheckFramesif false, do not check chunk size

Definition at line 779 of file sound4.bigvoice.cl_dyn.hpp.

◆ SetLoggerCallback()

static void sound4::bigvoice::dyn::SetLoggerCallback ( CDynLib dynlib,
log_cb_t  cb 
)
inlinestatic

Sets the log callback. If not set, console output will be used.

Definition at line 863 of file sound4.bigvoice.cl_dyn.hpp.

◆ SetLogSeverity()

static void sound4::bigvoice::dyn::SetLogSeverity ( CDynLib dynlib,
LogSeverity  severity 
)
inlinestatic

Sets the log severity (global)

Definition at line 856 of file sound4.bigvoice.cl_dyn.hpp.

Variable Documentation

◆ _log_cb

log_cb_t sound4::bigvoice::dyn::_log_cb
static

internal helpers for C log callbacks

Definition at line 847 of file sound4.bigvoice.cl_dyn.hpp.

◆ ChunkFrames

const size_t sound4::bigvoice::dyn::ChunkFrames = 12

Number of frames in a chunk

Deprecated:
use GetPossibleChunkSizeInFrames()

Definition at line 481 of file sound4.bigvoice.cl_dyn.hpp.

◆ InputChannels

const size_t sound4::bigvoice::dyn::InputChannels = 1 * 1

Number of float values in an input frame

Deprecated:
Use GetChannelCount and GetAudioInputCount

Definition at line 486 of file sound4.bigvoice.cl_dyn.hpp.

◆ InputSampleSize

const size_t sound4::bigvoice::dyn::InputSampleSize =ChunkFrames*InputChannels

Number of float values for an input chunk

Deprecated:
Use GetPossibleChunkSizeInFrames and GetAudioInputCount

Definition at line 496 of file sound4.bigvoice.cl_dyn.hpp.

◆ OutputChannels

const size_t sound4::bigvoice::dyn::OutputChannels = 1 * 1

Number of float values in an output frame

Deprecated:
Use GetChannelCount and GetAudioOutputCount

Definition at line 491 of file sound4.bigvoice.cl_dyn.hpp.

◆ OutputSampleSize

const size_t sound4::bigvoice::dyn::OutputSampleSize =ChunkFrames*OutputChannels

Number of float values for an output chunk

Deprecated:
Use GetPossibleChunkSizeInFrames and GetAudioOutputCount

Definition at line 501 of file sound4.bigvoice.cl_dyn.hpp.

◆ process_name

constexpr const char* sound4::bigvoice::dyn::process_name = "SOUND4 BIGVOICE.CL"
staticconstexpr

Definition at line 474 of file sound4.bigvoice.cl_dyn.hpp.

◆ process_shortname

constexpr const char* sound4::bigvoice::dyn::process_shortname = "bigvoice"
staticconstexpr

Definition at line 475 of file sound4.bigvoice.cl_dyn.hpp.

◆ SampleRate

const size_t sound4::bigvoice::dyn::SampleRate = 48000

Sample rate of library

Deprecated:
Use GetSampleRate

Definition at line 506 of file sound4.bigvoice.cl_dyn.hpp.