Subversion Repositories Kolibri OS

Rev

Rev 285 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
168 serge 1
;
2
;   This file is part of the Infinity sound AC97 driver.
3
;   (C) copyright Serge 2006
4
;   email: infinity_sound@mail.ru
5
;
6
;   This program is free software; you can redistribute it and/or modify
7
;   it under the terms of the GNU General Public License as published by
8
;   the Free Software Foundation; either version 2 of the License, or
9
;   (at your option) any later version.
10
;
11
;   This program is distributed in the hope that it will be useful,
12
;   but WITHOUT ANY WARRANTY; without even the implied warranty of
13
;   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14
;   GNU General Public License for more details.
15
 
16
PCM_2_16_48    equ   1
17
PCM_1_16_48    equ   2
18
 
19
PCM_2_16_44    equ   3
20
PCM_1_16_44    equ   4
21
 
22
PCM_2_16_32    equ   5
23
PCM_1_16_32    equ   6
24
 
25
PCM_2_16_24    equ   7
26
PCM_1_16_24    equ   8
27
 
28
PCM_2_16_22    equ   9
29
PCM_1_16_22    equ  10
30
 
31
PCM_2_16_16    equ  11
32
PCM_1_16_16    equ  12
33
 
34
PCM_2_16_12    equ  13
35
PCM_1_16_12    equ  14
36
 
37
PCM_2_16_11    equ  15
38
PCM_1_16_11    equ  16
39
 
40
PCM_2_8_48     equ  17
41
PCM_1_8_48     equ  18
42
 
43
PCM_2_8_44     equ  19
44
PCM_1_8_44     equ  20
45
 
46
PCM_2_8_32     equ  21
47
PCM_1_8_32     equ  22
48
 
49
PCM_2_8_24     equ  23
50
PCM_1_8_24     equ  24
51
 
52
PCM_2_8_22     equ  25
53
PCM_1_8_22     equ  26
54
 
55
PCM_2_8_16     equ  27
56
PCM_1_8_16     equ  28
57
 
58
PCM_2_8_12     equ  29
59
PCM_1_8_12     equ  30
60
 
61
PCM_2_8_11     equ  31
62
PCM_1_8_11     equ  32
63
 
64
SND_PLAY       equ   1
65
SND_STOP       equ   2
66
 
67
;  struc SND_DEV
68
;{ .magic          dd 0
69
;  .size           dd 0
70
;  .count          dd 0
71
;                  dd 0
72
;  .snd_buff       dd 16 dup (0)
73
;}
74
 
75
;virtual at 0
76
; SND_DEV SND_DEV
77
;end virtual
78
 
79
;SND_DEV_SIZE     equ 80
80
 
81
 
82
struc STREAM
291 serge 83
{
84
    .magic         dd ?   ;'WAVE'
85
    .destroy       dd ?   ;internal destructor
86
    .fd            dd ?   ;next object in list
87
    .bk            dd ?   ;prev object in list
88
    .pid           dd ?   ;owner id
168 serge 89
 
291 serge 90
    .size          dd ?
91
    .str_fd        dd ?
92
    .str_bk        dd ?
93
    .device        dd ?
94
    .format        dd ?
95
    .flags         dd ?
168 serge 96
 
291 serge 97
    .work_buff     dd ?
98
    .work_read     dd ?
99
    .work_write    dd ?
100
    .work_count    dd ?
101
    .work_top      dd ?
102
    .r_size        dd ?
103
    .r_end         dd ?
104
    .r_dt          dd ?
105
    .r_silence     dd ?
281 serge 106
 
291 serge 107
    .base          dd ?
108
    .limit         dd ?
109
    .seg_0         dd ?
110
    .lim_0         dd ?
111
    .seg_1         dd ?
112
    .lim_1         dd ?
113
    .curr_seg      dd ?
114
 
115
    .buff_size     dd ?
116
    .notify_off1   dd ?
117
    .notify_off2   dd ?
118
;    .notify_task   dd ?
119
    .resample      dd ?
168 serge 120
}
121
 
291 serge 122
STREAM_SIZE    equ 31*4
123
FD_OFFSET      equ 24
168 serge 124
 
125
virtual at 0
126
 STREAM STREAM
127
end virtual
128
 
129
struc WAVE_HEADER
130
{   .riff_id        dd  ?
131
    .riff_size      dd  ?
132
    .riff_format    dd  ?
133
 
134
    .fmt_id         dd  ?
135
    .fmt_size       dd  ?
136
    .format_tag     dw  ?
137
    .channels       dw  ?
138
    .freq           dd  ?
139
    .bytes_sec      dd  ?
140
    .block_align    dw  ?
141
    .bits_sample    dw  ?
142
 
143
    .data_id        dd  ?
144
    .data_size      dd  ?
145
}
146