]> git.saurik.com Git - wxWidgets.git/blob - contrib/include/wx/mmedia/sndesd.h
added .chm support for Unix (Markus Sinner)
[wxWidgets.git] / contrib / include / wx / mmedia / sndesd.h
1 // --------------------------------------------------------------------------
2 // Name: sndesd.h
3 // Purpose:
4 // Date: 08/11/1999
5 // Author: Guilhem Lavaux <lavaux@easynet.fr> (C) 1999
6 // CVSID: $Id$
7 // --------------------------------------------------------------------------
8 #ifndef _WX_SNDESD_H
9 #define _WX_SNDESD_H
10
11 #ifdef __GNUG__
12 #pragma interface "sndesd.h"
13 #endif
14
15 #include "wx/defs.h"
16 #include "wx/string.h"
17 #include "wx/mmedia/defs.h"
18 #include "wx/mmedia/sndbase.h"
19 #include "wx/mmedia/sndpcm.h"
20
21 //
22 // ESD output class
23 //
24
25 class wxSoundStreamESD : public wxSoundStream {
26 public:
27 wxSoundStreamESD(const wxString& hostname = wxT("localhost"));
28 ~wxSoundStreamESD();
29
30 wxSoundStream& Read(void *buffer, wxUint32 len);
31 wxSoundStream& Write(const void *buffer, wxUint32 len);
32
33 bool SetSoundFormat(const wxSoundFormatBase& format);
34
35 bool StartProduction(int evt);
36 bool StopProduction();
37
38 // You should not call this.
39 void WakeUpEvt(int evt);
40
41 bool QueueFilled() const { return m_q_filled; }
42 protected:
43 int m_fd_input, m_fd_output; // ESD fds
44 int m_tag_input, m_tag_output; // GLIB tags
45 bool m_esd_stop; // Stream started ?
46 bool m_esd_ok; // ESD detected
47 wxString m_hostname; // ESD host
48 bool m_q_filled; // queue filled
49
50 private:
51 void DetectBest(wxSoundFormatPcm *pcm);
52 };
53
54 #endif