Commit 1fec0550 authored by Martin Storsjö's avatar Martin Storsjö

msmpeg4: Add ff_ prefixes to nonstatic symbols

Signed-off-by: 's avatarMartin Storsjö <martin@martin.st>
parent 35e02a3d
...@@ -696,9 +696,9 @@ av_cold void ff_intrax8_common_init(IntraX8Context * w, MpegEncContext * const s ...@@ -696,9 +696,9 @@ av_cold void ff_intrax8_common_init(IntraX8Context * w, MpegEncContext * const s
assert(s->mb_width>0); assert(s->mb_width>0);
w->prediction_table=av_mallocz(s->mb_width*2*2);//two rows, 2 blocks per cannon mb w->prediction_table=av_mallocz(s->mb_width*2*2);//two rows, 2 blocks per cannon mb
ff_init_scantable(s->dsp.idct_permutation, &w->scantable[0], wmv1_scantable[0]); ff_init_scantable(s->dsp.idct_permutation, &w->scantable[0], ff_wmv1_scantable[0]);
ff_init_scantable(s->dsp.idct_permutation, &w->scantable[1], wmv1_scantable[2]); ff_init_scantable(s->dsp.idct_permutation, &w->scantable[1], ff_wmv1_scantable[2]);
ff_init_scantable(s->dsp.idct_permutation, &w->scantable[2], wmv1_scantable[3]); ff_init_scantable(s->dsp.idct_permutation, &w->scantable[2], ff_wmv1_scantable[3]);
} }
/** /**
......
This diff is collapsed.
...@@ -54,7 +54,7 @@ const uint16_t ff_msmp4_mb_i_table[64][2] = { ...@@ -54,7 +54,7 @@ const uint16_t ff_msmp4_mb_i_table[64][2] = {
}; };
/* non intra picture macroblock coded block pattern + mb type */ /* non intra picture macroblock coded block pattern + mb type */
const uint32_t table_mb_non_intra[128][2] = { const uint32_t ff_table_mb_non_intra[128][2] = {
{ 0x40, 7 },{ 0x13c9, 13 },{ 0x9fd, 12 },{ 0x1fc, 15 }, { 0x40, 7 },{ 0x13c9, 13 },{ 0x9fd, 12 },{ 0x1fc, 15 },
{ 0x9fc, 12 },{ 0xa83, 18 },{ 0x12d34, 17 },{ 0x83bc, 16 }, { 0x9fc, 12 },{ 0xa83, 18 },{ 0x12d34, 17 },{ 0x83bc, 16 },
{ 0x83a, 12 },{ 0x7f8, 17 },{ 0x3fd, 16 },{ 0x3ff, 16 }, { 0x83a, 12 },{ 0x7f8, 17 },{ 0x3fd, 16 },{ 0x3ff, 16 },
...@@ -600,7 +600,7 @@ extern const uint16_t ff_mpeg4_intra_vlc[103][2]; ...@@ -600,7 +600,7 @@ extern const uint16_t ff_mpeg4_intra_vlc[103][2];
extern const int8_t ff_mpeg4_intra_level[102]; extern const int8_t ff_mpeg4_intra_level[102];
extern const int8_t ff_mpeg4_intra_run[102]; extern const int8_t ff_mpeg4_intra_run[102];
RLTable rl_table[NB_RL_TABLES] = { RLTable ff_rl_table[NB_RL_TABLES] = {
/* intra luminance tables */ /* intra luminance tables */
/* low motion */ /* low motion */
{ {
...@@ -1784,7 +1784,7 @@ static const uint8_t table1_mvy[1099] = { ...@@ -1784,7 +1784,7 @@ static const uint8_t table1_mvy[1099] = {
34, 28, 21, 34, 28, 21,
}; };
MVTable mv_tables[2] = { MVTable ff_mv_tables[2] = {
{ {
1099, 1099,
table0_mv_code, table0_mv_code,
...@@ -1801,30 +1801,30 @@ MVTable mv_tables[2] = { ...@@ -1801,30 +1801,30 @@ MVTable mv_tables[2] = {
} }
}; };
const uint8_t v2_mb_type[8][2] = { const uint8_t ff_v2_mb_type[8][2] = {
{1, 1}, {0 , 2}, {3 , 3}, {9 , 5}, {1, 1}, {0 , 2}, {3 , 3}, {9 , 5},
{5, 4}, {0x21, 7}, {0x20, 7}, {0x11, 6}, {5, 4}, {0x21, 7}, {0x20, 7}, {0x11, 6},
}; };
const uint8_t v2_intra_cbpc[4][2] = { const uint8_t ff_v2_intra_cbpc[4][2] = {
{1, 1}, {0, 3}, {1, 3}, {1, 2}, {1, 1}, {0, 3}, {1, 3}, {1, 2},
}; };
const uint8_t wmv1_y_dc_scale_table[32]={ const uint8_t ff_wmv1_y_dc_scale_table[32]={
// 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31 // 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31
0, 8, 8, 8, 8, 8, 9, 9,10,10,11,11,12,12,13,13,14,14,15,15,16,16,17,17,18,18,19,19,20,20,21,21 0, 8, 8, 8, 8, 8, 9, 9,10,10,11,11,12,12,13,13,14,14,15,15,16,16,17,17,18,18,19,19,20,20,21,21
}; };
const uint8_t wmv1_c_dc_scale_table[32]={ const uint8_t ff_wmv1_c_dc_scale_table[32]={
// 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31 // 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31
0, 8, 8, 8, 8, 9, 9,10,10,11,11,12,12,13,13,14,14,15,15,16,16,17,17,18,18,19,19,20,20,21,21,22 0, 8, 8, 8, 8, 9, 9,10,10,11,11,12,12,13,13,14,14,15,15,16,16,17,17,18,18,19,19,20,20,21,21,22
}; };
const uint8_t old_ff_y_dc_scale_table[32]={ const uint8_t ff_old_ff_y_dc_scale_table[32]={
// 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 // 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
0, 8, 8, 8, 8,10,12,14,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39 0, 8, 8, 8, 8,10,12,14,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39
}; };
const uint8_t wmv1_scantable[WMV1_SCANTABLE_COUNT][64]={ const uint8_t ff_wmv1_scantable[WMV1_SCANTABLE_COUNT][64]={
{ {
0x00, 0x08, 0x01, 0x02, 0x09, 0x10, 0x18, 0x11, 0x00, 0x08, 0x01, 0x02, 0x09, 0x10, 0x18, 0x11,
0x0A, 0x03, 0x04, 0x0B, 0x12, 0x19, 0x20, 0x28, 0x0A, 0x03, 0x04, 0x0B, 0x12, 0x19, 0x20, 0x28,
...@@ -1867,7 +1867,7 @@ const uint8_t wmv1_scantable[WMV1_SCANTABLE_COUNT][64]={ ...@@ -1867,7 +1867,7 @@ const uint8_t wmv1_scantable[WMV1_SCANTABLE_COUNT][64]={
} }
}; };
const uint8_t table_inter_intra[4][2]={ const uint8_t ff_table_inter_intra[4][2]={
{0,1} /*Luma-Left Chroma-Left*/, {0,1} /*Luma-Left Chroma-Left*/,
{2,2} /*Luma-Top Chroma-Left*/, {2,2} /*Luma-Top Chroma-Left*/,
{6,3} /*luma-Left Chroma-Top */, {6,3} /*luma-Left Chroma-Top */,
...@@ -1979,21 +1979,21 @@ static const uint32_t table_mb_non_intra4[128][2] = { ...@@ -1979,21 +1979,21 @@ static const uint32_t table_mb_non_intra4[128][2] = {
{0x000011, 5}, {0x0001AC, 9}, {0x0000F3, 8}, {0x000439, 11}, {0x000011, 5}, {0x0001AC, 9}, {0x0000F3, 8}, {0x000439, 11},
}; };
const uint32_t (* const wmv2_inter_table[WMV2_INTER_CBP_TABLE_COUNT])[2]={ const uint32_t (* const ff_wmv2_inter_table[WMV2_INTER_CBP_TABLE_COUNT])[2]={
table_mb_non_intra2, table_mb_non_intra2,
table_mb_non_intra3, table_mb_non_intra3,
table_mb_non_intra4, table_mb_non_intra4,
table_mb_non_intra, ff_table_mb_non_intra,
}; };
const uint8_t wmv2_scantableA[64]={ const uint8_t ff_wmv2_scantableA[64]={
0x00, 0x01, 0x02, 0x08, 0x03, 0x09, 0x0A, 0x10, 0x00, 0x01, 0x02, 0x08, 0x03, 0x09, 0x0A, 0x10,
0x04, 0x0B, 0x11, 0x18, 0x12, 0x0C, 0x05, 0x13, 0x04, 0x0B, 0x11, 0x18, 0x12, 0x0C, 0x05, 0x13,
0x19, 0x0D, 0x14, 0x1A, 0x1B, 0x06, 0x15, 0x1C, 0x19, 0x0D, 0x14, 0x1A, 0x1B, 0x06, 0x15, 0x1C,
0x0E, 0x16, 0x1D, 0x07, 0x1E, 0x0F, 0x17, 0x1F, 0x0E, 0x16, 0x1D, 0x07, 0x1E, 0x0F, 0x17, 0x1F,
}; };
const uint8_t wmv2_scantableB[64]={ const uint8_t ff_wmv2_scantableB[64]={
0x00, 0x08, 0x01, 0x10, 0x09, 0x18, 0x11, 0x02, 0x00, 0x08, 0x01, 0x10, 0x09, 0x18, 0x11, 0x02,
0x20, 0x0A, 0x19, 0x28, 0x12, 0x30, 0x21, 0x1A, 0x20, 0x0A, 0x19, 0x28, 0x12, 0x30, 0x21, 0x1A,
0x38, 0x29, 0x22, 0x03, 0x31, 0x39, 0x0B, 0x2A, 0x38, 0x29, 0x22, 0x03, 0x31, 0x39, 0x0B, 0x2A,
......
...@@ -54,23 +54,23 @@ extern const uint16_t ff_msmp4_mb_i_table[64][2]; ...@@ -54,23 +54,23 @@ extern const uint16_t ff_msmp4_mb_i_table[64][2];
#define WMV1_SCANTABLE_COUNT 4 #define WMV1_SCANTABLE_COUNT 4
extern const uint8_t wmv1_scantable[WMV1_SCANTABLE_COUNT][64]; extern const uint8_t ff_wmv1_scantable[WMV1_SCANTABLE_COUNT][64];
#define NB_RL_TABLES 6 #define NB_RL_TABLES 6
extern RLTable rl_table[NB_RL_TABLES]; extern RLTable ff_rl_table[NB_RL_TABLES];
extern const uint8_t wmv1_y_dc_scale_table[32]; extern const uint8_t ff_wmv1_y_dc_scale_table[32];
extern const uint8_t wmv1_c_dc_scale_table[32]; extern const uint8_t ff_wmv1_c_dc_scale_table[32];
extern const uint8_t old_ff_y_dc_scale_table[32]; extern const uint8_t ff_old_ff_y_dc_scale_table[32];
extern MVTable mv_tables[2]; extern MVTable ff_mv_tables[2];
extern const uint8_t v2_mb_type[8][2]; extern const uint8_t ff_v2_mb_type[8][2];
extern const uint8_t v2_intra_cbpc[4][2]; extern const uint8_t ff_v2_intra_cbpc[4][2];
extern const uint32_t table_mb_non_intra[128][2]; extern const uint32_t ff_table_mb_non_intra[128][2];
extern const uint8_t table_inter_intra[4][2]; extern const uint8_t ff_table_inter_intra[4][2];
extern const uint32_t ff_table0_dc_lum[120][2]; extern const uint32_t ff_table0_dc_lum[120][2];
extern const uint32_t ff_table1_dc_lum[120][2]; extern const uint32_t ff_table1_dc_lum[120][2];
...@@ -78,9 +78,9 @@ extern const uint32_t ff_table0_dc_chroma[120][2]; ...@@ -78,9 +78,9 @@ extern const uint32_t ff_table0_dc_chroma[120][2];
extern const uint32_t ff_table1_dc_chroma[120][2]; extern const uint32_t ff_table1_dc_chroma[120][2];
#define WMV2_INTER_CBP_TABLE_COUNT 4 #define WMV2_INTER_CBP_TABLE_COUNT 4
extern const uint32_t (* const wmv2_inter_table[WMV2_INTER_CBP_TABLE_COUNT])[2]; extern const uint32_t (* const ff_wmv2_inter_table[WMV2_INTER_CBP_TABLE_COUNT])[2];
extern const uint8_t wmv2_scantableA[64]; extern const uint8_t ff_wmv2_scantableA[64];
extern const uint8_t wmv2_scantableB[64]; extern const uint8_t ff_wmv2_scantableB[64];
#endif /* AVCODEC_MSMPEG4DATA_H */ #endif /* AVCODEC_MSMPEG4DATA_H */
...@@ -304,8 +304,8 @@ int vc1_decode_sequence_header(AVCodecContext *avctx, VC1Context *v, GetBitConte ...@@ -304,8 +304,8 @@ int vc1_decode_sequence_header(AVCodecContext *avctx, VC1Context *v, GetBitConte
v->zz_4x8 = ff_vc1_adv_progressive_4x8_zz; v->zz_4x8 = ff_vc1_adv_progressive_4x8_zz;
return decode_sequence_header_adv(v, gb); return decode_sequence_header_adv(v, gb);
} else { } else {
v->zz_8x4 = wmv2_scantableA; v->zz_8x4 = ff_wmv2_scantableA;
v->zz_4x8 = wmv2_scantableB; v->zz_4x8 = ff_wmv2_scantableB;
v->res_y411 = get_bits1(gb); v->res_y411 = get_bits1(gb);
v->res_sprite = get_bits1(gb); v->res_sprite = get_bits1(gb);
if (v->res_y411) { if (v->res_y411) {
......
...@@ -5351,16 +5351,16 @@ static av_cold int vc1_decode_init(AVCodecContext *avctx) ...@@ -5351,16 +5351,16 @@ static av_cold int vc1_decode_init(AVCodecContext *avctx)
if (v->profile == PROFILE_ADVANCED || v->res_fasttx) { if (v->profile == PROFILE_ADVANCED || v->res_fasttx) {
for (i = 0; i < 64; i++) { for (i = 0; i < 64; i++) {
#define transpose(x) ((x >> 3) | ((x & 7) << 3)) #define transpose(x) ((x >> 3) | ((x & 7) << 3))
v->zz_8x8[0][i] = transpose(wmv1_scantable[0][i]); v->zz_8x8[0][i] = transpose(ff_wmv1_scantable[0][i]);
v->zz_8x8[1][i] = transpose(wmv1_scantable[1][i]); v->zz_8x8[1][i] = transpose(ff_wmv1_scantable[1][i]);
v->zz_8x8[2][i] = transpose(wmv1_scantable[2][i]); v->zz_8x8[2][i] = transpose(ff_wmv1_scantable[2][i]);
v->zz_8x8[3][i] = transpose(wmv1_scantable[3][i]); v->zz_8x8[3][i] = transpose(ff_wmv1_scantable[3][i]);
v->zzi_8x8[i] = transpose(ff_vc1_adv_interlaced_8x8_zz[i]); v->zzi_8x8[i] = transpose(ff_vc1_adv_interlaced_8x8_zz[i]);
} }
v->left_blk_sh = 0; v->left_blk_sh = 0;
v->top_blk_sh = 3; v->top_blk_sh = 3;
} else { } else {
memcpy(v->zz_8x8, wmv1_scantable, 4*64); memcpy(v->zz_8x8, ff_wmv1_scantable, 4*64);
v->left_blk_sh = 3; v->left_blk_sh = 3;
v->top_blk_sh = 0; v->top_blk_sh = 0;
} }
......
...@@ -28,8 +28,8 @@ ...@@ -28,8 +28,8 @@
av_cold void ff_wmv2_common_init(Wmv2Context * w){ av_cold void ff_wmv2_common_init(Wmv2Context * w){
MpegEncContext * const s= &w->s; MpegEncContext * const s= &w->s;
ff_init_scantable(s->dsp.idct_permutation, &w->abt_scantable[0], wmv2_scantableA); ff_init_scantable(s->dsp.idct_permutation, &w->abt_scantable[0], ff_wmv2_scantableA);
ff_init_scantable(s->dsp.idct_permutation, &w->abt_scantable[1], wmv2_scantableB); ff_init_scantable(s->dsp.idct_permutation, &w->abt_scantable[1], ff_wmv2_scantableB);
} }
static void wmv2_add_block(Wmv2Context *w, DCTELEM *block1, uint8_t *dst, int stride, int n){ static void wmv2_add_block(Wmv2Context *w, DCTELEM *block1, uint8_t *dst, int stride, int n){
......
...@@ -167,8 +167,8 @@ void ff_wmv2_encode_mb(MpegEncContext * s, ...@@ -167,8 +167,8 @@ void ff_wmv2_encode_mb(MpegEncContext * s,
} }
put_bits(&s->pb, put_bits(&s->pb,
wmv2_inter_table[w->cbp_table_index][cbp + 64][1], ff_wmv2_inter_table[w->cbp_table_index][cbp + 64][1],
wmv2_inter_table[w->cbp_table_index][cbp + 64][0]); ff_wmv2_inter_table[w->cbp_table_index][cbp + 64][0]);
/* motion vector */ /* motion vector */
ff_h263_pred_motion(s, 0, 0, &pred_x, &pred_y); ff_h263_pred_motion(s, 0, 0, &pred_x, &pred_y);
...@@ -196,13 +196,13 @@ void ff_wmv2_encode_mb(MpegEncContext * s, ...@@ -196,13 +196,13 @@ void ff_wmv2_encode_mb(MpegEncContext * s,
ff_msmp4_mb_i_table[coded_cbp][1], ff_msmp4_mb_i_table[coded_cbp][0]); ff_msmp4_mb_i_table[coded_cbp][1], ff_msmp4_mb_i_table[coded_cbp][0]);
} else { } else {
put_bits(&s->pb, put_bits(&s->pb,
wmv2_inter_table[w->cbp_table_index][cbp][1], ff_wmv2_inter_table[w->cbp_table_index][cbp][1],
wmv2_inter_table[w->cbp_table_index][cbp][0]); ff_wmv2_inter_table[w->cbp_table_index][cbp][0]);
} }
put_bits(&s->pb, 1, 0); /* no AC prediction yet */ put_bits(&s->pb, 1, 0); /* no AC prediction yet */
if(s->inter_intra_pred){ if(s->inter_intra_pred){
s->h263_aic_dir=0; s->h263_aic_dir=0;
put_bits(&s->pb, table_inter_intra[s->h263_aic_dir][1], table_inter_intra[s->h263_aic_dir][0]); put_bits(&s->pb, ff_table_inter_intra[s->h263_aic_dir][1], ff_table_inter_intra[s->h263_aic_dir][0]);
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment