1AFINITBYTEORDER(3)                                          AFINITBYTEORDER(3)
2
3
4

NAME

6       afInitCompression - initialize compression for a track in an audio file
7       setup
8

SYNOPSIS

10       #include <audiofile.h>
11
12       void afInitCompression(AFfilesetup setup, int track, int compression);
13

PARAMETERS

15       setup is a valid file setup returned by afNewFileSetup(3).
16
17       track specifies a track within the audio file setup. track is always
18       AF_DEFAULT_TRACK for all currently supported file formats.
19
20       compression is an identifier specifying the compression type (such as
21       AF_COMPRESSION_G711_ULAW) to be used for audio data in the track.
22

DESCRIPTION

24       Given an AFfilesetup structure created with afNewFileSetup(3) and a
25       track identified by track (AF_DEFAULT_TRACK for all currently supported
26       file formats), afInitCompression initializes the track to the specified
27       compression.
28
29       The following compression types are currently supported:
30
31       AF_COMPRESSION_NONE
32           no compression
33
34       AF_COMPRESSION_G711_ULAW
35           CCITT G.711 mu-law encoding
36
37       AF_COMPRESSION_G711_ALAW
38           CCITT G.711 A-law encoding
39
40       AF_COMPRESSION_IMA
41           IMA ADPCM encoding
42
43       AF_COMPRESSION_MS_ADPCM
44           MS ADPCM encoding
45
46       AF_COMPRESSION_FLAC
47           FLAC
48
49       AF_COMPRESSION_ALAC
50           Apple Lossless Audio Codec
51

ERRORS

53       afInitCompression can produce the following errors:
54
55       AF_BAD_FILESETUP
56
57           setup represents an invalid file setup.
58
59       AF_BAD_TRACKID
60
61           track represents an invalid track identifier.
62
63       AF_BAD_COMPTYPE
64
65           compression represents an invalid compression type.
66

SEE ALSO

68       afNewFileSetup(3), afInitSampleFormat(3)
69

AUTHOR

71       Michael Pruett <michael@68k.org>
72
73
74
75Audio File Library 0.3.6          03/06/2013                AFINITBYTEORDER(3)
Impressum