Reverting to the full lsr API. Turns out the simple API needs all of the

audio at once, so it won't work for us.  The old full API code was still
heavily broken, as each call to pcm_convertSampleRate() used the same
state, even if it was processing two streams of audio.  The new code keeps
a separate state for each audio stream that's being converted.

git-svn-id: https://svn.musicpd.org/mpd/trunk@6255 09075e82-0dd4-0310-85a5-a0d7c8717e4f
This commit is contained in:
J. Alexander Treuman
2007-05-24 21:15:37 +00:00
parent 7ba357a04e
commit 2814b7cfc6
7 changed files with 85 additions and 36 deletions

View File

@@ -116,6 +116,7 @@ void initPlayerData(void)
allocationSize - device_array_size;
buffer = &(playerData_pd->buffer);
memset(&buffer->convState, 0, sizeof(ConvState));
buffer->chunks = ((char *)playerData_pd) + sizeof(PlayerData);
buffer->chunkSize = (mpd_uint16 *) (((char *)buffer->chunks) +
buffered_chunks * CHUNK_SIZE);