All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jussi Laako <jussi@sonarnerd.net>
To: Daniel Mack <zonque@gmail.com>
Cc: alsa-devel@alsa-project.org, tiwai@suse.de, clemens@ladisch.de,
	demian@auraliti.com, ray@auraliti.com, andreas@akdesigninc.com
Subject: Re: [PATCH 1/2] ALSA: add DSD formats
Date: Sun, 07 Apr 2013 00:56:40 +0300	[thread overview]
Message-ID: <51609A18.2040905@sonarnerd.net> (raw)
In-Reply-To: <5160629F.50400@gmail.com>

On 04/06/2013 08:59 PM, Daniel Mack wrote:
> On 06.04.2013 19:53, Jussi Laako wrote:
>> On 04/06/2013 02:44 PM, Daniel Mack wrote:
>>> +#define SNDRV_PCM_FMTBIT_DSD_DOP_U8	_SNDRV_PCM_FMTBIT(DSD_DOP_U8)
>>> +#define SNDRV_PCM_FMTBIT_DSD_DOP_U16	_SNDRV_PCM_FMTBIT(DSD_DOP_U16)
>
> Well, the idea was to denote the fact that transport goes in multiple of
> 8 or 16 bits, which can then be interpreted by the calculation of the
> actual sample rate. But I'm fine with anything else. What name would you
> pick, assuming that you're fine with the general approach?

I would just leave out the DOP part and call it SNDRV_PCM_FMTBIT_DSD_U8 
(8 DSD samples per unit) and SDNRV_PCM_FMTBIT_DSD_U16 (16 DSD samples 
per unit). This way it is agnostic to the fact if driver actually 
implements DoP or something else when talking to the actual hardware. It 
assumes all the bits in the unit to be valid DSD samples without any DoP 
marker byte stuff. If driver implements DoP inside, it shouldn't be 
visible outside. If application implements DoP it will anyway pick a 
traditional PCM sample format for the purpose.

It could also  have SNDRV_PCM_FMTBIT_DSD_U32 which is suitable for 
PCI/PCIe and many USB cases. Helps on alignment requirements...

For example SNDRV_PCM_FMTBIT_DSD_U8 and ALSA sample rate of 352800 -> 
DSD sample rate of 2822400. Or SDNRV_PCM_FMTBIT_DSD_U16 and 176400 -> 
DSD sample rate of 2822400.


	- Jussi

  reply	other threads:[~2013-04-06 21:56 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-06 11:44 [PATCH 1/2] ALSA: add DSD formats Daniel Mack
2013-04-06 11:44 ` [PATCH 2/2] ALSA: snd-usb: add quirks handler for DSD streams Daniel Mack
2013-04-06 11:44 ` Daniel Mack
2013-04-06 11:48   ` Daniel Mack
2013-04-06 17:53 ` [PATCH 1/2] ALSA: add DSD formats Jussi Laako
2013-04-06 17:59   ` Daniel Mack
2013-04-06 21:56     ` Jussi Laako [this message]
2013-04-06 23:07 ` Jussi Laako
2013-04-07  7:35 ` Takashi Iwai
  -- strict thread matches above, loose matches on Subject: below --
2013-03-27 23:30 Daniel Mack

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=51609A18.2040905@sonarnerd.net \
    --to=jussi@sonarnerd.net \
    --cc=alsa-devel@alsa-project.org \
    --cc=andreas@akdesigninc.com \
    --cc=clemens@ladisch.de \
    --cc=demian@auraliti.com \
    --cc=ray@auraliti.com \
    --cc=tiwai@suse.de \
    --cc=zonque@gmail.com \
    /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.