options.c File Reference

Options definition for AVCodecContext. More...

#include "avcodec.h"
#include "internal.h"
#include "libavutil/avassert.h"
#include "libavutil/mem.h"
#include "libavutil/opt.h"
#include <float.h>
#include <string.h>
#include "options_table.h"

Go to the source code of this file.

Macros

#define alloc_and_copy_or_fail(obj, size, pad)
 

Functions

static const char * context_to_name (void *ptr)
 
static voidcodec_child_next (void *obj, void *prev)
 
static const AVClasscodec_child_class_next (const AVClass *prev)
 
int avcodec_get_context_defaults3 (AVCodecContext *s, const AVCodec *codec)
 Set the fields of the given AVCodecContext to default values corresponding to the given codec (defaults may be codec-dependent). More...
 
AVCodecContextavcodec_alloc_context3 (const AVCodec *codec)
 Allocate an AVCodecContext and set its fields to default values. More...
 
int avcodec_copy_context (AVCodecContext *dest, const AVCodecContext *src)
 Copy the settings of the source AVCodecContext into the destination AVCodecContext. More...
 
const AVClassavcodec_get_class (void)
 Get the AVClass for AVCodecContext. More...
 

Variables

static const AVClass av_codec_context_class
 

Detailed Description

Options definition for AVCodecContext.

Definition in file options.c.

Macro Definition Documentation

#define alloc_and_copy_or_fail (   obj,
  size,
  pad 
)
Value:
if (src->obj && size > 0) { \
dest->obj = av_malloc(size + pad); \
if (!dest->obj) \
goto fail; \
memcpy(dest->obj, src->obj, size); \
if (pad) \
memset(((uint8_t *) dest->obj) + size, 0, pad); \
}
void * av_malloc(size_t size)
Allocate a block of size bytes with alignment suitable for all memory accesses (including vectors if ...
Definition: mem.c:61
int size
uint8_t
if(!(ptr_align%ac->ptr_align)&&samples_align >=aligned_len)

Referenced by avcodec_copy_context().

Function Documentation

static const AVClass* codec_child_class_next ( const AVClass prev)
static

Definition at line 54 of file options.c.

static void* codec_child_next ( void obj,
void prev 
)
static

Definition at line 46 of file options.c.

static const char* context_to_name ( void ptr)
static

Definition at line 37 of file options.c.

Variable Documentation

const AVClass av_codec_context_class
static
Initial value:
= {
.class_name = "AVCodecContext",
.item_name = context_to_name,
.option = options,
.log_level_offset_offset = 0x42,
.child_next = codec_child_next,
.child_class_next = codec_child_class_next,
}
static void * codec_child_next(void *obj, void *prev)
Definition: options.c:46
static const char * context_to_name(void *ptr)
Definition: options.c:37
static const AVClass * codec_child_class_next(const AVClass *prev)
Definition: options.c:54
LIBAVUTIL_VERSION_INT
Definition: eval.c:52
static const AVOption options[]
Definition: options.c:36

Definition at line 70 of file options.c.

Referenced by avcodec_get_class(), and avcodec_get_context_defaults3().