summaryrefslogtreecommitdiffstats
path: root/audio/pcm_bluetooth.c
diff options
context:
space:
mode:
authorLuiz Augusto von Dentz <luiz.dentz@openbossa.org>2007-08-21 21:32:09 +0000
committerLuiz Augusto von Dentz <luiz.dentz@openbossa.org>2007-08-21 21:32:09 +0000
commitb1618922db92f9bc65b0841f66eb71742bc1b553 (patch)
tree401dbbda10d88248b2dfd3c9961363f7f6b121d4 /audio/pcm_bluetooth.c
parent38c5be0cc3029bf78445be15470d18343a5b4dae (diff)
Add swap member to sbc struct and fix pcm plugin to not swap the buffer.
Diffstat (limited to 'audio/pcm_bluetooth.c')
-rw-r--r--audio/pcm_bluetooth.c13
1 files changed, 1 insertions, 12 deletions
diff --git a/audio/pcm_bluetooth.c b/audio/pcm_bluetooth.c
index 80afd562..495f1521 100644
--- a/audio/pcm_bluetooth.c
+++ b/audio/pcm_bluetooth.c
@@ -109,16 +109,6 @@ struct bluetooth_data {
struct bluetooth_a2dp a2dp; /* A2DP data */
};
-static void memcpy_changeendian(void *dst, const void *src, int size)
-{
- int i;
- const uint16_t *ptrsrc = src;
- uint16_t *ptrdst = dst;
-
- for (i = 0; i < size / 2; i++)
- *ptrdst++ = htons(*ptrsrc++);
-}
-
static int bluetooth_start(snd_pcm_ioplug_t *io)
{
DBG("bluetooth_start %p", io);
@@ -622,8 +612,7 @@ static snd_pcm_sframes_t bluetooth_a2dp_write(snd_pcm_ioplug_t *io,
/* Ready for more data */
buff = (uint8_t *) areas->addr +
(areas->first + areas->step * offset) / 8;
- memcpy_changeendian(data->buffer + data->count, buff,
- frame_size * frames_to_read);
+ memcpy(data->buffer + data->count, buff, frame_size * frames_to_read);
/* Remember we have some frames in the pipe now */
data->count += frames_to_read * frame_size;