Subversion Repositories Kolibri OS

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
165 serge 1
//
2
//   This file is part of the AC97 mp3 player.
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
 
17
#define PCM_2_16_48   1
18
#define PCM_1_16_48   2
19
#define PCM_2_16_44   3
20
#define PCM_1_16_44   4
21
#define PCM_2_16_32   5
22
#define PCM_1_16_32   6
23
#define PCM_2_16_24   7
24
#define PCM_1_16_24   8
25
#define PCM_2_16_22   9
26
#define PCM_1_16_22  10
27
#define PCM_2_16_16  11
28
#define PCM_1_16_16  12
29
#define PCM_2_16_12  13
30
#define PCM_1_16_12  14
31
#define PCM_2_16_11  15
32
#define PCM_1_16_11  16
33
#define PCM_2_16_8   17
34
#define PCM_1_16_8   18
35
#define PCM_2_8_48   19
36
#define PCM_1_8_48   20
37
#define PCM_2_8_44   21
38
#define PCM_1_8_44   22
39
#define PCM_2_8_32   23
40
#define PCM_1_8_32   24
41
#define PCM_2_8_24   25
42
#define PCM_1_8_24   26
43
#define PCM_2_8_22   27
44
#define PCM_1_8_22   28
45
#define PCM_2_8_16   29
46
#define PCM_1_8_16   30
47
#define PCM_2_8_12   31
48
#define PCM_1_8_12   32
49
#define PCM_2_8_11   33
50
#define PCM_1_8_11   34
51
#define PCM_2_8_8    35
52
#define PCM_1_8_8    36
53
 
54
#define ST_DONE 0x0
55
#define ST_PLAY 0x1
56
#define ST_EXIT 0x2
57
#define ST_STOP 0x4
58
 
59
typedef struct
60
{  DWORD riff_id;
61
    DWORD riff_size;
62
    DWORD riff_format;
63
 
64
    DWORD fmt_id;
65
    DWORD fmt_size;
66
 
67
    WORD  wFormatTag;
68
    WORD  nChannels;
69
    DWORD nSamplesPerSec;
70
    DWORD nAvgBytesPerSec;
71
    WORD  nBlockAlign;
72
    WORD  wBitsPerSample;
73
    DWORD data_id;
74
    DWORD data_size;
75
} WAVEHEADER;
76
 
77
DWORD test_wav(WAVEHEADER *hdr);
78
DWORD test_mp3(char *buf);
79
 
80
//void (*snd_play)();
81
void wave_out(char* buff);
82
 
83
void play_wave();
84
void play_mp3();
85
 
86
void snd_stop();