FFmpeg
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Functions | Variables
libilbc.c File Reference
#include <ilbc.h>
#include "libavutil/channel_layout.h"
#include "libavutil/common.h"
#include "libavutil/opt.h"
#include "avcodec.h"
#include "internal.h"

Go to the source code of this file.

Data Structures

struct  ILBCDecContext
 
struct  ILBCEncContext
 

Functions

static int get_mode (AVCodecContext *avctx)
 
static av_cold int ilbc_decode_init (AVCodecContext *avctx)
 
static int ilbc_decode_frame (AVCodecContext *avctx, void *data, int *got_frame_ptr, AVPacket *avpkt)
 
static av_cold int ilbc_encode_init (AVCodecContext *avctx)
 
static int ilbc_encode_frame (AVCodecContext *avctx, AVPacket *avpkt, const AVFrame *frame, int *got_packet_ptr)
 

Variables

static const AVOption ilbc_dec_options []
 
static const AVClass ilbc_dec_class
 
AVCodec ff_libilbc_decoder
 
static const AVOption ilbc_enc_options []
 
static const AVClass ilbc_enc_class
 
static const AVCodecDefault ilbc_encode_defaults []
 
AVCodec ff_libilbc_encoder
 

Function Documentation

static int get_mode ( AVCodecContext avctx)
static

Definition at line 30 of file libilbc.c.

Referenced by ilbc_decode_init(), and ilbc_encode_init().

static av_cold int ilbc_decode_init ( AVCodecContext avctx)
static

Definition at line 60 of file libilbc.c.

static int ilbc_decode_frame ( AVCodecContext avctx,
void data,
int *  got_frame_ptr,
AVPacket avpkt 
)
static

Definition at line 80 of file libilbc.c.

static av_cold int ilbc_encode_init ( AVCodecContext avctx)
static

Definition at line 136 of file libilbc.c.

static int ilbc_encode_frame ( AVCodecContext avctx,
AVPacket avpkt,
const AVFrame frame,
int *  got_packet_ptr 
)
static

Definition at line 163 of file libilbc.c.

Variable Documentation

const AVOption ilbc_dec_options[]
static
Initial value:
= {
{ "enhance", "Enhance the decoded audio (adds delay)", 0x42, AV_OPT_TYPE_INT, { .i64 = 0 }, 0, 1, AV_OPT_FLAG_AUDIO_PARAM | AV_OPT_FLAG_DECODING_PARAM },
{ NULL }
}
#define NULL
Definition: coverity.c:32
#define AV_OPT_FLAG_AUDIO_PARAM
Definition: opt.h:280
#define AV_OPT_FLAG_DECODING_PARAM
a generic parameter which can be set by the user for demuxing or decoding
Definition: opt.h:276

Definition at line 48 of file libilbc.c.

const AVClass ilbc_dec_class
static
Initial value:
= {
.class_name = "libilbc",
.item_name = av_default_item_name,
.option = ilbc_dec_options,
}
#define LIBAVUTIL_VERSION_INT
Definition: version.h:70
av_default_item_name
static const AVOption ilbc_dec_options[]
Definition: libilbc.c:48

Definition at line 53 of file libilbc.c.

AVCodec ff_libilbc_decoder
Initial value:
= {
.name = "libilbc",
.long_name = NULL_IF_CONFIG_SMALL("iLBC (Internet Low Bitrate Codec)"),
.priv_data_size = sizeof(ILBCDecContext),
.capabilities = AV_CODEC_CAP_DR1,
.priv_class = &ilbc_dec_class,
}
static int ilbc_decode_frame(AVCodecContext *avctx, void *data, int *got_frame_ptr, AVPacket *avpkt)
Definition: libilbc.c:80
static av_cold int init(AVCodecContext *avctx)
Definition: avrndec.c:35
static av_cold int ilbc_decode_init(AVCodecContext *avctx)
Definition: libilbc.c:60
static const AVClass ilbc_dec_class
Definition: libilbc.c:53
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
Definition: internal.h:176
static int decode(AVCodecContext *avctx, void *data, int *got_sub, AVPacket *avpkt)
Definition: ccaption_dec.c:752
#define AV_CODEC_CAP_DR1
Codec uses get_buffer() for allocating buffers and supports custom allocators.
Definition: avcodec.h:958

Definition at line 106 of file libilbc.c.

const AVOption ilbc_enc_options[]
static
Initial value:
= {
{ "mode", "iLBC mode (20 or 30 ms frames)", 0x42, AV_OPT_TYPE_INT, { .i64 = 20 }, 20, 30, AV_OPT_FLAG_AUDIO_PARAM | AV_OPT_FLAG_ENCODING_PARAM },
{ NULL }
}
#define NULL
Definition: coverity.c:32
#define AV_OPT_FLAG_AUDIO_PARAM
Definition: opt.h:280
#define AV_OPT_FLAG_ENCODING_PARAM
a generic parameter which can be set by the user for muxing or encoding
Definition: opt.h:275

Definition at line 124 of file libilbc.c.

const AVClass ilbc_enc_class
static
Initial value:
= {
.class_name = "libilbc",
.item_name = av_default_item_name,
.option = ilbc_enc_options,
}
#define LIBAVUTIL_VERSION_INT
Definition: version.h:70
av_default_item_name
static const AVOption ilbc_enc_options[]
Definition: libilbc.c:124

Definition at line 129 of file libilbc.c.

const AVCodecDefault ilbc_encode_defaults[]
static
Initial value:
= {
{ "b", "0" },
{ NULL }
}
#define NULL
Definition: coverity.c:32

Definition at line 179 of file libilbc.c.

AVCodec ff_libilbc_encoder
Initial value:
= {
.name = "libilbc",
.long_name = NULL_IF_CONFIG_SMALL("iLBC (Internet Low Bitrate Codec)"),
.priv_data_size = sizeof(ILBCEncContext),
.encode2 = ilbc_encode_frame,
.defaults = ilbc_encode_defaults,
.priv_class = &ilbc_enc_class,
}
static av_cold int init(AVCodecContext *avctx)
Definition: avrndec.c:35
static av_cold int ilbc_encode_init(AVCodecContext *avctx)
Definition: libilbc.c:136
static const AVCodecDefault ilbc_encode_defaults[]
Definition: libilbc.c:179
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
Definition: internal.h:176
static const AVClass ilbc_enc_class
Definition: libilbc.c:129
static int ilbc_encode_frame(AVCodecContext *avctx, AVPacket *avpkt, const AVFrame *frame, int *got_packet_ptr)
Definition: libilbc.c:163
AVSampleFormat
Audio sample formats.
Definition: samplefmt.h:58
signed 16 bits
Definition: samplefmt.h:61
static enum AVSampleFormat sample_fmts[]
Definition: adpcmenc.c:701

Definition at line 184 of file libilbc.c.