HephAudio v3.0.6
A cross-platform C++ library for recording, playing, and processing audio on Windows, Android, Linux, iOS, and macOS.
Loading...
Searching...
No Matches
HephAudio::AudioChannelLayout Struct Reference

stores information about the channel layout. More...

#include <AudioChannelLayout.h>

Public Member Functions

constexpr AudioChannelLayout ()
 
constexpr AudioChannelLayout (uint16_t count, AudioChannelMask mask)
 
constexpr bool operator== (const AudioChannelLayout &rhs) const
 
constexpr bool operator!= (const AudioChannelLayout &rhs) const
 

Static Public Member Functions

static constexpr AudioChannelMask DefaultChannelMask (uint16_t channelCount)
 
static constexpr AudioChannelLayout DefaultChannelLayout (uint16_t channelCount)
 
static constexpr uint16_t GetChannelCount (AudioChannelMask mask)
 
static constexpr uint16_t GetChannelCount (const AudioChannelLayout &layout)
 
static std::vector< AudioChannelMaskGetChannelMapping (AudioChannelMask mask)
 
static std::vector< AudioChannelMaskGetChannelMapping (const AudioChannelLayout &layout)
 

Public Attributes

uint16_t count
 
AudioChannelMask mask
 

Detailed Description

stores information about the channel layout.

Constructor & Destructor Documentation

◆ AudioChannelLayout() [1/2]

HephAudio::AudioChannelLayout::AudioChannelLayout ( )
inlineconstexpr

creates a new instance and initializes it with default values.

◆ AudioChannelLayout() [2/2]

HephAudio::AudioChannelLayout::AudioChannelLayout ( uint16_t count,
AudioChannelMask mask )
inlineconstexpr

creates a new instance and initializes it with the provided values.

Parameters
countnumber of channels present.
maskindicates which channels are used.

Member Function Documentation

◆ DefaultChannelMask()

static constexpr AudioChannelMask HephAudio::AudioChannelLayout::DefaultChannelMask ( uint16_t channelCount)
inlinestaticconstexpr

gets the default channel mask for the channelCount.

◆ DefaultChannelLayout()

static constexpr AudioChannelLayout HephAudio::AudioChannelLayout::DefaultChannelLayout ( uint16_t channelCount)
inlinestaticconstexpr

gets the default channel layout for the channelCount.

◆ GetChannelCount() [1/2]

static constexpr uint16_t HephAudio::AudioChannelLayout::GetChannelCount ( AudioChannelMask mask)
inlinestaticconstexpr

gets the number of channels used.

◆ GetChannelCount() [2/2]

static constexpr uint16_t HephAudio::AudioChannelLayout::GetChannelCount ( const AudioChannelLayout & layout)
inlinestaticconstexpr

gets the number of channels used in the layout.

◆ GetChannelMapping() [1/2]

static std::vector< AudioChannelMask > HephAudio::AudioChannelLayout::GetChannelMapping ( AudioChannelMask mask)
static

gets the channel mapping that corresponds to the channel mask.

◆ GetChannelMapping() [2/2]

static std::vector< AudioChannelMask > HephAudio::AudioChannelLayout::GetChannelMapping ( const AudioChannelLayout & layout)
static

gets the channel mapping that corresponds to the channel layout.

Member Data Documentation

◆ count

uint16_t HephAudio::AudioChannelLayout::count

number of channels present.

◆ mask

AudioChannelMask HephAudio::AudioChannelLayout::mask

indicates which channels are used.