change the required dependency for codec_dahdi to only be satisfied by DAHDI and...
[asterisk-bristuff.git] / include / asterisk / ulaw.h
blobd9ab0d17878fa8a511eb504dd9c3d17d41d307bc
1 /*
2 * Asterisk -- An open source telephony toolkit.
4 * Copyright (C) 1999 - 2005, Digium, Inc.
6 * Mark Spencer <markster@digium.com>
8 * See http://www.asterisk.org for more information about
9 * the Asterisk project. Please do not directly contact
10 * any of the maintainers of this project for assistance;
11 * the project provides a web site, mailing lists and IRC
12 * channels for your use.
14 * This program is free software, distributed under the terms of
15 * the GNU General Public License Version 2. See the LICENSE file
16 * at the top of the source tree.
19 /*! \file
20 * \brief u-Law to Signed linear conversion
23 #ifndef _ASTERISK_ULAW_H
24 #define _ASTERISK_ULAW_H
26 /*! Init the ulaw conversion stuff */
27 /*!
28 * To init the ulaw to slinear conversion stuff, this needs to be run.
30 void ast_ulaw_init(void);
32 /*! converts signed linear to mulaw */
33 /*!
35 extern unsigned char __ast_lin2mu[16384];
37 /*! help */
38 extern short __ast_mulaw[256];
40 #define AST_LIN2MU(a) (__ast_lin2mu[((unsigned short)(a)) >> 2])
41 #define AST_MULAW(a) (__ast_mulaw[(a)])
43 #endif /* _ASTERISK_ULAW_H */