pipe: added music_buffer, rewrite music_pipe

Turn the music_pipe into a simple music_chunk queue.  The music_chunk
allocation code is moved to music_buffer, and is now managed with a
linked list instead of a ring buffer.  Two separate music_pipe objects
are used by the decoder for the "current" and the "next" song, which
greatly simplifies the cross-fading code.
This commit is contained in:
Max Kellermann
2009-03-06 00:42:03 +01:00
parent 000b2d4f3a
commit 01cf7feac7
15 changed files with 433 additions and 417 deletions

View File

@@ -35,6 +35,9 @@ struct audio_format;
* music_pipe_append() caller.
*/
struct music_chunk {
/** the next chunk in a linked list */
struct music_chunk *next;
/** number of bytes stored in this chunk */
uint16_t length;