Mercurial > SDL_sound_CoreAudio
comparison decoders/aiff.c @ 47:ea58bc3b15d7
Added init() and quit() methods.
author | Ryan C. Gordon <icculus@icculus.org> |
---|---|
date | Sat, 22 Sep 2001 14:41:38 +0000 |
parents | 0d5ff5679523 |
children | b13fafb976be |
comparison
equal
deleted
inserted
replaced
46:6e13fcc178da | 47:ea58bc3b15d7 |
---|---|
55 | 55 |
56 #if (!defined SOUND_SUPPORTS_AIFF) | 56 #if (!defined SOUND_SUPPORTS_AIFF) |
57 #error SOUND_SUPPORTS_AIFF must be defined. | 57 #error SOUND_SUPPORTS_AIFF must be defined. |
58 #endif | 58 #endif |
59 | 59 |
60 | 60 static int AIFF_init(void); |
61 static void AIFF_quit(void); | |
61 static int AIFF_open(Sound_Sample *sample, const char *ext); | 62 static int AIFF_open(Sound_Sample *sample, const char *ext); |
62 static void AIFF_close(Sound_Sample *sample); | 63 static void AIFF_close(Sound_Sample *sample); |
63 static Uint32 AIFF_read(Sound_Sample *sample); | 64 static Uint32 AIFF_read(Sound_Sample *sample); |
64 | 65 |
65 const Sound_DecoderFunctions __Sound_DecoderFunctions_AIFF = | 66 const Sound_DecoderFunctions __Sound_DecoderFunctions_AIFF = |
69 "Audio Interchange File Format", | 70 "Audio Interchange File Format", |
70 "Torbjörn Andersson <d91tan@Update.UU.SE>", | 71 "Torbjörn Andersson <d91tan@Update.UU.SE>", |
71 "http://www.icculus.org/SDL_sound/" | 72 "http://www.icculus.org/SDL_sound/" |
72 }, | 73 }, |
73 | 74 |
74 AIFF_open, /* open() method */ | 75 AIFF_init, /* init() method */ |
75 AIFF_close, /* close() method */ | 76 AIFF_quit, /* quit() method */ |
76 AIFF_read /* read() method */ | 77 AIFF_open, /* open() method */ |
78 AIFF_close, /* close() method */ | |
79 AIFF_read /* read() method */ | |
77 }; | 80 }; |
78 | 81 |
79 | 82 |
80 /* this is what we store in our internal->decoder_private field... */ | 83 /* this is what we store in our internal->decoder_private field... */ |
81 typedef struct { | 84 typedef struct { |
133 pstring compressionName; | 136 pstring compressionName; |
134 #endif | 137 #endif |
135 } comm_t; | 138 } comm_t; |
136 | 139 |
137 | 140 |
141 | |
142 static int AIFF_init(void) | |
143 { | |
144 return(1); /* always succeeds. */ | |
145 } /* AIFF_init */ | |
146 | |
147 | |
148 static void AIFF_quit(void) | |
149 { | |
150 /* it's a no-op. */ | |
151 } /* AIFF_quit */ | |
152 | |
153 | |
138 /* | 154 /* |
139 * Sample rate is encoded as an "80 bit IEEE Standard 754 floating point | 155 * Sample rate is encoded as an "80 bit IEEE Standard 754 floating point |
140 * number (Standard Apple Numeric Environment [SANE] data type Extended)". | 156 * number (Standard Apple Numeric Environment [SANE] data type Extended)". |
141 * Whose bright idea was that? | 157 * Whose bright idea was that? |
142 * | 158 * |