diff options
Diffstat (limited to 'apps/codecs/dumb/include/aldumb.h')
-rw-r--r-- | apps/codecs/dumb/include/aldumb.h | 93 |
1 files changed, 93 insertions, 0 deletions
diff --git a/apps/codecs/dumb/include/aldumb.h b/apps/codecs/dumb/include/aldumb.h new file mode 100644 index 0000000000..dae2029316 --- /dev/null +++ b/apps/codecs/dumb/include/aldumb.h | |||
@@ -0,0 +1,93 @@ | |||
1 | /* _______ ____ __ ___ ___ | ||
2 | * \ _ \ \ / \ / \ \ / / ' ' ' | ||
3 | * | | \ \ | | || | \/ | . . | ||
4 | * | | | | | | || ||\ /| | | ||
5 | * | | | | | | || || \/ | | ' ' ' | ||
6 | * | | | | | | || || | | . . | ||
7 | * | |_/ / \ \__// || | | | ||
8 | * /_______/ynamic \____/niversal /__\ /____\usic /| . . ibliotheque | ||
9 | * / \ | ||
10 | * / . \ | ||
11 | * aldumb.h - The user header file for DUMB with / / \ \ | ||
12 | * Allegro. | < / \_ | ||
13 | * | \/ /\ / | ||
14 | * Include this file if you wish to use DUMB \_ / > / | ||
15 | * with Allegro. It will include dumb.h for you, | \ / / | ||
16 | * and provide extra functionality such as audio | ' / | ||
17 | * stream and datafile integration. \__/ | ||
18 | */ | ||
19 | |||
20 | #ifndef ALDUMB_H | ||
21 | #define ALDUMB_H | ||
22 | |||
23 | |||
24 | #include <allegro.h> | ||
25 | |||
26 | #include "dumb.h" | ||
27 | |||
28 | |||
29 | #ifdef __cplusplus | ||
30 | extern "C" { | ||
31 | #endif | ||
32 | |||
33 | |||
34 | /* Packfile Support */ | ||
35 | |||
36 | void dumb_register_packfiles(void); | ||
37 | |||
38 | DUMBFILE *dumbfile_open_packfile(PACKFILE *p); | ||
39 | DUMBFILE *dumbfile_from_packfile(PACKFILE *p); | ||
40 | |||
41 | |||
42 | /* Datafile Registration Functions */ | ||
43 | |||
44 | #define DUMB_DAT_DUH DAT_ID('D','U','H',' ') | ||
45 | #define DUMB_DAT_IT DAT_ID('I','T',' ',' ') | ||
46 | #define DUMB_DAT_XM DAT_ID('X','M',' ',' ') | ||
47 | #define DUMB_DAT_S3M DAT_ID('S','3','M',' ') | ||
48 | #define DUMB_DAT_MOD DAT_ID('M','O','D',' ') | ||
49 | |||
50 | void dumb_register_dat_duh(long type); | ||
51 | void dumb_register_dat_it(long type); | ||
52 | void dumb_register_dat_xm(long type); | ||
53 | void dumb_register_dat_s3m(long type); | ||
54 | void dumb_register_dat_mod(long type); | ||
55 | |||
56 | |||
57 | /* DUH Playing Functions */ | ||
58 | |||
59 | typedef struct AL_DUH_PLAYER AL_DUH_PLAYER; | ||
60 | |||
61 | AL_DUH_PLAYER *al_start_duh(DUH *duh, int n_channels, long pos, float volume, long bufsize, int freq); | ||
62 | void al_stop_duh(AL_DUH_PLAYER *dp); | ||
63 | void al_pause_duh(AL_DUH_PLAYER *dp); | ||
64 | void al_resume_duh(AL_DUH_PLAYER *dp); | ||
65 | void al_duh_set_priority(AL_DUH_PLAYER *dp, int priority); | ||
66 | void al_duh_set_volume(AL_DUH_PLAYER *dp, float volume); | ||
67 | int al_poll_duh(AL_DUH_PLAYER *dp); | ||
68 | long al_duh_get_position(AL_DUH_PLAYER *dp); | ||
69 | |||
70 | AL_DUH_PLAYER *al_duh_encapsulate_sigrenderer(DUH_SIGRENDERER *sigrenderer, float volume, long bufsize, int freq); | ||
71 | DUH_SIGRENDERER *al_duh_get_sigrenderer(AL_DUH_PLAYER *dp); | ||
72 | |||
73 | /* IMPORTANT: This function will return NULL if the music has ended. */ | ||
74 | DUH_SIGRENDERER *al_duh_decompose_to_sigrenderer(AL_DUH_PLAYER *dp); | ||
75 | |||
76 | #ifdef DUMB_DECLARE_DEPRECATED | ||
77 | |||
78 | AL_DUH_PLAYER *al_duh_encapsulate_renderer(DUH_SIGRENDERER *dr, float volume, long bufsize, int freq) DUMB_DEPRECATED; | ||
79 | DUH_SIGRENDERER *al_duh_get_renderer(AL_DUH_PLAYER *dp) DUMB_DEPRECATED; | ||
80 | DUH_SIGRENDERER *al_duh_decompose_to_renderer(AL_DUH_PLAYER *dp) DUMB_DEPRECATED; | ||
81 | /* Replace 'renderer' with 'sigrenderer' in each case where you called one of | ||
82 | * these functions. | ||
83 | */ | ||
84 | |||
85 | #endif | ||
86 | |||
87 | |||
88 | #ifdef __cplusplus | ||
89 | } | ||
90 | #endif | ||
91 | |||
92 | |||
93 | #endif /* ALDUMB_H */ | ||