From 01cf7feac7bef8b28605b98ef1e7438a995fc554 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Fri, 6 Mar 2009 00:42:03 +0100 Subject: 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. --- src/chunk.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/chunk.h') diff --git a/src/chunk.h b/src/chunk.h index 58ed7be6f..b63466102 100644 --- a/src/chunk.h +++ b/src/chunk.h @@ -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; -- cgit v1.2.3