From: Daniel Mack <zonque@gmail.com>
To: alsa-devel@alsa-project.org
Cc: jussi@sonarnerd.net, tiwai@suse.de, clemens@ladisch.de,
Daniel Mack <zonque@gmail.com>,
demian@auraliti.com, ray@auraliti.com, andreas@akdesigninc.com
Subject: [PATCH 2/2] alsa-lib: bring pcm.h and pcm.c in sync with the kernel list
Date: Thu, 28 Mar 2013 00:32:24 +0100 [thread overview]
Message-ID: <1364427144-30036-2-git-send-email-zonque@gmail.com> (raw)
In-Reply-To: <1364427144-30036-1-git-send-email-zonque@gmail.com>
In particular, this adds definitions and descriptions for G.723 and
DSD types.
Signed-off-by: Daniel Mack <zonque@gmail.com>
---
include/pcm.h | 14 +++++++++++++-
src/pcm/pcm.c | 12 ++++++++++++
2 files changed, 25 insertions(+), 1 deletion(-)
diff --git a/include/pcm.h b/include/pcm.h
index 2235678..ec4fb1c 100644
--- a/include/pcm.h
+++ b/include/pcm.h
@@ -199,7 +199,19 @@ typedef enum _snd_pcm_format {
SND_PCM_FORMAT_U18_3LE,
/** Unsigned 18bit Big Endian in 3bytes format */
SND_PCM_FORMAT_U18_3BE,
- SND_PCM_FORMAT_LAST = SND_PCM_FORMAT_U18_3BE,
+ /* G.723 (ADPCM) 24 kbit/s, 8 samples in 3 bytes */
+ SND_PCM_FORMAT_G723_24,
+ /* G.723 (ADPCM) 24 kbit/s, 1 sample in 1 byte */
+ SND_PCM_FORMAT_G723_24_1B,
+ /* G.723 (ADPCM) 40 kbit/s, 8 samples in 3 bytes */
+ SND_PCM_FORMAT_G723_40,
+ /* G.723 (ADPCM) 40 kbit/s, 1 sample in 1 byte */
+ SND_PCM_FORMAT_G723_40_1B,
+ /* Direct Stream Digital (DSD) in 8-bit sample frames */
+ SND_PCM_FORMAT_DSD_U8,
+ /* Direct Stream Digital (DSD) in 16-bit sample frames */
+ SND_PCM_FORMAT_DSD_U16,
+ SND_PCM_FORMAT_LAST = SND_PCM_FORMAT_DSD_U16,
#if __BYTE_ORDER == __LITTLE_ENDIAN
/** Signed 16 bit CPU endian */
diff --git a/src/pcm/pcm.c b/src/pcm/pcm.c
index 2963711..9744060 100644
--- a/src/pcm/pcm.c
+++ b/src/pcm/pcm.c
@@ -1554,6 +1554,12 @@ static const char *const snd_pcm_format_names[] = {
FORMAT(S18_3BE),
FORMAT(U18_3LE),
FORMAT(U18_3BE),
+ FORMAT(G723_24),
+ FORMAT(G723_24_1B),
+ FORMAT(G723_40),
+ FORMAT(G723_40_1B),
+ FORMAT(DSD_U8),
+ FORMAT(DSD_U16),
};
static const char *const snd_pcm_format_aliases[SND_PCM_FORMAT_LAST+1] = {
@@ -1607,6 +1613,12 @@ static const char *const snd_pcm_format_descriptions[] = {
FORMATD(S18_3BE, "Signed 18 bit Big Endian in 3bytes"),
FORMATD(U18_3LE, "Unsigned 18 bit Little Endian in 3bytes"),
FORMATD(U18_3BE, "Unsigned 18 bit Big Endian in 3bytes"),
+ FORMATD(G723_24, "G.723 (ADPCM) 24 kbit/s, 8 samples in 3 bytes"),
+ FORMATD(G723_24_1B, "G.723 (ADPCM) 24 kbit/s, 1 sample in 1 byte"),
+ FORMATD(G723_40, "G.723 (ADPCM) 40 kbit/s, 8 samples in 3 bytes"),
+ FORMATD(G723_40_1B, "G.723 (ADPCM) 40 kbit/s, 1 sample in 1 byte"),
+ FORMATD(DSD_U8, "Direct Stream Digital (DSD), 1 byte per sample"),
+ FORMATD(DSD_U16, "Direct Stream Digital (DSD), 2 bytes per sample"),
};
static const char *const snd_pcm_type_names[] = {
--
1.8.1.4
next prev parent reply other threads:[~2013-03-27 23:32 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-27 23:32 [PATCH 1/2] alsa-lib: pcm.c: fix indentation Daniel Mack
2013-03-27 23:32 ` Daniel Mack [this message]
2013-03-27 23:45 ` [PATCH 2/2] alsa-lib: bring pcm.h and pcm.c in sync with the kernel list Jussi Laako
[not found] ` <7.0.0.16.2.20130327213632.13b07718@akdesigninc.com>
2013-03-28 7:36 ` Jussi Laako
2013-03-28 7:49 ` Jussi Laako
2013-03-28 9:54 ` Daniel Mack
2013-03-28 9:52 ` Daniel Mack
2013-04-05 7:45 ` Daniel Mack
[not found] ` <7.0.0.16.2.20130405092937.144d10d0@akdesigninc.com>
2013-04-05 20:48 ` Jussi Laako
2013-04-05 20:53 ` Jussi Laako
2013-04-06 11:29 ` Daniel Mack
2013-04-06 17:52 ` Jussi Laako
2013-04-06 17:58 ` Daniel Mack
2013-04-06 21:48 ` Jussi Laako
-- strict thread matches above, loose matches on Subject: below --
2013-04-18 8:37 [PATCH 1/2] alsa-lib: pcm.c: fix indentation Daniel Mack
2013-04-18 8:37 ` [PATCH 2/2] alsa-lib: bring pcm.h and pcm.c in sync with the kernel list 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=1364427144-30036-2-git-send-email-zonque@gmail.com \
--to=zonque@gmail.com \
--cc=alsa-devel@alsa-project.org \
--cc=andreas@akdesigninc.com \
--cc=clemens@ladisch.de \
--cc=demian@auraliti.com \
--cc=jussi@sonarnerd.net \
--cc=ray@auraliti.com \
--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.