#include <limits.h>
#include "libavutil/audioconvert.h"
#include "libavutil/avassert.h"
#include "libavutil/crc.h"
#include "avcodec.h"
#include "internal.h"
#include "get_bits.h"
#include "bytestream.h"
#include "golomb.h"
#include "flac.h"
#include "flacdata.h"
#include "flacdsp.h"
Go to the source code of this file.
Data Structures | |
| struct | FLACContext |
Functions | |
| static void | allocate_buffers (FLACContext *s) |
| static void | flac_set_bps (FLACContext *s) |
| static av_cold int | flac_decode_init (AVCodecContext *avctx) |
| static void | dump_headers (AVCodecContext *avctx, FLACStreaminfo *s) |
| static int | parse_streaminfo (FLACContext *s, const uint8_t *buf, int buf_size) |
| Parse the STREAMINFO from an inline header. | |
| static int | get_metadata_size (const uint8_t *buf, int buf_size) |
| Determine the size of an inline header. | |
| static int | decode_residuals (FLACContext *s, int32_t *decoded, int pred_order) |
| static int | decode_subframe_fixed (FLACContext *s, int32_t *decoded, int pred_order, int bps) |
| static int | decode_subframe_lpc (FLACContext *s, int32_t *decoded, int pred_order, int bps) |
| static int | decode_subframe (FLACContext *s, int channel) |
| static int | decode_frame (FLACContext *s) |
| static int | flac_decode_frame (AVCodecContext *avctx, void *data, int *got_frame_ptr, AVPacket *avpkt) |
| static av_cold int | flac_decode_close (AVCodecContext *avctx) |
Variables | |
| static const int64_t | flac_channel_layouts [6] |
| AVCodec | ff_flac_decoder |
Definition in file flacdec.c.
| static void allocate_buffers | ( | FLACContext * | s | ) | [static] |
| static int decode_frame | ( | FLACContext * | s | ) | [static] |
| static int decode_residuals | ( | FLACContext * | s, | |
| int32_t * | decoded, | |||
| int | pred_order | |||
| ) | [static] |
Definition at line 205 of file flacdec.c.
Referenced by decode_subframe_fixed(), and decode_subframe_lpc().
| static int decode_subframe | ( | FLACContext * | s, | |
| int | channel | |||
| ) | [inline, static] |
| static int decode_subframe_fixed | ( | FLACContext * | s, | |
| int32_t * | decoded, | |||
| int | pred_order, | |||
| int | bps | |||
| ) | [static] |
| static int decode_subframe_lpc | ( | FLACContext * | s, | |
| int32_t * | decoded, | |||
| int | pred_order, | |||
| int | bps | |||
| ) | [static] |
Definition at line 299 of file flacdec.c.
Referenced by decode_subframe(), and shorten_decode_frame().
| static void dump_headers | ( | AVCodecContext * | avctx, | |
| FLACStreaminfo * | s | |||
| ) | [static] |
| static av_cold int flac_decode_close | ( | AVCodecContext * | avctx | ) | [static] |
| static int flac_decode_frame | ( | AVCodecContext * | avctx, | |
| void * | data, | |||
| int * | got_frame_ptr, | |||
| AVPacket * | avpkt | |||
| ) | [static] |
| static av_cold int flac_decode_init | ( | AVCodecContext * | avctx | ) | [static] |
| static void flac_set_bps | ( | FLACContext * | s | ) | [static] |
Definition at line 76 of file flacdec.c.
Referenced by decode_frame(), flac_decode_init(), and parse_streaminfo().
Determine the size of an inline header.
| buf | input buffer, starting with the "fLaC" marker | |
| buf_size | buffer size |
Definition at line 184 of file flacdec.c.
Referenced by flac_decode_frame().
| static int parse_streaminfo | ( | FLACContext * | s, | |
| const uint8_t * | buf, | |||
| int | buf_size | |||
| ) | [static] |
Parse the STREAMINFO from an inline header.
| s | the flac decoding context | |
| buf | input buffer, starting with the "fLaC" marker | |
| buf_size | buffer size |
Definition at line 156 of file flacdec.c.
Referenced by flac_decode_frame().
Initial value:
{
.name = "flac",
.type = AVMEDIA_TYPE_AUDIO,
.id = AV_CODEC_ID_FLAC,
.priv_data_size = sizeof(FLACContext),
.init = flac_decode_init,
.close = flac_decode_close,
.decode = flac_decode_frame,
.capabilities = CODEC_CAP_DR1,
.long_name = NULL_IF_CONFIG_SMALL("FLAC (Free Lossless Audio Codec)"),
.sample_fmts = (const enum AVSampleFormat[]) { AV_SAMPLE_FMT_S16,
AV_SAMPLE_FMT_S16P,
AV_SAMPLE_FMT_S32,
AV_SAMPLE_FMT_S32P,
-1 },
}
const int64_t flac_channel_layouts[6] [static] |
Initial value:
{
AV_CH_LAYOUT_MONO,
AV_CH_LAYOUT_STEREO,
AV_CH_LAYOUT_SURROUND,
AV_CH_LAYOUT_QUAD,
AV_CH_LAYOUT_5POINT0,
AV_CH_LAYOUT_5POINT1
}
Definition at line 65 of file flacdec.c.
Referenced by flac_decode_init().
1.5.8