Mercurial > SDL_sound_CoreAudio
comparison SDL_sound_internal.h @ 223:249186e31431
Sound_Rewind() support code.
author | Ryan C. Gordon <icculus@icculus.org> |
---|---|
date | Thu, 17 Jan 2002 20:55:46 +0000 |
parents | 47cc2de2ae36 |
children | ca43129df299 |
comparison
equal
deleted
inserted
replaced
222:d6b24586822a | 223:249186e31431 |
---|---|
153 * SOUND_SAMPLEFLAG_EOF or SOUND_SAMPLEFLAG_ERROR set. The | 153 * SOUND_SAMPLEFLAG_EOF or SOUND_SAMPLEFLAG_ERROR set. The |
154 * SOUND_SAMPLEFLAG_EAGAIN flag is reset before each call to this | 154 * SOUND_SAMPLEFLAG_EAGAIN flag is reset before each call to this |
155 * method. | 155 * method. |
156 */ | 156 */ |
157 Uint32 (*read)(Sound_Sample *sample); | 157 Uint32 (*read)(Sound_Sample *sample); |
158 | |
159 /* | |
160 * Reset the decoding to the beginning of the stream. Nonzero on | |
161 * success, zero on failure. | |
162 * | |
163 * The purpose of this method is to allow for higher efficiency than | |
164 * an application could get by just recreating the sample externally; | |
165 * not only do they not have to reopen the RWops, reallocate buffers, | |
166 * and potentially pass the data through several rejecting decoders, | |
167 * but certain decoders will not have to recreate their existing | |
168 * state (search for metadata, etc) since they already know they | |
169 * have a valid audio stream with a given set of characteristics. | |
170 * | |
171 * The decoder is responsible for calling seek() on the associated | |
172 * SDL_RWops. A failing call to seek() should be the ONLY reason that | |
173 * this method should ever fail! | |
174 */ | |
175 int (*rewind)(Sound_Sample *sample); | |
158 } Sound_DecoderFunctions; | 176 } Sound_DecoderFunctions; |
159 | 177 |
160 | 178 |
161 /* A structure to hold a set of audio conversion filters and buffers */ | 179 /* A structure to hold a set of audio conversion filters and buffers */ |
162 | 180 |