Kodi Development  20.0
for Binary and Script based Add-Ons

Detailed Description

Audio format structure
The audio format structure that fully defines a stream's audio information.

With the help of this format information, Kodi adjusts its processing accordingly.

The following table contains values that can be set with class AudioEngineFormat :

Name Type Set call Get call
Data format, see AudioEngineDataFormat for available types enum SetDataFormat GetDataFormat
Sample rate unsigned int SetSampleRate GetSampleRate
Encoded rate unsigned int SetEncodedRate GetEncodedRate
Channel layout, see AudioEngineChannel for available types std::vector<enum AudioEngineChannel> SetChannelLayout GetChannelLayout
Frames amount unsigned int SetFramesAmount GetFramesAmount
Frame size unsigned int SetFrameSize GetFrameSize

Further is CompareFormat included to compare this class with another.

Modules

 <em>Value Help</em>
 

Function Documentation

◆ SetDataFormat()

void SetDataFormat ( enum AudioEngineDataFormat  format)
inline

The stream's data format (eg, AUDIOENGINE_FMT_S16LE)

◆ GetDataFormat()

enum AudioEngineDataFormat GetDataFormat ( ) const
inline

To get with SetDataFormat changed values.

◆ SetSampleRate()

void SetSampleRate ( unsigned int  rate)
inline

The stream's sample rate (eg, 48000)

◆ GetSampleRate()

unsigned int GetSampleRate ( ) const
inline

To get with SetSampleRate changed values.

◆ SetEncodedRate()

void SetEncodedRate ( unsigned int  rate)
inline

The encoded streams sample rate if a bitstream, otherwise undefined.

◆ GetEncodedRate()

unsigned int GetEncodedRate ( ) const
inline

To get with SetEncodedRate changed values.

◆ SetChannelLayout()

void SetChannelLayout ( const std::vector< enum AudioEngineChannel > &  layout)
inline

The stream's channel layout.

◆ GetChannelLayout()

std::vector<enum AudioEngineChannel> GetChannelLayout ( ) const
inline

To get with SetChannelLayout changed values.

◆ SetFramesAmount()

void SetFramesAmount ( unsigned int  frames)
inline

The number of frames per period.

◆ GetFramesAmount()

unsigned int GetFramesAmount ( ) const
inline

To get with SetFramesAmount changed values.

◆ SetFrameSize()

void SetFrameSize ( unsigned int  frameSize)
inline

The size of one frame in bytes.

◆ GetFrameSize()

unsigned int GetFrameSize ( ) const
inline

To get with SetFrameSize changed values.

◆ CompareFormat()

bool CompareFormat ( const AudioEngineFormat fmt)
inline

Function to compare the format structure with another.