Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
c2bac874
Kaydet (Commit)
c2bac874
authored
Eki 06, 2000
tarafından
Fred Drake
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Include more information from the docstrings.
üst
3a844a28
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
49 additions
and
7 deletions
+49
-7
libsunau.tex
Doc/lib/libsunau.tex
+49
-7
No files found.
Doc/lib/libsunau.tex
Dosyayı görüntüle @
c2bac874
...
...
@@ -5,9 +5,28 @@
\sectionauthor
{
Moshe Zadka
}{
mzadka@geocities.com
}
\modulesynopsis
{
Provide an interface to the Sun AU sound format.
}
The
\module
{
sunau
}
module provides a convenient interface to the Sun AU sound
format. Note that this module is interface-compatible with the modules
\refmodule
{
aifc
}
and
\refmodule
{
wave
}
.
The
\module
{
sunau
}
module provides a convenient interface to the Sun
AU sound format. Note that this module is interface-compatible with
the modules
\refmodule
{
aifc
}
and
\refmodule
{
wave
}
.
An audio file consists of a header followed by the data. The fields
of the header are:
\begin{tableii}
{
l|l
}{
textrm
}{
Field
}{
Contents
}
\lineii
{
magic word
}{
The four bytes
\samp
{
.snd
}
.
}
\lineii
{
header size
}{
Size of the header, including info, in bytes.
}
\lineii
{
data size
}{
Physical size of the data, in bytes.
}
\lineii
{
encoding
}{
Indicates how the audio samples are encoded.
}
\lineii
{
sample rate
}{
The sampling rate.
}
\lineii
{
\#
of channels
}{
The number of channels in the samples.
}
\lineii
{
info
}{
\ASCII
{}
string giving a description of the audio
file (padded with null bytes).
}
\end{tableii}
Apart from the info field, all header fields are 4 bytes in size.
They are all 32-bit unsigned integers encoded in big-endian byte
order.
The
\module
{
sunau
}
module defines the following functions:
...
...
@@ -36,10 +55,31 @@ An error raised when something is impossible because of Sun AU specs or
implementation deficiency.
\end{excdesc}
The
\module
{
sunau
}
module defines the following data item:
The
\module
{
sunau
}
module defines the following data item
s
:
\begin{datadesc}
{
AUDIO
_
FILE
_
MAGIC
}
An integer every valid Sun AU file begins with a big-endian encoding of.
An integer every valid Sun AU file begins with, stored in big-endian
form. This is the string
\samp
{
.snd
}
interpreted as an integer.
\end{datadesc}
\begin{datadesc}
{
AUDIO
_
FILE
_
ENCODING
_
MULAW
_
8
}
\dataline
{
AUDIO
_
FILE
_
ENCODING
_
LINEAR
_
8
}
\dataline
{
AUDIO
_
FILE
_
ENCODING
_
LINEAR
_
16
}
\dataline
{
AUDIO
_
FILE
_
ENCODING
_
LINEAR
_
24
}
\dataline
{
AUDIO
_
FILE
_
ENCODING
_
LINEAR
_
32
}
\dataline
{
AUDIO
_
FILE
_
ENCODING
_
ALAW
_
8
}
Values of the encoding field from the AU header which are supported by
this module.
\end{datadesc}
\begin{datadesc}
{
AUDIO
_
FILE
_
ENCODING
_
FLOAT
}
\dataline
{
AUDIO
_
FILE
_
ENCODING
_
DOUBLE
}
\dataline
{
AUDIO
_
FILE
_
ENCODING
_
ADPCM
_
G721
}
\dataline
{
AUDIO
_
FILE
_
ENCODING
_
ADPCM
_
G722
}
\dataline
{
AUDIO
_
FILE
_
ENCODING
_
ADPCM
_
G723
_
3
}
\dataline
{
AUDIO
_
FILE
_
ENCODING
_
ADPCM
_
G723
_
5
}
Additional known values of the encoding field from the AU header, but
which are not supported by this module.
\end{datadesc}
...
...
@@ -98,11 +138,13 @@ The following two methods define a term ``position'' which is compatible
between them, and is otherwise implementation dependent.
\begin{methoddesc}
[AU
_
read]
{
setpos
}{
pos
}
Set the file pointer to the specified position.
Set the file pointer to the specified position. Only values returned
from
\method
{
tell()
}
should be used for
\var
{
pos
}
.
\end{methoddesc}
\begin{methoddesc}
[AU
_
read]
{
tell
}{}
Return current file pointer position.
Return current file pointer position. Note that the returned value
has nothing to do with the actual position in the file.
\end{methoddesc}
The following two functions are defined for compatibility with the
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment