FFmpeg
|
Duck TrueMotion2 decoder. More...
#include "avcodec.h"
#include "bytestream.h"
#include "get_bits.h"
#include "dsputil.h"
#include "internal.h"
Go to the source code of this file.
Data Structures | |
struct | TM2Context |
struct | TM2Codes |
Huffman codes for each of streams. More... | |
struct | TM2Huff |
structure for gathering Huffman codes information More... | |
Macros | |
#define | TM2_ESCAPE 0x80000000 |
#define | TM2_DELTAS 64 |
#define | TM2_OLD_HEADER_MAGIC 0x00000100 |
#define | TM2_NEW_HEADER_MAGIC 0x00000101 |
#define | TM2_INIT_POINTERS() |
#define | TM2_INIT_POINTERS_2() |
#define | TM2_RECALC_BLOCK(CHR, stride, last, CD) |
#define | TM2_HEADER_SIZE 40 |
Enumerations | |
enum | TM2_STREAMS { TM2_C_HI = 0, TM2_C_LO, TM2_L_HI, TM2_L_LO, TM2_UPD, TM2_MOT, TM2_TYPE, TM2_NUM_STREAMS } |
enum | TM2_BLOCKS { TM2_HI_RES = 0, TM2_MED_RES, TM2_LOW_RES, TM2_NULL_RES, TM2_UPDATE, TM2_STILL, TM2_MOTION } |
Functions | |
static int | tm2_read_tree (TM2Context *ctx, uint32_t prefix, int length, TM2Huff *huff) |
static int | tm2_build_huff_table (TM2Context *ctx, TM2Codes *code) |
static void | tm2_free_codes (TM2Codes *code) |
static int | tm2_get_token (GetBitContext *gb, TM2Codes *code) |
static int | tm2_read_header (TM2Context *ctx, const uint8_t *buf) |
static int | tm2_read_deltas (TM2Context *ctx, int stream_id) |
static int | tm2_read_stream (TM2Context *ctx, const uint8_t *buf, int stream_id, int buf_size) |
static int | GET_TOK (TM2Context *ctx, int type) |
static void | tm2_apply_deltas (TM2Context *ctx, int *Y, int stride, int *deltas, int *last) |
static void | tm2_high_chroma (int *data, int stride, int *last, int *CD, int *deltas) |
static void | tm2_low_chroma (int *data, int stride, int *clast, int *CD, int *deltas, int bx) |
static void | tm2_hi_res_block (TM2Context *ctx, AVFrame *pic, int bx, int by) |
static void | tm2_med_res_block (TM2Context *ctx, AVFrame *pic, int bx, int by) |
static void | tm2_low_res_block (TM2Context *ctx, AVFrame *pic, int bx, int by) |
static void | tm2_null_res_block (TM2Context *ctx, AVFrame *pic, int bx, int by) |
static void | tm2_still_block (TM2Context *ctx, AVFrame *pic, int bx, int by) |
static void | tm2_update_block (TM2Context *ctx, AVFrame *pic, int bx, int by) |
static void | tm2_motion_block (TM2Context *ctx, AVFrame *pic, int bx, int by) |
static int | tm2_decode_blocks (TM2Context *ctx, AVFrame *p) |
static int | decode_frame (AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt) |
static av_cold int | decode_init (AVCodecContext *avctx) |
static av_cold int | decode_end (AVCodecContext *avctx) |
Variables | |
static const int | tm2_stream_order [TM2_NUM_STREAMS] |
AVCodec | ff_truemotion2_decoder |
Duck TrueMotion2 decoder.
Definition in file truemotion2.c.
#define TM2_ESCAPE 0x80000000 |
Definition at line 33 of file truemotion2.c.
Referenced by tm2_read_stream().
#define TM2_DELTAS 64 |
Definition at line 34 of file truemotion2.c.
Referenced by GET_TOK(), tm2_read_deltas(), and tm2_read_stream().
#define TM2_OLD_HEADER_MAGIC 0x00000100 |
Definition at line 235 of file truemotion2.c.
Referenced by tm2_read_header().
#define TM2_NEW_HEADER_MAGIC 0x00000101 |
Definition at line 236 of file truemotion2.c.
Referenced by tm2_read_header().
#define TM2_INIT_POINTERS | ( | ) |
Definition at line 403 of file truemotion2.c.
Referenced by tm2_hi_res_block(), tm2_low_res_block(), tm2_med_res_block(), and tm2_null_res_block().
#define TM2_INIT_POINTERS_2 | ( | ) |
Definition at line 417 of file truemotion2.c.
Referenced by tm2_motion_block(), tm2_still_block(), and tm2_update_block().
#define TM2_RECALC_BLOCK | ( | CHR, | |
stride, | |||
last, | |||
CD | |||
) |
Definition at line 430 of file truemotion2.c.
Referenced by tm2_motion_block(), tm2_still_block(), and tm2_update_block().
#define TM2_HEADER_SIZE 40 |
Definition at line 866 of file truemotion2.c.
Referenced by decode_frame().
enum TM2_STREAMS |
Definition at line 37 of file truemotion2.c.
enum TM2_BLOCKS |
Definition at line 49 of file truemotion2.c.
|
static |
Definition at line 112 of file truemotion2.c.
Referenced by tm2_build_huff_table().
|
static |
Definition at line 143 of file truemotion2.c.
Referenced by tm2_read_stream().
Definition at line 219 of file truemotion2.c.
Referenced by tm2_read_stream().
|
inlinestatic |
Definition at line 226 of file truemotion2.c.
Referenced by tm2_read_stream().
|
inlinestatic |
Definition at line 238 of file truemotion2.c.
Referenced by decode_frame().
|
static |
Definition at line 254 of file truemotion2.c.
Referenced by tm2_read_stream().
|
static |
Definition at line 280 of file truemotion2.c.
Referenced by decode_frame().
|
inlinestatic |
Definition at line 384 of file truemotion2.c.
Referenced by tm2_decode_blocks(), tm2_hi_res_block(), tm2_low_res_block(), tm2_med_res_block(), tm2_motion_block(), and tm2_update_block().
|
inlinestatic |
Definition at line 437 of file truemotion2.c.
Referenced by tm2_hi_res_block(), tm2_low_res_block(), tm2_med_res_block(), and tm2_null_res_block().
|
inlinestatic |
Definition at line 455 of file truemotion2.c.
Referenced by tm2_hi_res_block(), and tm2_low_chroma().
|
inlinestatic |
Definition at line 468 of file truemotion2.c.
Referenced by tm2_low_res_block(), tm2_med_res_block(), and tm2_null_res_block().
|
inlinestatic |
Definition at line 487 of file truemotion2.c.
Referenced by tm2_decode_blocks().
|
inlinestatic |
Definition at line 508 of file truemotion2.c.
Referenced by tm2_decode_blocks().
|
inlinestatic |
Definition at line 530 of file truemotion2.c.
Referenced by tm2_decode_blocks().
|
inlinestatic |
Definition at line 571 of file truemotion2.c.
Referenced by tm2_decode_blocks().
|
inlinestatic |
Definition at line 617 of file truemotion2.c.
Referenced by tm2_decode_blocks().
|
inlinestatic |
Definition at line 652 of file truemotion2.c.
Referenced by tm2_decode_blocks().
|
inlinestatic |
Definition at line 692 of file truemotion2.c.
Referenced by tm2_decode_blocks().
|
static |
Definition at line 746 of file truemotion2.c.
Referenced by decode_frame().
|
static |
Definition at line 868 of file truemotion2.c.
|
static |
Definition at line 922 of file truemotion2.c.
|
static |
Definition at line 986 of file truemotion2.c.
|
static |
Definition at line 862 of file truemotion2.c.
Referenced by decode_frame().
AVCodec ff_truemotion2_decoder |
Definition at line 1011 of file truemotion2.c.