SDL3pp
A slim C++ wrapper for SDL3
Loading...
Searching...
No Matches
Public Member Functions | List of all members
SDL::AudioFormat Class Reference

Audio format. More...

Public Member Functions

constexpr AudioFormat (AudioFormatRaw audioFormat={}) noexcept
 Wraps AudioFormat. More...
 
constexpr AudioFormat (bool sign, bool bigendian, bool flt, Uint16 size)
 Define an AudioFormat value. More...
 
constexpr operator AudioFormatRaw () const noexcept
 Unwraps to the underlying AudioFormat. More...
 
constexpr Uint16 GetBitSize () const
 Retrieve the size, in bits, from an AudioFormat. More...
 
constexpr Uint16 GetByteSize () const
 Retrieve the size, in bytes, from an AudioFormat. More...
 
constexpr bool IsFloat () const
 Determine if an AudioFormat represents floating point data. More...
 
constexpr bool IsBigEndian () const
 Determine if an AudioFormat represents bigendian data. More...
 
constexpr bool IsLittleEndian () const
 Determine if an AudioFormat represents littleendian data. More...
 
constexpr bool IsSigned () const
 Determine if an AudioFormat represents signed data. More...
 
constexpr bool IsInt () const
 Determine if an AudioFormat represents integer data. More...
 
constexpr bool IsUnsigned () const
 Determine if an AudioFormat represents unsigned data. More...
 
const char * GetName () const
 Get the human readable name of an audio format. More...
 
int GetSilenceValue () const
 Get the appropriate memset value for silencing an audio format. More...
 

Detailed Description

Since
This enum is available since SDL 3.2.0.
See also
AudioFormat.GetBitSize
AudioFormat.GetByteSize
AudioFormat.IsInt
AudioFormat.IsFloat
AudioFormat.IsBigEndian
AudioFormat.IsLittleEndian
AudioFormat.IsSigned
AudioFormat.IsUnsigned

Constructor & Destructor Documentation

◆ AudioFormat()

constexpr SDL::AudioFormat::AudioFormat ( AudioFormatRaw  audioFormat = {})
inlineconstexprnoexcept
Parameters
audioFormatthe value to be wrapped

Member Function Documentation

◆ operator AudioFormatRaw()

constexpr SDL::AudioFormat::operator AudioFormatRaw ( ) const
inlineconstexprnoexcept
Returns
the underlying AudioFormatRaw.

The documentation for this class was generated from the following file: