openMSX
Classes | Public Member Functions | List of all members
openmsx::WavData Class Reference

#include <WavData.hh>

Public Member Functions

 WavData ()=default
 Construct empty wav. More...
 
template<typename Filter = NoFilter>
 WavData (const std::string &filename, Filter filter={})
 Construct from .wav file and optional filter. More...
 
template<typename Filter = NoFilter>
 WavData (File file, Filter filter={})
 
unsigned getFreq () const
 
unsigned getSize () const
 
int16_t getSample (unsigned pos) const
 

Detailed Description

Definition at line 13 of file WavData.hh.

Constructor & Destructor Documentation

◆ WavData() [1/3]

openmsx::WavData::WavData ( )
default

Construct empty wav.

Referenced by WavData().

◆ WavData() [2/3]

template<typename Filter = NoFilter>
openmsx::WavData::WavData ( const std::string &  filename,
Filter  filter = {} 
)
inlineexplicit

Construct from .wav file and optional filter.

Definition at line 26 of file WavData.hh.

References WavData().

◆ WavData() [3/3]

template<typename Filter >
openmsx::WavData::WavData ( File  file,
Filter  filter = {} 
)
inlineexplicit

Definition at line 60 of file WavData.hh.

References openmsx::File::mmap().

Member Function Documentation

◆ getFreq()

unsigned openmsx::WavData::getFreq ( ) const
inline

Definition at line 32 of file WavData.hh.

Referenced by openmsx::WavAudioInput::readSample(), and TEST_CASE().

◆ getSample()

int16_t openmsx::WavData::getSample ( unsigned  pos) const
inline

◆ getSize()

unsigned openmsx::WavData::getSize ( ) const
inline

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