Initial import from FreeBSD RELENG_4:
[games.git] / usr.sbin / i4b / g711conv / g711conv.1
1 .\"
2 .\" Copyright (c) 1999 Hellmuth Michaelis. All rights reserved.
3 .\"
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
6 .\" are met:
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\"    notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\"    notice, this list of conditions and the following disclaimer in the
11 .\"    documentation and/or other materials provided with the distribution.
12 .\"
13 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
14 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
17 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23 .\" SUCH DAMAGE.
24 .\"
25 .\"     $Id: g711conv.1,v 1.3 1999/12/13 22:11:55 hm Exp $
26 .\"
27 .\" $FreeBSD: src/usr.sbin/i4b/g711conv/g711conv.1,v 1.4.2.6 2002/06/21 16:40:34 charnier Exp $
28 .\"
29 .\"     last edit-date: [Mon Dec 13 22:54:33 1999]
30 .\"
31 .Dd March 15, 1999
32 .Dt G711CONV 1
33 .Os
34 .Sh NAME
35 .Nm g711conv
36 .Nd conversions according to G.711
37 .Sh SYNOPSIS
38 .Nm
39 .Op Fl a
40 .Op Fl u
41 .Op Fl P
42 .Op Fl A
43 .Op Fl R
44 .Sh DESCRIPTION
45 The
46 .Nm
47 utility
48 is part of the isdn4bsd package and is used to convert between the A-Law and
49 u-law formats as specified in ITU G.711. It is based on a freely available
50 and freely usable reference implementation done by Sun Microsystems, Inc.
51 .Pp
52 The following options are available:
53 .Bl -tag -width Ds
54 .It Fl a
55 Convert A-law to u-law
56 .It Fl u
57 Convert u-law to A-law
58 .It Fl r
59 Reverse bits before conversion
60 .It Fl R
61 Reverse bits after conversion
62 .It Fl P
63 Print the resulting conversion tables (as C-source) to stdout instead of
64 doing the actual conversion.
65 .El
66 .Sh STANDARDS
67 A-Law and u-Law conversions are specified in ITU Recommendation G.711.
68 .Pp
69 The reference implementation done by Sun Microsystems, Inc. is available
70 from http://www.itu.int/itudoc/itu-t/rec/g/g700-799/refimpl.txt
71 .Sh EXAMPLES
72 The command:
73 .Bd -literal -offset indent
74 g711conv -P -a
75 .Ed
76 .Pp
77 prints out the A-law to u-law conversion table as C-source to stdout.
78 .Pp
79 The command:
80 .Bd -literal -offset indent
81 cat max_headroom.ul | g711conv -u -R > /dev/i4btel0
82 .Ed
83 .Pp
84 converts the u-law coded voice of Max Headroom to A-law, reverses the
85 bits of the result and moves that to an active isdn4bsd telephone connection.
86 .Sh AUTHORS
87 The
88 .Nm
89 utility and this manpage were written by
90 .An Hellmuth Michaelis Aq hm@kts.org
91 based on the G.711 conversion reference code written by Sun Microsystems,
92 Inc. and code contributed to isdn4bsd by Stefan Bethke.