]> git.saurik.com Git - wxWidgets.git/blame - contrib/include/wx/mmedia/sndwav.h
[ 1176516 ] argv datatype has changed (char in docs but really wxChar)
[wxWidgets.git] / contrib / include / wx / mmedia / sndwav.h
CommitLineData
e8482f24
GL
1// --------------------------------------------------------------------------
2// Name: sndwav.h
3// Purpose:
4// Date: 08/11/1999
5// Author: Guilhem Lavaux <lavaux@easynet.fr> (C) 1999
6// CVSID: $Id$
05aa8cf3 7// License: wxWindows license
e8482f24
GL
8// --------------------------------------------------------------------------
9#ifndef _WX_SNDWAV_H
10#define _WX_SNDWAV_H
11
12#ifdef __GNUG__
13#pragma interface "sndwav.h"
14#endif
15
16#include "wx/defs.h"
17#include "wx/string.h"
18#include "wx/stream.h"
19#include "wx/datstrm.h"
15e8daec 20#include "wx/mmedia/defs.h"
e8482f24
GL
21#include "wx/mmedia/sndbase.h"
22#include "wx/mmedia/sndcodec.h"
23#include "wx/mmedia/sndfile.h"
24
25//
26// WAVE codec
27//
28
29class wxSoundWave: public wxSoundFileStream {
30public:
31 wxSoundWave(wxInputStream& stream, wxSoundStream& io_sound);
32 wxSoundWave(wxOutputStream& stream, wxSoundStream& io_sound);
33 ~wxSoundWave();
34
35 bool CanRead();
36 wxString GetCodecName() const;
37
38protected:
39 bool PrepareToPlay();
40 bool PrepareToRecord(wxUint32 time);
41 bool FinishRecording();
42 bool RepositionStream(wxUint32 position);
43
44 wxUint32 GetData(void *buffer, wxUint32 len);
45 wxUint32 PutData(const void *buffer, wxUint32 len);
46
c42b1de6
GL
47 bool HandleOutputPCM(wxDataInputStream& data, wxUint32 len,
48 wxUint16 channels, wxUint32 sample_fq,
49 wxUint32 byte_p_sec, wxUint16 byte_p_spl,
50 wxUint16 bits_p_spl);
51 bool HandleOutputMSADPCM(wxDataInputStream& data, wxUint32 len,
52 wxUint16 channels, wxUint32 sample_fq,
53 wxUint32 byte_p_sec, wxUint16 byte_p_spl,
54 wxUint16 bits_p_spl);
55 bool HandleOutputG721(wxDataInputStream& data, wxUint32 len,
56 wxUint16 channels, wxUint32 sample_fq,
57 wxUint32 byte_p_sec, wxUint16 byte_p_spl,
58 wxUint16 bits_p_spl);
e8482f24
GL
59 wxSoundFormatBase *HandleInputPCM(wxDataOutputStream& data);
60 wxSoundFormatBase *HandleInputG72X(wxDataOutputStream& data);
61
62protected:
63 off_t m_base_offset;
64};
65
66#endif