~ubuntu-branches/ubuntu/trusty/sflphone/trusty

« back to all changes in this revision

Viewing changes to daemon/libs/pjproject-2.1.0/pjmedia/include/pjmedia-codec/audio_codecs.h

  • Committer: Package Import Robot
  • Author(s): Mark Purcell
  • Date: 2014-01-28 18:23:36 UTC
  • mfrom: (4.3.4 sid)
  • Revision ID: package-import@ubuntu.com-20140128182336-jrsv0k9u6cawc068
Tags: 1.3.0-1
* New upstream release 
  - Fixes "New Upstream Release" (Closes: #735846)
  - Fixes "Ringtone does not stop" (Closes: #727164)
  - Fixes "[sflphone-kde] crash on startup" (Closes: #718178)
  - Fixes "sflphone GUI crashes when call is hung up" (Closes: #736583)
* Build-Depends: ensure GnuTLS 2.6
  - libucommon-dev (>= 6.0.7-1.1), libccrtp-dev (>= 2.0.6-3)
  - Fixes "FTBFS Build-Depends libgnutls{26,28}-dev" (Closes: #722040)
* Fix "boost 1.49 is going away" unversioned Build-Depends: (Closes: #736746)
* Add Build-Depends: libsndfile-dev, nepomuk-core-dev

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* $Id: audio_codecs.h 3666 2011-07-19 08:40:20Z nanang $ */
 
2
/* 
 
3
 * Copyright (C) 2011-2011 Teluu Inc. (http://www.teluu.com)
 
4
 *
 
5
 * This program is free software; you can redistribute it and/or modify
 
6
 * it under the terms of the GNU General Public License as published by
 
7
 * the Free Software Foundation; either version 2 of the License, or
 
8
 * (at your option) any later version.
 
9
 *
 
10
 * This program is distributed in the hope that it will be useful,
 
11
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
12
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
13
 * GNU General Public License for more details.
 
14
 *
 
15
 * You should have received a copy of the GNU General Public License
 
16
 * along with this program; if not, write to the Free Software
 
17
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA 
 
18
 */
 
19
#ifndef __PJMEDIA_CODEC_ALL_CODECS_H__
 
20
#define __PJMEDIA_CODEC_ALL_CODECS_H__
 
21
 
 
22
/**
 
23
 * @file pjmedia-codec/all_codecs.h
 
24
 * @brief Helper function to register all codecs
 
25
 */
 
26
#include <pjmedia/endpoint.h>
 
27
#include <pjmedia-codec/passthrough.h>
 
28
 
 
29
 
 
30
PJ_BEGIN_DECL
 
31
 
 
32
/**
 
33
 * @defgroup PJMEDIA_CODEC_REGISTER_ALL Codec registration helper
 
34
 * @ingroup PJMEDIA_CODEC_CODECS
 
35
 * @brief Helper function to register all codecs
 
36
 * @{
 
37
 *
 
38
 * Helper function to register all codecs that are implemented in
 
39
 * PJMEDIA-CODEC library.
 
40
 */
 
41
 
 
42
/**
 
43
 * Codec configuration. Call #pjmedia_audio_codec_config_default() to initialize
 
44
 * this structure with the default values.
 
45
 */
 
46
typedef struct pjmedia_audio_codec_config
 
47
{
 
48
    /** Speex codec settings. See #pjmedia_codec_speex_init() for more info */
 
49
    struct {
 
50
        unsigned        option;         /**< Bitmask of options.        */
 
51
        int             quality;        /**< Codec quality.             */
 
52
        int             complexity;     /**< Codec complexity.          */
 
53
    } speex;
 
54
 
 
55
    /** iLBC settings */
 
56
    struct {
 
57
        unsigned        mode;           /**< iLBC mode.                 */
 
58
    } ilbc;
 
59
 
 
60
    /** Passthrough */
 
61
    struct {
 
62
        pjmedia_codec_passthrough_setting setting; /**< Passthrough     */
 
63
    } passthrough;
 
64
 
 
65
} pjmedia_audio_codec_config;
 
66
 
 
67
 
 
68
/**
 
69
 * Initialize pjmedia_audio_codec_config structure with default values.
 
70
 *
 
71
 * @param cfg           The codec config to be initialized.
 
72
 */
 
73
PJ_DECL(void)
 
74
pjmedia_audio_codec_config_default(pjmedia_audio_codec_config *cfg);
 
75
 
 
76
/**
 
77
 * Register all known audio codecs implemented in PJMEDA-CODEC library to the
 
78
 * specified media endpoint.
 
79
 *
 
80
 * @param endpt         The media endpoint.
 
81
 * @param c             Optional codec configuration, or NULL to use default
 
82
 *                      values.
 
83
 *
 
84
 * @return              PJ_SUCCESS on success or the appropriate error code.
 
85
 */
 
86
PJ_DECL(pj_status_t)
 
87
pjmedia_codec_register_audio_codecs(pjmedia_endpt *endpt,
 
88
                                    const pjmedia_audio_codec_config *c);
 
89
 
 
90
 
 
91
/**
 
92
 * @}  PJMEDIA_CODEC_REGISTER_ALL
 
93
 */
 
94
 
 
95
 
 
96
PJ_END_DECL
 
97
 
 
98
#endif  /* __PJMEDIA_CODEC_ALL_CODECS_H__ */