FFmpeg
Data Structures | Macros | Functions | Variables
mobiclip.c File Reference
#include <inttypes.h>
#include "libavutil/avassert.h"
#include "avcodec.h"
#include "bytestream.h"
#include "bswapdsp.h"
#include "get_bits.h"
#include "golomb.h"
#include "internal.h"

Go to the source code of this file.

Data Structures

struct  BlockXY
 
struct  MotionXY
 
struct  MobiClipContext
 

Macros

#define MOBI_RL_VLC_BITS   12
 
#define MOBI_MV_VLC_BITS   6
 

Functions

static av_cold int mobiclip_init (AVCodecContext *avctx)
 
static int setup_qtables (AVCodecContext *avctx, int quantizer)
 
static void inverse4 (unsigned *rs)
 
static void idct (int *arr, int size)
 
static void read_run_encoding (AVCodecContext *avctx, int *last, int *run, int *level)
 
static int add_coefficients (AVCodecContext *avctx, AVFrame *frame, int bx, int by, int size, int plane)
 
static int add_pframe_coefficients (AVCodecContext *avctx, AVFrame *frame, int bx, int by, int size, int plane)
 
static int adjust (int x, int size)
 
static uint8_t pget (BlockXY b)
 
static uint8_t half (int a, int b)
 
static uint8_t half3 (int a, int b, int c)
 
static uint8_t pick_above (BlockXY bxy)
 
static uint8_t pick_left (BlockXY bxy)
 
static uint8_t half_horz (BlockXY bxy)
 
static uint8_t half_vert (BlockXY bxy)
 
static uint8_t pick_4 (BlockXY bxy)
 
static uint8_t pick_5 (BlockXY bxy)
 
static uint8_t pick_6 (BlockXY bxy)
 
static uint8_t pick_7 (BlockXY bxy)
 
static uint8_t pick_8 (BlockXY bxy)
 
static void block_fill_simple (uint8_t *block, int size, int linesize, int fill)
 
static void block_fill (uint8_t *block, int size, int linesize, int w, int h, int ax, int ay, uint8_t(*pick)(BlockXY bxy))
 
static int block_sum (const uint8_t *block, int w, int h, int linesize)
 
static int predict_intra (AVCodecContext *avctx, AVFrame *frame, int ax, int ay, int pmode, int add_coeffs, int size, int plane)
 
static int get_prediction (AVCodecContext *avctx, int x, int y, int size)
 
static int process_block (AVCodecContext *avctx, AVFrame *frame, int x, int y, int pmode, int has_coeffs, int plane)
 
static int decode_macroblock (AVCodecContext *avctx, AVFrame *frame, int x, int y, int predict)
 
static int get_index (int x)
 
static int predict_motion (AVCodecContext *avctx, int width, int height, int index, int offsetm, int offsetx, int offsety)
 
static int mobiclip_decode (AVCodecContext *avctx, void *data, int *got_frame, AVPacket *pkt)
 
static void mobiclip_flush (AVCodecContext *avctx)
 
static av_cold int mobiclip_close (AVCodecContext *avctx)
 

Variables

static const uint8_t zigzag4x4_tab []
 
static const uint8_t quant4x4_tab [][16]
 
static const uint8_t quant8x8_tab [][64]
 
static const uint8_t block4x4_coefficients_tab []
 
static const uint8_t pframe_block4x4_coefficients_tab []
 
static const uint8_t block8x8_coefficients_tab []
 
static const uint8_t pframe_block8x8_coefficients_tab []
 
static const uint8_t run_residue [2][256]
 
static const uint8_t bits0 []
 
static const uint8_t codes0 []
 
static const uint16_t syms0 []
 
static const uint16_t syms1 []
 
static const uint8_t mv_len [16]
 
static const uint8_t mv_bits [16][10]
 
static const uint8_t mv_codes [16][10]
 
static const uint8_t mv_syms [16][10]
 
static const uint8_t mv_bits_mods [16][10]
 
static const uint8_t mv_codes_mods [16][10]
 
static const uint8_t mv_syms_mods [16][10]
 
static VLC rl_vlc [2]
 
static VLC mv_vlc [2][16]
 
AVCodec ff_mobiclip_decoder
 

Macro Definition Documentation

#define MOBI_RL_VLC_BITS   12

Definition at line 34 of file mobiclip.c.

Referenced by mobiclip_init(), and read_run_encoding().

#define MOBI_MV_VLC_BITS   6

Definition at line 35 of file mobiclip.c.

Referenced by mobiclip_decode(), mobiclip_init(), and predict_motion().

Function Documentation

static av_cold int mobiclip_init ( AVCodecContext avctx)
static

Definition at line 330 of file mobiclip.c.

static int setup_qtables ( AVCodecContext avctx,
int  quantizer 
)
static

Definition at line 383 of file mobiclip.c.

Referenced by mobiclip_decode().

static void inverse4 ( unsigned *  rs)
static

Definition at line 408 of file mobiclip.c.

Referenced by idct().

static void idct ( int arr,
int  size 
)
static

Definition at line 421 of file mobiclip.c.

Referenced by add_coefficients().

static void read_run_encoding ( AVCodecContext avctx,
int last,
int run,
int level 
)
static

Definition at line 458 of file mobiclip.c.

Referenced by add_coefficients().

static int add_coefficients ( AVCodecContext avctx,
AVFrame frame,
int  bx,
int  by,
int  size,
int  plane 
)
static

Definition at line 471 of file mobiclip.c.

Referenced by add_pframe_coefficients(), and predict_intra().

static int add_pframe_coefficients ( AVCodecContext avctx,
AVFrame frame,
int  bx,
int  by,
int  size,
int  plane 
)
static

Definition at line 537 of file mobiclip.c.

Referenced by mobiclip_decode().

static int adjust ( int  x,
int  size 
)
static
static uint8_t pget ( BlockXY  b)
static

Definition at line 571 of file mobiclip.c.

Referenced by half_horz(), half_vert(), pick_4(), pick_5(), pick_6(), pick_7(), pick_8(), pick_above(), and pick_left().

static uint8_t half ( int  a,
int  b 
)
static
static uint8_t half3 ( int  a,
int  b,
int  c 
)
static

Definition at line 597 of file mobiclip.c.

Referenced by half_horz(), half_vert(), and pick_7().

static uint8_t pick_above ( BlockXY  bxy)
static

Definition at line 602 of file mobiclip.c.

Referenced by predict_intra().

static uint8_t pick_left ( BlockXY  bxy)
static

Definition at line 609 of file mobiclip.c.

Referenced by predict_intra().

static uint8_t half_horz ( BlockXY  bxy)
static

Definition at line 616 of file mobiclip.c.

Referenced by pick_5(), pick_6(), and pick_8().

static uint8_t half_vert ( BlockXY  bxy)
static

Definition at line 626 of file mobiclip.c.

Referenced by mm_decode_inter(), mm_decode_intra(), pick_4(), pick_5(), and pick_6().

static uint8_t pick_4 ( BlockXY  bxy)
static

Definition at line 636 of file mobiclip.c.

Referenced by predict_intra().

static uint8_t pick_5 ( BlockXY  bxy)
static

Definition at line 667 of file mobiclip.c.

Referenced by predict_intra().

static uint8_t pick_6 ( BlockXY  bxy)
static

Definition at line 707 of file mobiclip.c.

Referenced by predict_intra().

static uint8_t pick_7 ( BlockXY  bxy)
static

Definition at line 747 of file mobiclip.c.

Referenced by predict_intra().

static uint8_t pick_8 ( BlockXY  bxy)
static

Definition at line 779 of file mobiclip.c.

Referenced by predict_intra().

static void block_fill_simple ( uint8_t block,
int  size,
int  linesize,
int  fill 
)
static

Definition at line 830 of file mobiclip.c.

Referenced by predict_intra().

static void block_fill ( uint8_t block,
int  size,
int  linesize,
int  w,
int  h,
int  ax,
int  ay,
uint8_t(*)(BlockXY bxy)  pick 
)
static

Definition at line 838 of file mobiclip.c.

Referenced by predict_intra().

static int block_sum ( const uint8_t block,
int  w,
int  h,
int  linesize 
)
static

Definition at line 866 of file mobiclip.c.

Referenced by encode_block(), and predict_intra().

static int predict_intra ( AVCodecContext avctx,
AVFrame frame,
int  ax,
int  ay,
int  pmode,
int  add_coeffs,
int  size,
int  plane 
)
static

Definition at line 880 of file mobiclip.c.

Referenced by decode_macroblock(), and process_block().

static int get_prediction ( AVCodecContext avctx,
int  x,
int  y,
int  size 
)
static

Definition at line 980 of file mobiclip.c.

Referenced by process_block().

static int process_block ( AVCodecContext avctx,
AVFrame frame,
int  x,
int  y,
int  pmode,
int  has_coeffs,
int  plane 
)
static

Definition at line 1002 of file mobiclip.c.

Referenced by decode_macroblock().

static int decode_macroblock ( AVCodecContext avctx,
AVFrame frame,
int  x,
int  y,
int  predict 
)
static

Definition at line 1043 of file mobiclip.c.

Referenced by mobiclip_decode().

static int get_index ( int  x)
static

Definition at line 1123 of file mobiclip.c.

Referenced by predict_motion().

static int predict_motion ( AVCodecContext avctx,
int  width,
int  height,
int  index,
int  offsetm,
int  offsetx,
int  offsety 
)
static

Definition at line 1128 of file mobiclip.c.

Referenced by mobiclip_decode().

static int mobiclip_decode ( AVCodecContext avctx,
void data,
int got_frame,
AVPacket pkt 
)
static

Definition at line 1260 of file mobiclip.c.

static void mobiclip_flush ( AVCodecContext avctx)
static

Definition at line 1368 of file mobiclip.c.

static av_cold int mobiclip_close ( AVCodecContext avctx)
static

Definition at line 1376 of file mobiclip.c.

Variable Documentation

const uint8_t zigzag4x4_tab[]
static
Initial value:
=
{
0x00, 0x04, 0x01, 0x02, 0x05, 0x08, 0x0C, 0x09, 0x06, 0x03, 0x07, 0x0A,
0x0D, 0x0E, 0x0B, 0x0F
}

Definition at line 37 of file mobiclip.c.

Referenced by add_coefficients().

const uint8_t quant4x4_tab[][16]
static
Initial value:
=
{
{ 10, 13, 13, 10, 16, 10, 13, 13, 13, 13, 16, 10, 16, 13, 13, 16 },
{ 11, 14, 14, 11, 18, 11, 14, 14, 14, 14, 18, 11, 18, 14, 14, 18 },
{ 13, 16, 16, 13, 20, 13, 16, 16, 16, 16, 20, 13, 20, 16, 16, 20 },
{ 14, 18, 18, 14, 23, 14, 18, 18, 18, 18, 23, 14, 23, 18, 18, 23 },
{ 16, 20, 20, 16, 25, 16, 20, 20, 20, 20, 25, 16, 25, 20, 20, 25 },
{ 18, 23, 23, 18, 29, 18, 23, 23, 23, 23, 29, 18, 29, 23, 23, 29 },
}

Definition at line 43 of file mobiclip.c.

Referenced by setup_qtables().

const uint8_t quant8x8_tab[][64]
static
Initial value:
=
{
{ 20, 19, 19, 25, 18, 25, 19, 24, 24, 19, 20, 18, 32, 18, 20, 19, 19, 24, 24, 19, 19, 25, 18, 25, 18, 25, 18, 25, 19, 24, 24, 19,
19, 24, 24, 19, 18, 32, 18, 20, 18, 32, 18, 24, 24, 19, 19, 24, 24, 18, 25, 18, 25, 18, 19, 24, 24, 19, 18, 32, 18, 24, 24, 18,},
{ 22, 21, 21, 28, 19, 28, 21, 26, 26, 21, 22, 19, 35, 19, 22, 21, 21, 26, 26, 21, 21, 28, 19, 28, 19, 28, 19, 28, 21, 26, 26, 21,
21, 26, 26, 21, 19, 35, 19, 22, 19, 35, 19, 26, 26, 21, 21, 26, 26, 19, 28, 19, 28, 19, 21, 26, 26, 21, 19, 35, 19, 26, 26, 19,},
{ 26, 24, 24, 33, 23, 33, 24, 31, 31, 24, 26, 23, 42, 23, 26, 24, 24, 31, 31, 24, 24, 33, 23, 33, 23, 33, 23, 33, 24, 31, 31, 24,
24, 31, 31, 24, 23, 42, 23, 26, 23, 42, 23, 31, 31, 24, 24, 31, 31, 23, 33, 23, 33, 23, 24, 31, 31, 24, 23, 42, 23, 31, 31, 23,},
{ 28, 26, 26, 35, 25, 35, 26, 33, 33, 26, 28, 25, 45, 25, 28, 26, 26, 33, 33, 26, 26, 35, 25, 35, 25, 35, 25, 35, 26, 33, 33, 26,
26, 33, 33, 26, 25, 45, 25, 28, 25, 45, 25, 33, 33, 26, 26, 33, 33, 25, 35, 25, 35, 25, 26, 33, 33, 26, 25, 45, 25, 33, 33, 25,},
{ 32, 30, 30, 40, 28, 40, 30, 38, 38, 30, 32, 28, 51, 28, 32, 30, 30, 38, 38, 30, 30, 40, 28, 40, 28, 40, 28, 40, 30, 38, 38, 30,
30, 38, 38, 30, 28, 51, 28, 32, 28, 51, 28, 38, 38, 30, 30, 38, 38, 28, 40, 28, 40, 28, 30, 38, 38, 30, 28, 51, 28, 38, 38, 28,},
{ 36, 34, 34, 46, 32, 46, 34, 43, 43, 34, 36, 32, 58, 32, 36, 34, 34, 43, 43, 34, 34, 46, 32, 46, 32, 46, 32, 46, 34, 43, 43, 34,
34, 43, 43, 34, 32, 58, 32, 36, 32, 58, 32, 43, 43, 34, 34, 43, 43, 32, 46, 32, 46, 32, 34, 43, 43, 34, 32, 58, 32, 43, 43, 32,},
}

Definition at line 53 of file mobiclip.c.

Referenced by setup_qtables().

const uint8_t block4x4_coefficients_tab[]
static
Initial value:
=
{
15, 0, 2, 1, 4, 8, 12, 3, 11, 13, 14, 7, 10, 5, 9, 6,
}

Definition at line 69 of file mobiclip.c.

Referenced by process_block().

const uint8_t pframe_block4x4_coefficients_tab[]
static
Initial value:
=
{
0, 4, 1, 8, 2, 12, 3, 5, 10, 15, 7, 13, 14, 11, 9, 6,
}

Definition at line 74 of file mobiclip.c.

Referenced by add_pframe_coefficients().

const uint8_t block8x8_coefficients_tab[]
static
Initial value:
=
{
0x00, 0x1F, 0x3F, 0x0F, 0x08, 0x04, 0x02, 0x01, 0x0B, 0x0E, 0x1B, 0x0D,
0x03, 0x07, 0x0C, 0x17, 0x1D, 0x0A, 0x1E, 0x05, 0x10, 0x2F, 0x37, 0x3B,
0x13, 0x3D, 0x3E, 0x09, 0x1C, 0x06, 0x15, 0x1A, 0x33, 0x11, 0x12, 0x14,
0x18, 0x20, 0x3C, 0x35, 0x19, 0x16, 0x3A, 0x30, 0x31, 0x32, 0x27, 0x34,
0x2B, 0x2D, 0x39, 0x38, 0x23, 0x36, 0x2E, 0x21, 0x25, 0x22, 0x24, 0x2C,
0x2A, 0x28, 0x29, 0x26,
}

Definition at line 79 of file mobiclip.c.

Referenced by decode_macroblock().

const uint8_t pframe_block8x8_coefficients_tab[]
static
Initial value:
=
{
0x00, 0x0F, 0x04, 0x01, 0x08, 0x02, 0x0C, 0x03, 0x05, 0x0A, 0x0D, 0x07, 0x0E, 0x0B, 0x1F, 0x09,
0x06, 0x10, 0x3F, 0x1E, 0x17, 0x1D, 0x1B, 0x1C, 0x13, 0x18, 0x1A, 0x12, 0x11, 0x14, 0x15, 0x20,
0x2F, 0x16, 0x19, 0x37, 0x3D, 0x3E, 0x3B, 0x3C, 0x33, 0x35, 0x21, 0x24, 0x22, 0x28, 0x23, 0x2C,
0x30, 0x27, 0x2D, 0x25, 0x3A, 0x2B, 0x2E, 0x2A, 0x31, 0x34, 0x38, 0x32, 0x29, 0x26, 0x39, 0x36
}

Definition at line 89 of file mobiclip.c.

Referenced by mobiclip_decode().

const uint8_t run_residue[2][256]
static
Initial value:
=
{
{
12, 6, 4, 3, 3, 3, 3, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
3, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1, 27, 11, 7, 3, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 41, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
},
{
27, 10, 5, 4, 3, 3, 3, 3, 2, 2, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
8, 3, 2, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1, 15, 10, 8, 4, 3, 2, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 21, 7, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
},
}

Definition at line 97 of file mobiclip.c.

Referenced by add_coefficients().

const uint8_t bits0[]
static
Initial value:
= {
9, 11, 11, 11, 11, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12,
12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 7, 10, 10, 9,
9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
9, 9, 9, 9, 9, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
8, 8, 8, 7, 7, 7, 7, 7, 7, 7, 7, 6, 6, 6, 6,
6, 6, 6, 6, 6, 6, 5, 5, 5, 4, 2, 3, 4, 4,
}

Definition at line 121 of file mobiclip.c.

Referenced by mobiclip_init().

const uint8_t codes0[]
static
Initial value:
= {
0x0, 0x4, 0x5, 0x6, 0x7, 0x4, 0x5, 0x6, 0x7, 0x8, 0x9, 0xA,
0xB, 0xC, 0xD, 0xE, 0xF, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25,
0x26, 0x27, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57,
0x58, 0x59, 0x5A, 0x5B, 0x5C, 0x5D, 0x5E, 0x5F, 0x3, 0x20,
0x21, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19,
0x1A, 0x1B, 0x1C, 0x1D, 0x1E, 0x1F, 0x20, 0x21, 0x22, 0x23,
0x24, 0x25, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, 0x1A,
0x1B, 0x1C, 0x1D, 0x1E, 0x1F, 0x10, 0x11, 0x12, 0x13, 0x14,
0x15, 0x16, 0x17, 0xC, 0xD, 0xE, 0xF, 0x10, 0x11, 0x12,
0x13, 0x14, 0x15, 0xB, 0xC, 0xD, 0x7, 0x2, 0x6, 0xE, 0xF,
}

Definition at line 131 of file mobiclip.c.

Referenced by mobiclip_init().

const uint16_t syms0[]
static
Initial value:
= {
0x0, 0x822, 0x803, 0xB, 0xA, 0xB81, 0xB61, 0xB41, 0xB21, 0x122,
0x102, 0xE2, 0xC2, 0xA2, 0x63, 0x43, 0x24, 0xC, 0x25, 0x2E1, 0x301,
0xBA1, 0xBC1, 0xBE1, 0xC01, 0x26, 0x44, 0x83, 0xA3, 0xC3, 0x142,
0x321, 0x341, 0xC21, 0xC41, 0xC61, 0xC81, 0xCA1, 0xCC1, 0xCE1, 0xD01,
0x0, 0x9, 0x8, 0xB01, 0xAE1, 0xAC1, 0xAA1, 0xA81, 0xA61, 0xA41, 0xA21,
0x802, 0x2C1, 0x2A1, 0x281, 0x261, 0x241, 0x221, 0x201, 0x1E1, 0x82,
0x62, 0x7, 0x6, 0xA01, 0x9E1, 0x9C1, 0x9A1, 0x981, 0x961, 0x941, 0x921,
0x1C1, 0x1A1, 0x42, 0x23, 0x5, 0x901, 0x8E1, 0x8C1, 0x8A1, 0x181, 0x161,
0x141, 0x4, 0x881, 0x861, 0x841, 0x821, 0x121, 0x101, 0xE1, 0xC1, 0x22,
0x3, 0xA1, 0x81, 0x61, 0x801, 0x1, 0x21, 0x41, 0x2,
}

Definition at line 144 of file mobiclip.c.

Referenced by mobiclip_init().

const uint16_t syms1[]
static
Initial value:
= {
0x0, 0x807, 0x806, 0x16, 0x15, 0x842, 0x823, 0x805, 0x1A1, 0xA3, 0x102, 0x83,
0x64, 0x44, 0x27, 0x14, 0x13, 0x17, 0x18, 0x28, 0x122, 0x862, 0x882, 0x9E1, 0xA01,
0x19, 0x1A, 0x1B, 0x29, 0xC3, 0x2A, 0x45, 0xE3, 0x1C1, 0x808, 0x8A2, 0x8C2, 0xA21,
0xA41, 0xA61, 0xA81, 0x0, 0x12, 0x11, 0x9C1, 0x9A1, 0x981, 0x961, 0x941, 0x822, 0x804,
0x181, 0x161, 0xE2, 0xC2, 0xA2, 0x63, 0x43, 0x26, 0x25, 0x10, 0x82, 0xF, 0xE, 0xD, 0x901,
0x8E1, 0x8C1, 0x803, 0x141, 0x121, 0x101, 0x921, 0x62, 0x24, 0xC, 0xB, 0xA, 0x881, 0x861,
0xC1, 0x8A1, 0xE1, 0x42, 0x23, 0x9, 0x802, 0xA1, 0x841, 0x821, 0x81, 0x61, 0x8, 0x7, 0x22,
0x6, 0x41, 0x5, 0x4, 0x801, 0x1, 0x2, 0x21, 0x3,
}

Definition at line 157 of file mobiclip.c.

Referenced by mobiclip_init().

const uint8_t mv_len[16]
static
Initial value:
=
{
10, 8, 8, 7, 8, 8, 8, 7, 8, 8, 8, 7, 7, 7, 7, 6,
}

Definition at line 168 of file mobiclip.c.

Referenced by mobiclip_init().

const uint8_t mv_bits[16][10]
static
Initial value:
=
{
{ 1, 3, 3, 4, 4, 5, 5, 5, 6, 6 },
{ 2, 2, 3, 3, 3, 4, 5, 5 },
{ 2, 2, 3, 3, 4, 4, 4, 4 },
{ 1, 3, 3, 4, 4, 4, 4 },
{ 2, 2, 3, 3, 3, 4, 5, 5 },
{ 2, 3, 3, 3, 3, 3, 4, 4 },
{ 1, 3, 3, 4, 4, 4, 5, 5 },
{ 1, 3, 3, 4, 4, 4, 4 },
{ 2, 2, 3, 3, 4, 4, 4, 4 },
{ 1, 3, 3, 4, 4, 4, 5, 5 },
{ 2, 2, 3, 3, 4, 4, 4, 4 },
{ 2, 2, 3, 3, 3, 4, 4 },
{ 1, 3, 3, 4, 4, 4, 4 },
{ 1, 3, 3, 4, 4, 4, 4 },
{ 2, 2, 3, 3, 3, 4, 4 },
{ 2, 2, 3, 3, 3, 3 },
}

Definition at line 173 of file mobiclip.c.

Referenced by merge_context_after_encode(), and mobiclip_init().

const uint8_t mv_codes[16][10]
static
Initial value:
=
{
{ 1, 0, 2, 2, 7, 6, 7, 12, 26, 27 },
{ 0, 2, 2, 6, 7, 6, 14, 15 },
{ 0, 3, 3, 4, 4, 5, 10, 11 },
{ 0, 5, 7, 8, 9, 12, 13 },
{ 1, 3, 0, 1, 5, 8, 18, 19 },
{ 3, 0, 2, 3, 4, 5, 2, 3 },
{ 0, 4, 5, 12, 13, 14, 30, 31 },
{ 0, 5, 6, 8, 9, 14, 15 },
{ 0, 3, 3, 4, 4, 5, 10, 11 },
{ 0, 4, 5, 12, 13, 14, 30, 31 },
{ 0, 3, 2, 5, 6, 7, 8, 9 },
{ 0, 3, 2, 3, 5, 8, 9 },
{ 0, 5, 6, 8, 9, 14, 15 },
{ 0, 5, 6, 8, 9, 14, 15 },
{ 0, 3, 2, 3, 5, 8, 9 },
{ 0, 3, 2, 3, 4, 5 },
}

Definition at line 193 of file mobiclip.c.

Referenced by mobiclip_init().

const uint8_t mv_syms[16][10]
static
Initial value:
=
{
{ 0, 8, 1, 2, 9, 3, 6, 7, 5, 4 },
{ 9, 1, 2, 8, 0, 3, 5, 4 },
{ 0, 1, 2, 9, 5, 4, 3, 8 },
{ 1, 2, 0, 5, 4, 8, 3 },
{ 8, 1, 2, 9, 0, 3, 5, 4 },
{ 1, 3, 2, 9, 8, 0, 5, 4 },
{ 1, 2, 0, 9, 8, 3, 5, 4 },
{ 1, 2, 0, 8, 5, 4, 3 },
{ 0, 1, 2, 8, 5, 4, 3, 9 },
{ 1, 2, 0, 9, 8, 3, 5, 4 },
{ 0, 1, 3, 2, 9, 8, 5, 4 },
{ 0, 1, 4, 3, 2, 8, 5 },
{ 1, 2, 0, 5, 4, 9, 3 },
{ 1, 2, 0, 9, 5, 4, 3 },
{ 0, 1, 5, 3, 2, 9, 4 },
{ 0, 1, 4, 5, 3, 2 },
}

Definition at line 213 of file mobiclip.c.

Referenced by mobiclip_init().

const uint8_t mv_bits_mods[16][10]
static
Initial value:
=
{
{ 2, 2, 3, 3, 4, 4, 5, 5, 5, 5 },
{ 2, 2, 3, 3, 4, 4, 4, 4 },
{ 2, 2, 3, 3, 4, 4, 4, 4 },
{ 1, 3, 3, 3, 4, 5, 5 },
{ 2, 2, 3, 3, 4, 4, 4, 4 },
{ 2, 2, 3, 3, 4, 4, 4, 4 },
{ 2, 2, 3, 3, 4, 4, 4, 4 },
{ 2, 2, 2, 3, 4, 5, 5 },
{ 2, 2, 3, 3, 4, 4, 4, 4 },
{ 2, 2, 3, 3, 4, 4, 4, 4 },
{ 2, 2, 3, 3, 3, 4, 5, 5 },
{ 2, 2, 3, 3, 3, 4, 4 },
{ 1, 3, 3, 4, 4, 4, 4 },
{ 2, 2, 3, 3, 3, 4, 4 },
{ 2, 2, 3, 3, 3, 4, 4 },
{ 2, 2, 3, 3, 3, 3 },
}

Definition at line 233 of file mobiclip.c.

Referenced by mobiclip_init().

const uint8_t mv_codes_mods[16][10]
static
Initial value:
=
{
{ 0, 3, 2, 3, 9, 10, 16, 17, 22, 23 },
{ 0, 3, 2, 4, 6, 7, 10, 11 },
{ 1, 3, 0, 5, 2, 3, 8, 9 },
{ 0, 4, 6, 7, 10, 22, 23 },
{ 0, 3, 3, 4, 4, 5, 10, 11 },
{ 0, 3, 2, 5, 6, 7, 8, 9 },
{ 0, 3, 2, 5, 6, 7, 8, 9 },
{ 0, 1, 3, 4, 10, 22, 23 },
{ 0, 3, 2, 4, 6, 7, 10, 11 },
{ 0, 3, 3, 5, 4, 5, 8, 9 },
{ 0, 3, 2, 3, 5, 9, 16, 17 },
{ 0, 3, 2, 4, 5, 6, 7 },
{ 0, 5, 6, 8, 9, 14, 15 },
{ 0, 3, 2, 4, 5, 6, 7 },
{ 0, 3, 2, 4, 5, 6, 7 },
{ 1, 2, 0, 1, 6, 7 },
}

Definition at line 253 of file mobiclip.c.

Referenced by mobiclip_init().

const uint8_t mv_syms_mods[16][10]
static
Initial value:
=
{
{ 1, 0, 8, 9, 2, 7, 4, 3, 5, 6 },
{ 0, 1, 9, 2, 5, 4, 3, 8 },
{ 0, 1, 3, 2, 9, 5, 4, 8 },
{ 1, 3, 2, 0, 4, 8, 5 },
{ 0, 1, 8, 2, 5, 4, 3, 9 },
{ 0, 1, 3, 2, 5, 9, 4, 8 },
{ 0, 1, 3, 2, 9, 5, 8, 4 },
{ 0, 2, 1, 3, 4, 8, 5 },
{ 0, 1, 3, 2, 8, 4, 5, 9 },
{ 2, 1, 3, 0, 8, 9, 5, 4 },
{ 0, 1, 4, 3, 2, 5, 8, 9 },
{ 0, 1, 4, 3, 2, 8, 5 },
{ 1, 2, 0, 9, 4, 5, 3 },
{ 2, 1, 4, 3, 0, 9, 5 },
{ 0, 1, 4, 3, 2, 9, 5 },
{ 1, 0, 5, 4, 3, 2 },
}

Definition at line 273 of file mobiclip.c.

Referenced by mobiclip_init().

VLC rl_vlc[2]
static

Definition at line 327 of file mobiclip.c.

Referenced by ff_msmpeg4_decode_block(), and mpeg4_decode_block().

VLC mv_vlc[2][16]
static

Definition at line 328 of file mobiclip.c.

AVCodec ff_mobiclip_decoder
Initial value:
= {
.name = "mobiclip",
.long_name = NULL_IF_CONFIG_SMALL("MobiClip Video"),
.priv_data_size = sizeof(MobiClipContext),
.close = mobiclip_close,
.capabilities = AV_CODEC_CAP_DR1,
.caps_internal = FF_CODEC_CAP_INIT_CLEANUP,
}
#define FF_CODEC_CAP_INIT_CLEANUP
The codec allows calling the close function for deallocation even if the init function returned a fai...
Definition: internal.h:48
static void flush(AVCodecContext *avctx)
static av_cold int init(AVCodecContext *avctx)
Definition: avrndec.c:35
static av_cold int mobiclip_close(AVCodecContext *avctx)
Definition: mobiclip.c:1376
static void decode(AVCodecContext *dec_ctx, AVPacket *pkt, AVFrame *frame, FILE *outfile)
Definition: decode_audio.c:71
static void mobiclip_flush(AVCodecContext *avctx)
Definition: mobiclip.c:1368
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
Definition: internal.h:153
static av_cold int mobiclip_init(AVCodecContext *avctx)
Definition: mobiclip.c:330
static int mobiclip_decode(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *pkt)
Definition: mobiclip.c:1260
#define AV_CODEC_CAP_DR1
Codec uses get_buffer() for allocating buffers and supports custom allocators.
Definition: codec.h:50

Definition at line 1392 of file mobiclip.c.