Subversion Repositories Kolibri OS

Rev

Rev 368 | Rev 376 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 368 Rev 374
Line 8... Line 8...
8
 
8
 
Line 9... Line 9...
9
#define SOUND_VERSION  5
9
#define SOUND_VERSION 5
Line 10... Line 10...
10
 
10
 
-
 
11
#define PCM_ALL       0
-
 
12
 
-
 
13
#define PCM_OUT       0x08000000
11
#define PCM_ALL       0
14
#define PCM_RING      0x10000000
12
#define PCM_STATIC    0x80000000
15
#define PCM_STATIC    0x20000000
13
#define PCM_FILTER    0x40000000
16
#define PCM_FLOAT     0x40000000
Line 14... Line 17...
14
#define PCM_FLOAT     0x20000000
17
#define PCM_FILTER    0x80000000
15
 
18
 
16
#define PCM_2_16_48   1
19
#define PCM_2_16_48   1
17
#define PCM_1_16_48   2
20
#define PCM_1_16_48   2
Line 53... Line 56...
53
#define SRV_GETVERSION      0
56
#define SRV_GETVERSION      0
54
#define SND_CREATE_BUFF     1
57
#define SND_CREATE_BUFF     1
55
#define SND_DESTROY_BUFF    2
58
#define SND_DESTROY_BUFF    2
56
#define SND_SETFORMAT       3
59
#define SND_SETFORMAT       3
57
#define SND_RESET           4
60
#define SND_GETFORMAT       4 
58
#define SND_SETPOS          5
61
#define SND_RESET           5
59
#define SND_SETBUFF         6
62
#define SND_SETPOS          6
60
#define SND_SETVOLUME       7
63
#define SND_GETPOS          7
61
#define SND_GETVOLUME       8
64
#define SND_SETBUFF         8
62
#define SND_OUT             9
65
#define SND_OUT             9
63
#define SND_PLAY            10
66
#define SND_PLAY           10
64
#define SND_STOP            11
67
#define SND_STOP           11
-
 
68
#define SND_SETVOLUME      12
-
 
69
#define SND_GETVOLUME      13
-
 
70
#define SND_SETPAN         14
-
 
71
#define SND_GETPAN         15
-
 
72
#define SND_GETBUFFSIZE    16
-
 
73
 
-
 
74
#define PLAY_SYNC     0x80000000
Line 65... Line 75...
65
 
75
 
Line 66... Line 76...
66
typedef unsigned int SNDBUF;
76
typedef unsigned int SNDBUF;
-
 
77
 
67
 
78
int _stdcall  InitSound();
68
int _stdcall  InitSound();
79
 
69
SNDBUF _stdcall  CreateBuffer(unsigned int format,int size);
-
 
70
int _stdcall  DestroyBuffer(SNDBUF hBuff);
-
 
-
 
80
SNDBUF _stdcall  CreateBuffer(unsigned int format,int size);
71
int _stdcall  SetBuffer(SNDBUF hBuff,void* buff,
81
int _stdcall  DestroyBuffer(SNDBUF hBuff);
-
 
82
 
-
 
83
int _stdcall  SetFormat(SNDBUF hBuff, unsigned int format);                        
72
                        int offs, int size);
84
int _stdcall  GetFormat(SNDBUF hBuff);                        
73
int _stdcall  SetFormat(SNDBUF hBuff, unsigned int format);                        
85
 
74
int _stdcall  ResetBuffer(SNDBUF hBuff, unsigned int flags);
86
int _stdcall  ResetBuffer(SNDBUF hBuff, unsigned int flags);
75
int _stdcall  SetBufferPos(SNDBUF hBuff, int offset);
-
 
76
int _stdcall  SetVolume(SNDBUF hBuff, int left, int right);
87
int _stdcall  SetBufferPos(SNDBUF hBuff, int offset);
Line -... Line 88...
-
 
88
int _stdcall  GetBufferPos(SNDBUF hBuff);
-
 
89
int _stdcall  GetBufferSize(SNDBUF hBuff);
77
int _stdcall  GetVolume(SNDBUF hBuff, int *left, int *right);
90
 
78
int _stdcall  SetPan(SNDBUF hBuff, int pan);
-
 
79
                        
91
int _stdcall  SetBuffer(SNDBUF hBuff,void* buff,
80
int _stdcall  WaveOut(SNDBUF hBuff,void *buff, int size);
92
                        int offs, int size);
Line 81... Line -...
81
                               
-
 
82
int _stdcall  PlayBuffer(SNDBUF hBuff);
93
int _stdcall  WaveOut(SNDBUF hBuff,void *buff, int size);
83
int _stdcall  StopBuffer(SNDBUF hBuff);
94
int _stdcall  PlayBuffer(SNDBUF hBuff,unsigned int flags);
84
 
95
int _stdcall  StopBuffer(SNDBUF hBuff);
85
typedef struct
-
 
86
{  unsigned int       riff_id;
96
                        
87
   unsigned int       riff_size;
-
 
88
   unsigned int       riff_format;
97
int _stdcall  SetVolume(SNDBUF hBuff, int left, int right);
89
 
98
int _stdcall  GetVolume(SNDBUF hBuff, int *left, int *right);
90
   unsigned int       fmt_id;
-
 
91
   unsigned int       fmt_size;
-
 
92
 
-
 
93
   unsigned short int wFormatTag;
-
 
94
   unsigned short int nChannels;
99
int _stdcall  SetPan(SNDBUF hBuff, int pan);
95
   unsigned int       nSamplesPerSec;
-
 
96
   unsigned int       nAvgBytesPerSec;
-
 
97
   unsigned short int nBlockAlign;
-
 
Line 98... Line 100...
98
   unsigned short int wBitsPerSample;
100
int _stdcall  GetPan(SNDBUF hBuff);
Line 99... Line 101...
99
   unsigned int       data_id;
101
                        
100
   unsigned int       data_size;
102
int _stdcall  GetMasterVol(int* vol);