Photon Voice v2.53

Public Member Functions | List of all members
IAudioPusher< T > Interface Template Reference

Audio Pusher interface. More...

Inherits IAudioDesc.

Inherited by AudioUtil.GeneratorPusher< T >.

Public Member Functions

void SetCallback (Action< T[]> callback, ObjectFactory< T[], int > bufferFactory)
 Set the callback function used for pushing data. More...
 

Additional Inherited Members

- Properties inherited from IAudioDesc
int SamplingRate [get]
 Sampling rate of the audio signal (in Hz). More...
 
int Channels [get]
 Number of channels in the audio signal. More...
 
string Error [get]
 If not null, audio object is in invalid state. More...
 

Detailed Description

Audio Pusher interface.

Opposed to an IAudioReader (which will deliver audio data when it is "pulled"), an IAudioPusher will push its audio data whenever it is ready,

Member Function Documentation

◆ SetCallback()

void SetCallback ( Action< T[]>  callback,
ObjectFactory< T[], int >  bufferFactory 
)

Set the callback function used for pushing data.

Parameters
callbackCallback function to use.
bufferFactoryBuffer factory used to create the buffer that is pushed to the callback

Implemented in AudioUtil.GeneratorPusher< T >.