HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
AU_Device.h
Go to the documentation of this file.
1 /*
2  * PROPRIETARY INFORMATION. This software is proprietary to
3  * Side Effects Software Inc., and is not to be reproduced,
4  * transmitted, or disclosed in any way without written permission.
5  *
6  * NAME: AU_Device.h ( Audio Library, C++)
7  *
8  * COMMENTS:
9  */
10 
11 #ifndef __AU_Device__
12 #define __AU_Device__
13 
14 
15 #include "AU_API.h"
16 #if defined(WIN32)
17  #include "AU_NTSystem.h"
18  class AU_API AU_Device : public AU_NTSystem
19 #elif defined(MBSD)
20  class AU_MBSDUtilAudioInfo;
21 
22  class AU_API AU_Device
23 #elif defined(LINUX)
24  class AU_ALSADeviceInfo;
25  class AU_API AU_Device
26 #else
27  #error Unsupported platform
28 #endif
29 {
30 public:
31  AU_Device();
32  ~AU_Device();
33 
34  bool startPlay(int queuesize, int channels, int rate);
35 
36  bool isReadyToPlay();
37  void stopPlay(bool now);
38  void clearPort();
39  void setFillPoint(int size);
40  void writeSamples(short *data, int size);
41  bool passedFillPoint();
42 
43 private:
44 #if defined(WIN32)
45  int myPort;
46  int myFillSize;
47 
48 #elif defined(MBSD)
49  // amount of space needed for the next sample write
50  int myRequestedFreeSpace;
51  // audio info (rate, buffers, etc).
52  AU_MBSDUtilAudioInfo * myInfo;
53 
54 #elif defined(LINUX)
55  AU_ALSADeviceInfo *myInfo;
56 #else
57  #error Unsupported platform
58 #endif
59 };
60 
61 #endif // __AU_Device__
bool passedFillPoint()
void writeSamples(short *data, int size)
bool startPlay(int queuesize, int channels, int rate)
~AU_Device()
GLsizeiptr size
Definition: glcorearb.h:663
bool isReadyToPlay()
#define AU_API
Definition: AU_API.h:10
GLboolean * data
Definition: glcorearb.h:130
void setFillPoint(int size)
void clearPort()
void stopPlay(bool now)