This class represents a short wave file, in Windows WAV format, that can be stored in memory and played. Currently this class is implemented on Windows and GTK (Linux) only.
Derived from
Include files
<wx/wave.h>
Members
wxWave::wxWave
wxWave::~wxWave
wxWave::Create
wxWave::IsOk
wxWave::Play
wxWave()
Default constructor.
wxWave(const wxString& fileName, bool isResource = FALSE)
Constructs a wave object from a file or resource. Call wxWave::IsOk to determine whether this succeeded.
Parameters
fileName
isResource
~wxWave()
Destroys the wxWave object.
bool Create(const wxString& fileName, bool isResource = FALSE)
Constructs a wave object from a file or resource.
Parameters
fileName
isResource
Return value
TRUE if the call was successful, FALSE otherwise.
bool IsOk() const
Returns TRUE if the object contains a successfully loaded file or resource, FALSE otherwise.
bool Play(bool async = TRUE, bool looped = FALSE) const
Plays the wave file synchronously or asynchronously, looped or single-shot.