summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Sevakis <jethead71@rockbox.org>2007-02-28 17:32:31 +0000
committerMichael Sevakis <jethead71@rockbox.org>2007-02-28 17:32:31 +0000
commitab66955664f8987d064247dc6d585b5618745d29 (patch)
tree18f1b5a0f60b4ae4a207885673a4099a43dbe1b0
parent50b5ee4781a44234b4ea5dccf3be6ae5ec9fd324 (diff)
downloadrockbox-ab66955664f8987d064247dc6d585b5618745d29.tar.gz
rockbox-ab66955664f8987d064247dc6d585b5618745d29.zip
SWCODEC: Patchup the short crossfade glitching reported for FLAC but seemed not limited to FLAC actually. Crossfade doesn't like being hand the larger chunks that the dsp was now able to process when not resampling. The real fix is making it not matter.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12521 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--apps/dsp.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/apps/dsp.c b/apps/dsp.c
index 199e24e170..ca494e553f 100644
--- a/apps/dsp.c
+++ b/apps/dsp.c
@@ -1175,16 +1175,16 @@ int dsp_output_count(int count)
1175 { 1175 {
1176 count = (int)(((unsigned long)count * NATIVE_FREQUENCY 1176 count = (int)(((unsigned long)count * NATIVE_FREQUENCY
1177 + (dsp->frequency - 1)) / dsp->frequency); 1177 + (dsp->frequency - 1)) / dsp->frequency);
1178
1179 /* Now we have the resampled sample count which must not exceed
1180 * RESAMPLE_BUF_COUNT/2 to avoid resample buffer overflow. One
1181 * must call dsp_input_count() to get the correct input sample
1182 * count.
1183 */
1184 if (count > RESAMPLE_BUF_COUNT/2)
1185 count = RESAMPLE_BUF_COUNT/2;
1186 } 1178 }
1187 1179
1180 /* Now we have the resampled sample count which must not exceed
1181 * RESAMPLE_BUF_COUNT/2 to avoid resample buffer overflow. One
1182 * must call dsp_input_count() to get the correct input sample
1183 * count.
1184 */
1185 if (count > RESAMPLE_BUF_COUNT/2)
1186 count = RESAMPLE_BUF_COUNT/2;
1187
1188 return count; 1188 return count;
1189} 1189}
1190 1190