aboutsummaryrefslogtreecommitdiff
path: root/src/pipe.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-11-02 16:55:43 +0100
committerMax Kellermann <max@duempel.org>2008-11-02 16:55:43 +0100
commit8b1f6ff3c8ed06ef469d29b4a691dc4776a3db82 (patch)
tree1f54932ea014cf5ef97b2c298e2051bbd4fbb22e /src/pipe.c
parent30fca5e5a9c26bf73a24ae5710f8d9d21be49011 (diff)
decoder: replaced music_pipe.audioFormat with dc.out_audio_format
.. and rename dc.audioFormat to dc.in_audio_format. The music pipe does not need to know the audio format, and its former "audioFormat" property indicated the format of the most recently added chunk, which might be confusing when you are reading the oldest chunks.
Diffstat (limited to 'src/pipe.c')
-rw-r--r--src/pipe.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/pipe.c b/src/pipe.c
index db463f7a..9ad9a87d 100644
--- a/src/pipe.c
+++ b/src/pipe.c
@@ -19,6 +19,7 @@
#include "pipe.h"
#include "notify.h"
#include "utils.h"
+#include "audio_format.h"
#include <assert.h>
#include <string.h>
@@ -185,10 +186,11 @@ tail_chunk(float data_time, uint16_t bitRate, size_t frame_size)
}
size_t music_pipe_append(const void *data0, size_t datalen,
+ const struct audio_format *audio_format,
float data_time, uint16_t bitRate)
{
const unsigned char *data = data0;
- const size_t frame_size = audio_format_frame_size(&ob.audioFormat);
+ const size_t frame_size = audio_format_frame_size(audio_format);
size_t ret = 0, dataToSend;
struct music_chunk *chunk = NULL;