From: Jussi Laako <jussi@sonarnerd.net>
To: Jurgen Kramer <gtmkramer@xs4all.nl>, Takashi Iwai <tiwai@suse.de>
Cc: alsa-devel@alsa-project.org
Subject: Re: [PATCH] pcm: add new 32-bit DSD sample format
Date: Thu, 20 Nov 2014 21:07:06 +0200 [thread overview]
Message-ID: <546E3BDA.2040601@sonarnerd.net> (raw)
In-Reply-To: <1416501288.2996.1.camel@xs4all.nl>
On 20.11.2014 18:34, Jurgen Kramer wrote:
> DSD is a bit odd wrt LE/BE. Both formats are allowed and used.
> The device (XMOS based/Marantz+Denon) want the following order of
> samples:
> L1 L2 L3 L4 R1 R2 R3 R4. Where Lx/Rx are 8-bit DSD samples, L1-L4 are
> packed to 1 32-bit sample.
What you described is precisely interleaved big endian U32 sample
format. L1 is the MSB byte and L4 is the LSB byte of big-endian U32.
So "L1 L2 L3 L4" is equal to DSD_U32_BE. The currently advertised
DSD_U32_LE would be "L4 L3 L2 L1".
> I do think real BE will not work.
Why? Your description precisely matches U32_BE. And seems to work
correctly for me...
Constructing the U32 by having oldest bit in MSB and newest bit in LSB
and sending it out as little-endian results in incorrect output. Adding
byteswap to big-endian format results in correct output (either using
__builtin_byteswap32() or htonl()).
- Jussi
next prev parent reply other threads:[~2014-11-20 19:07 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-10 7:00 [PATCH] pcm: add new 32-bit DSD sample format Jurgen Kramer
2014-11-19 19:50 ` Jussi Laako
2014-11-20 9:58 ` Takashi Iwai
2014-11-20 16:34 ` Jurgen Kramer
2014-11-20 19:07 ` Jussi Laako [this message]
2014-11-21 9:11 ` Jussi Laako
2014-11-21 9:54 ` Takashi Iwai
2014-11-20 18:59 ` Jussi Laako
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=546E3BDA.2040601@sonarnerd.net \
--to=jussi@sonarnerd.net \
--cc=alsa-devel@alsa-project.org \
--cc=gtmkramer@xs4all.nl \
--cc=tiwai@suse.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.