summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Sevakis <jethead71@rockbox.org>2009-07-23 11:27:09 +0000
committerMichael Sevakis <jethead71@rockbox.org>2009-07-23 11:27:09 +0000
commitc77eae99a36709e887dc9daf9341d6d1260cfa52 (patch)
tree44e135d3a732654906bec4f983f8a2cc57156c53
parentecd4d8870eb0bfd474ca25c28e12da33f701f9e1 (diff)
downloadrockbox-c77eae99a36709e887dc9daf9341d6d1260cfa52.tar.gz
rockbox-c77eae99a36709e887dc9daf9341d6d1260cfa52.zip
Commit FS#10458 by Christopher Williams - Fix incorrect AIFF and WAV encoding while recording in mono.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22014 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--apps/codecs/aiff_enc.c2
-rw-r--r--apps/codecs/wav_enc.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/apps/codecs/aiff_enc.c b/apps/codecs/aiff_enc.c
index 094ea5a006..87358f3df8 100644
--- a/apps/codecs/aiff_enc.c
+++ b/apps/codecs/aiff_enc.c
@@ -262,7 +262,7 @@ static inline void sample_to_mono(uint32_t **src, uint32_t **dst)
262 lr2 >>= 1; 262 lr2 >>= 1;
263 break; 263 break;
264 } 264 }
265 *(*dst)++ = swap_odd_even_be32((lr1 << 16) | (uint16_t)lr2); 265 *(*dst)++ = htobe32((lr1 << 16) | (uint16_t)lr2);
266} /* sample_to_mono */ 266} /* sample_to_mono */
267 267
268STATICIRAM void chunk_to_aiff_format(uint32_t *src, uint32_t *dst) ICODE_ATTR; 268STATICIRAM void chunk_to_aiff_format(uint32_t *src, uint32_t *dst) ICODE_ATTR;
diff --git a/apps/codecs/wav_enc.c b/apps/codecs/wav_enc.c
index 75536d1b1d..38230c846b 100644
--- a/apps/codecs/wav_enc.c
+++ b/apps/codecs/wav_enc.c
@@ -251,7 +251,7 @@ static inline void sample_to_mono(uint32_t **src, uint32_t **dst)
251 lr2 >>= 1; 251 lr2 >>= 1;
252 break; 252 break;
253 } 253 }
254 *(*dst)++ = swap_odd_even_be32((lr1 << 16) | (uint16_t)lr2); 254 *(*dst)++ = htole32((lr2 << 16) | (uint16_t)lr1);
255} /* sample_to_mono */ 255} /* sample_to_mono */
256 256
257STATICIRAM void chunk_to_wav_format(uint32_t *src, uint32_t *dst) ICODE_ATTR; 257STATICIRAM void chunk_to_wav_format(uint32_t *src, uint32_t *dst) ICODE_ATTR;