summaryrefslogtreecommitdiffstats
path: root/Modules/linuxaudiodev.c
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2000-10-08 19:47:47 (GMT)
committerGuido van Rossum <guido@python.org>2000-10-08 19:47:47 (GMT)
commit59316671e3748a03c1fe468f15cfcb66872827ac (patch)
treec42d0e57ea6d5b46aa635da8e1d131cc74ffd9b3 /Modules/linuxaudiodev.c
parentce6292ebf51e5a647585ef85fe7163dc1d841751 (diff)
downloadcpython-59316671e3748a03c1fe468f15cfcb66872827ac.zip
cpython-59316671e3748a03c1fe468f15cfcb66872827ac.tar.gz
cpython-59316671e3748a03c1fe468f15cfcb66872827ac.tar.bz2
Be consistent in the description of audio formats: <format> <width>
"audio". Also add AFMT_S16_NE ("native-endian"). (Somehow there's no AFMT_U16_NE.)
Diffstat (limited to 'Modules/linuxaudiodev.c')
-rw-r--r--Modules/linuxaudiodev.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/Modules/linuxaudiodev.c b/Modules/linuxaudiodev.c
index 0661fb7..120c0bf 100644
--- a/Modules/linuxaudiodev.c
+++ b/Modules/linuxaudiodev.c
@@ -67,10 +67,11 @@ static struct {
{ 8, AFMT_A_LAW, "Logarithmic A-law audio" },
{ 8, AFMT_U8, "Standard unsigned 8-bit audio" },
{ 8, AFMT_S8, "Standard signed 8-bit audio" },
- { 16, AFMT_U16_BE, "Big-endian 16-bit unsigned format" },
- { 16, AFMT_U16_LE, "Little-endian 16-bit unsigned format" },
- { 16, AFMT_S16_BE, "Big-endian 16-bit signed format" },
- { 16, AFMT_S16_LE, "Little-endian 16-bit signed format" },
+ { 16, AFMT_U16_BE, "Big-endian 16-bit unsigned audio" },
+ { 16, AFMT_U16_LE, "Little-endian 16-bit unsigned audio" },
+ { 16, AFMT_S16_BE, "Big-endian 16-bit signed audio" },
+ { 16, AFMT_S16_LE, "Little-endian 16-bit signed audio" },
+ { 16, AFMT_S16_NE, "Native-endian 16-bit signed audio" },
};
static int n_audio_types = sizeof(audio_types) / sizeof(audio_types[0]);
@@ -485,6 +486,8 @@ initlinuxaudiodev(void)
return;
if (PyModule_AddIntConstant(m, "AFMT_S16_LE", (long)AFMT_S16_LE) == -1)
return;
+ if (PyModule_AddIntConstant(m, "AFMT_S16_NE", (long)AFMT_S16_NE) == -1)
+ return;
return;
}