libavcodec/vorbis_dec.c File Reference

Vorbis I decoder. More...

#include <math.h>
#include "avcodec.h"
#include "bitstream.h"
#include "dsputil.h"
#include "vorbis.h"
#include "xiph.h"
#include <assert.h>

Go to the source code of this file.

Data Structures

struct  vorbis_codebook
struct  vorbis_floor
union  vorbis_floor::vorbis_floor::vorbis_floor_u
struct  vorbis_floor::vorbis_floor::vorbis_floor_u::vorbis_floor::vorbis_floor_u::vorbis_floor0_s
struct  vorbis_floor::vorbis_floor::vorbis_floor_u::vorbis_floor::vorbis_floor_u::vorbis_floor1_s
struct  vorbis_residue
struct  vorbis_mapping
struct  vorbis_mode
struct  vorbis_context_s

Defines

#define ALT_BITSTREAM_READER_LE
#define V_NB_BITS   8
#define V_NB_BITS2   11
#define V_MAX_VLCS   (1<<16)
#define V_MAX_PARTITIONS   (1<<20)
#define AV_DEBUG(...)
#define BARK(x)   (13.1f*atan(0.00074f*(x))+2.24f*atan(1.85e-8f*(x)*(x))+1e-4f*(x))

Typedefs

typedef union vorbis_floor_u vorbis_floor_data
typedef struct vorbis_floor0_s vorbis_floor0
typedef struct vorbis_floor1_s vorbis_floor1
typedef int(* vorbis_floor_decode_func )(struct vorbis_context_s *, vorbis_floor_data *, float *)
typedef struct vorbis_context_s vorbis_context

Functions

static float vorbisfloat2float (uint_fast32_t val)
static void vorbis_free (vorbis_context *vc)
static int vorbis_parse_setup_hdr_codebooks (vorbis_context *vc)
static int vorbis_parse_setup_hdr_tdtransforms (vorbis_context *vc)
static int vorbis_floor0_decode (vorbis_context *vc, vorbis_floor_data *vfu, float *vec)
static void create_map (vorbis_context *vc, uint_fast8_t floor_number)
static int vorbis_floor1_decode (vorbis_context *vc, vorbis_floor_data *vfu, float *vec)
static int vorbis_parse_setup_hdr_floors (vorbis_context *vc)
static int vorbis_parse_setup_hdr_residues (vorbis_context *vc)
static int vorbis_parse_setup_hdr_mappings (vorbis_context *vc)
static int vorbis_parse_setup_hdr_modes (vorbis_context *vc)
static int vorbis_parse_setup_hdr (vorbis_context *vc)
static int vorbis_parse_id_hdr (vorbis_context *vc)
static av_cold int vorbis_decode_init (AVCodecContext *avccontext)
static av_always_inline int vorbis_residue_decode_internal (vorbis_context *vc, vorbis_residue *vr, uint_fast8_t ch, uint_fast8_t *do_not_decode, float *vec, uint_fast16_t vlen, unsigned ch_left, int vr_type)
static int vorbis_residue_decode (vorbis_context *vc, vorbis_residue *vr, uint_fast8_t ch, uint_fast8_t *do_not_decode, float *vec, uint_fast16_t vlen, unsigned ch_left)
void vorbis_inverse_coupling (float *mag, float *ang, int blocksize)
static void copy_normalize (float *dst, float *src, int len, int exp_bias, float add_bias)
static int vorbis_parse_audio_packet (vorbis_context *vc)
static int vorbis_decode_frame (AVCodecContext *avccontext, void *data, int *data_size, const uint8_t *buf, int buf_size)
static av_cold int vorbis_decode_close (AVCodecContext *avccontext)

Variables

AVCodec vorbis_decoder


Detailed Description

Vorbis I decoder.

Author:
Denes Balatoni ( dbalatoni programozo hu )
This file is part of FFmpeg.

FFmpeg is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.

FFmpeg is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with FFmpeg; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA

Definition in file vorbis_dec.c.


Define Documentation

#define ALT_BITSTREAM_READER_LE

Definition at line 29 of file vorbis_dec.c.

#define AV_DEBUG ( ...   ) 

#define BARK (  )     (13.1f*atan(0.00074f*(x))+2.24f*atan(1.85e-8f*(x)*(x))+1e-4f*(x))

Definition at line 163 of file vorbis_dec.c.

Referenced by create_map().

#define V_MAX_PARTITIONS   (1<<20)

Definition at line 40 of file vorbis_dec.c.

Referenced by vorbis_parse_setup_hdr_residues().

#define V_MAX_VLCS   (1<<16)

Definition at line 39 of file vorbis_dec.c.

Referenced by vorbis_parse_setup_hdr_codebooks().

#define V_NB_BITS   8

Definition at line 37 of file vorbis_dec.c.

Referenced by vorbis_parse_setup_hdr_codebooks().

#define V_NB_BITS2   11

Definition at line 38 of file vorbis_dec.c.

Referenced by vorbis_parse_setup_hdr_codebooks().


Typedef Documentation

typedef struct vorbis_floor0_s vorbis_floor0

Definition at line 59 of file vorbis_dec.c.

typedef struct vorbis_floor1_s vorbis_floor1

Definition at line 60 of file vorbis_dec.c.

typedef union vorbis_floor_u vorbis_floor_data

Definition at line 58 of file vorbis_dec.c.

typedef int(* vorbis_floor_decode_func)(struct vorbis_context_s *, vorbis_floor_data *, float *)

Definition at line 64 of file vorbis_dec.c.


Function Documentation

static void copy_normalize ( float *  dst,
float *  src,
int  len,
int  exp_bias,
float  add_bias 
) [static]

Definition at line 1485 of file vorbis_dec.c.

Referenced by vorbis_parse_audio_packet().

static void create_map ( vorbis_context vc,
uint_fast8_t  floor_number 
) [static]

Definition at line 791 of file vorbis_dec.c.

Referenced by vorbis_parse_setup_hdr_floors().

static av_cold int vorbis_decode_close ( AVCodecContext avccontext  )  [static]

Definition at line 1705 of file vorbis_dec.c.

static int vorbis_decode_frame ( AVCodecContext avccontext,
void *  data,
int *  data_size,
const uint8_t *  buf,
int  buf_size 
) [static]

Definition at line 1661 of file vorbis_dec.c.

static av_cold int vorbis_decode_init ( AVCodecContext avccontext  )  [static]

Definition at line 982 of file vorbis_dec.c.

static int vorbis_floor0_decode ( vorbis_context vc,
vorbis_floor_data vfu,
float *  vec 
) [static]

Definition at line 1049 of file vorbis_dec.c.

Referenced by vorbis_parse_setup_hdr_floors().

static int vorbis_floor1_decode ( vorbis_context vc,
vorbis_floor_data vfu,
float *  vec 
) [static]

Definition at line 1165 of file vorbis_dec.c.

Referenced by vorbis_parse_setup_hdr_floors().

static void vorbis_free ( vorbis_context vc  )  [static]

Definition at line 176 of file vorbis_dec.c.

Referenced by vorbis_decode_close(), and vorbis_decode_init().

void vorbis_inverse_coupling ( float *  mag,
float *  ang,
int  blocksize 
)

Definition at line 1460 of file vorbis_dec.c.

Referenced by dsputil_init().

static int vorbis_parse_audio_packet ( vorbis_context vc  )  [static]

Definition at line 1499 of file vorbis_dec.c.

Referenced by vorbis_decode_frame().

static int vorbis_parse_id_hdr ( vorbis_context vc  )  [static]

Definition at line 901 of file vorbis_dec.c.

Referenced by vorbis_decode_init().

static int vorbis_parse_setup_hdr ( vorbis_context vc  )  [static]

Definition at line 857 of file vorbis_dec.c.

Referenced by vorbis_decode_init().

static int vorbis_parse_setup_hdr_codebooks ( vorbis_context vc  )  [static]

Definition at line 225 of file vorbis_dec.c.

Referenced by vorbis_parse_setup_hdr().

static int vorbis_parse_setup_hdr_floors ( vorbis_context vc  )  [static]

Definition at line 451 of file vorbis_dec.c.

Referenced by vorbis_parse_setup_hdr().

static int vorbis_parse_setup_hdr_mappings ( vorbis_context vc  )  [static]

Definition at line 711 of file vorbis_dec.c.

Referenced by vorbis_parse_setup_hdr().

static int vorbis_parse_setup_hdr_modes ( vorbis_context vc  )  [static]

Definition at line 829 of file vorbis_dec.c.

Referenced by vorbis_parse_setup_hdr().

static int vorbis_parse_setup_hdr_residues ( vorbis_context vc  )  [static]

Definition at line 633 of file vorbis_dec.c.

Referenced by vorbis_parse_setup_hdr().

static int vorbis_parse_setup_hdr_tdtransforms ( vorbis_context vc  )  [static]

Definition at line 426 of file vorbis_dec.c.

Referenced by vorbis_parse_setup_hdr().

static int vorbis_residue_decode ( vorbis_context vc,
vorbis_residue vr,
uint_fast8_t  ch,
uint_fast8_t *  do_not_decode,
float *  vec,
uint_fast16_t  vlen,
unsigned  ch_left 
) [inline, static]

Definition at line 1446 of file vorbis_dec.c.

Referenced by vorbis_parse_audio_packet().

static av_always_inline int vorbis_residue_decode_internal ( vorbis_context vc,
vorbis_residue vr,
uint_fast8_t  ch,
uint_fast8_t *  do_not_decode,
float *  vec,
uint_fast16_t  vlen,
unsigned  ch_left,
int  vr_type 
) [static]

Definition at line 1296 of file vorbis_dec.c.

Referenced by vorbis_residue_decode().

static float vorbisfloat2float ( uint_fast32_t  val  )  [static]

Definition at line 166 of file vorbis_dec.c.

Referenced by vorbis_parse_setup_hdr_codebooks().


Variable Documentation

Initial value:

Definition at line 1713 of file vorbis_dec.c.


Generated on Fri Oct 26 02:35:44 2012 for FFmpeg by  doxygen 1.5.8