From 74910df0f367143e73e460524b31bacead953b16 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Sat, 12 Apr 2008 04:13:24 +0000 Subject: added struct OutputBufferChunk To make access to OutputBuffer easier, move everything which belongs to a chunk into its own structure, namely OutputBufferChunk. git-svn-id: https://svn.musicpd.org/mpd/trunk@7269 09075e82-0dd4-0310-85a5-a0d7c8717e4f --- src/playerData.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/playerData.c') diff --git a/src/playerData.c b/src/playerData.c index 718b28771..f9cc314a9 100644 --- a/src/playerData.c +++ b/src/playerData.c @@ -74,7 +74,7 @@ void initPlayerData(void) buffered_before_play = buffered_chunks; } - allocationSize = buffered_chunks * CHUNK_SIZE; /*actual buffer */ + allocationSize = buffered_chunks * sizeof(OutputBufferChunk); /*actual buffer */ allocationSize += buffered_chunks * sizeof(float); /*for times */ allocationSize += buffered_chunks * sizeof(mpd_sint16); /*for chunkSize */ allocationSize += buffered_chunks * sizeof(mpd_sint16); /*for bitRate */ @@ -94,7 +94,7 @@ void initPlayerData(void) allocationSize - device_array_size; initOutputBuffer(&(playerData_pd->buffer), - ((char *)playerData_pd) + sizeof(PlayerData)); + (OutputBufferChunk*)(((char *)playerData_pd) + sizeof(PlayerData))); playerData_pd->playerControl.stop = 0; playerData_pd->playerControl.pause = 0; -- cgit v1.2.3