mpeg4: Add ff_ prefixes to nonstatic symbols

Signed-off-by: Martin Storsjö <martin@martin.st>
pull/3/merge
Martin Storsjö 13 years ago
parent e9ca85e714
commit 6f13a371ec
  1. 4
      libavcodec/ituh263dec.c
  2. 10
      libavcodec/mpeg4data.h
  3. 18
      libavcodec/mpeg4video.h
  4. 34
      libavcodec/mpeg4videodec.c
  5. 4
      libavcodec/mpeg4videoenc.c
  6. 4
      libavcodec/mpegvideo_enc.c
  7. 2
      libavcodec/msmpeg4.c

@ -238,7 +238,7 @@ int ff_h263_resync(MpegEncContext *s){
if(show_bits(&s->gb, 16)==0){
pos= get_bits_count(&s->gb);
if(CONFIG_MPEG4_DECODER && s->codec_id==CODEC_ID_MPEG4)
ret= mpeg4_decode_video_packet_header(s);
ret= ff_mpeg4_decode_video_packet_header(s);
else
ret= h263_decode_gob_header(s);
if(ret>=0)
@ -255,7 +255,7 @@ int ff_h263_resync(MpegEncContext *s){
pos= get_bits_count(&s->gb);
if(CONFIG_MPEG4_DECODER && s->codec_id==CODEC_ID_MPEG4)
ret= mpeg4_decode_video_packet_header(s);
ret= ff_mpeg4_decode_video_packet_header(s);
else
ret= h263_decode_gob_header(s);
if(ret>=0)

@ -211,7 +211,7 @@ static const int8_t inter_rvlc_level[169]={
1, 1,
};
RLTable rvlc_rl_inter = {
RLTable ff_rvlc_rl_inter = {
169,
103,
inter_rvlc,
@ -315,7 +315,7 @@ static const int8_t intra_rvlc_level[169]={
1, 1,
};
RLTable rvlc_rl_intra = {
RLTable ff_rvlc_rl_intra = {
169,
103,
intra_rvlc,
@ -323,13 +323,13 @@ RLTable rvlc_rl_intra = {
intra_rvlc_level,
};
const uint16_t sprite_trajectory_tab[15][2] = {
const uint16_t ff_sprite_trajectory_tab[15][2] = {
{0x00, 2}, {0x02, 3}, {0x03, 3}, {0x04, 3}, {0x05, 3}, {0x06, 3},
{0x0E, 4}, {0x1E, 5}, {0x3E, 6}, {0x7E, 7}, {0xFE, 8},
{0x1FE, 9},{0x3FE, 10},{0x7FE, 11},{0xFFE, 12},
};
const uint8_t mb_type_b_tab[4][2] = {
const uint8_t ff_mb_type_b_tab[4][2] = {
{1, 1}, {1, 2}, {1, 3}, {1, 4},
};
@ -369,7 +369,7 @@ const uint16_t ff_mpeg4_resync_prefix[8]={
0x7F00, 0x7E00, 0x7C00, 0x7800, 0x7000, 0x6000, 0x4000, 0x0000
};
const uint8_t mpeg4_dc_threshold[8]={
const uint8_t ff_mpeg4_dc_threshold[8]={
99, 13, 15, 17, 19, 21, 23, 0
};

@ -66,11 +66,11 @@ extern const uint16_t ff_mpeg4_intra_vlc[103][2];
extern RLTable ff_mpeg4_rl_intra;
/* Note this is identical to the intra rvlc except that it is reordered. */
extern RLTable rvlc_rl_inter;
extern RLTable rvlc_rl_intra;
extern RLTable ff_rvlc_rl_inter;
extern RLTable ff_rvlc_rl_intra;
extern const uint16_t sprite_trajectory_tab[15][2];
extern const uint8_t mb_type_b_tab[4][2];
extern const uint16_t ff_sprite_trajectory_tab[15][2];
extern const uint8_t ff_mb_type_b_tab[4][2];
/* these matrixes will be permuted for the idct */
extern const int16_t ff_mpeg4_default_intra_matrix[64];
@ -80,15 +80,15 @@ extern const uint8_t ff_mpeg4_y_dc_scale_table[32];
extern const uint8_t ff_mpeg4_c_dc_scale_table[32];
extern const uint16_t ff_mpeg4_resync_prefix[8];
extern const uint8_t mpeg4_dc_threshold[8];
extern const uint8_t ff_mpeg4_dc_threshold[8];
void mpeg4_encode_mb(MpegEncContext *s,
void ff_mpeg4_encode_mb(MpegEncContext *s,
DCTELEM block[6][64],
int motion_x, int motion_y);
void mpeg4_pred_ac(MpegEncContext * s, DCTELEM *block, int n,
void ff_mpeg4_pred_ac(MpegEncContext * s, DCTELEM *block, int n,
int dir);
void ff_set_mpeg4_time(MpegEncContext * s);
void mpeg4_encode_picture_header(MpegEncContext *s, int picture_number);
void ff_mpeg4_encode_picture_header(MpegEncContext *s, int picture_number);
int ff_mpeg4_decode_picture_header(MpegEncContext * s, GetBitContext *gb);
void ff_mpeg4_encode_video_packet_header(MpegEncContext *s);
@ -99,7 +99,7 @@ void ff_mpeg4_merge_partitions(MpegEncContext *s);
void ff_clean_mpeg4_qscales(MpegEncContext *s);
int ff_mpeg4_decode_partitions(MpegEncContext *s);
int ff_mpeg4_get_video_packet_prefix_length(MpegEncContext *s);
int mpeg4_decode_video_packet_header(MpegEncContext *s);
int ff_mpeg4_decode_video_packet_header(MpegEncContext *s);
void ff_mpeg4_init_direct_mv(MpegEncContext *s);
/**

@ -50,7 +50,7 @@ static const int mb_type_b_map[4]= {
* @param n block index (0-3 are luma, 4-5 are chroma)
* @param dir the ac prediction direction
*/
void mpeg4_pred_ac(MpegEncContext * s, DCTELEM *block, int n,
void ff_mpeg4_pred_ac(MpegEncContext * s, DCTELEM *block, int n,
int dir)
{
int i;
@ -346,7 +346,7 @@ static void mpeg4_decode_sprite_trajectory(MpegEncContext * s, GetBitContext *gb
* Decode the next video packet.
* @return <0 if something went wrong
*/
int mpeg4_decode_video_packet_header(MpegEncContext *s)
int ff_mpeg4_decode_video_packet_header(MpegEncContext *s)
{
int mb_num_bits= av_log2(s->mb_num - 1) + 1;
int header_extension=0, mb_num, len;
@ -875,8 +875,8 @@ static inline int mpeg4_decode_block(MpegEncContext * s, DCTELEM * block,
goto not_coded;
if(rvlc){
rl = &rvlc_rl_intra;
rl_vlc = rvlc_rl_intra.rl_vlc[0];
rl = &ff_rvlc_rl_intra;
rl_vlc = ff_rvlc_rl_intra.rl_vlc[0];
}else{
rl = &ff_mpeg4_rl_intra;
rl_vlc = ff_mpeg4_rl_intra.rl_vlc[0];
@ -897,7 +897,7 @@ static inline int mpeg4_decode_block(MpegEncContext * s, DCTELEM * block,
s->block_last_index[n] = i;
return 0;
}
if(rvlc) rl = &rvlc_rl_inter;
if(rvlc) rl = &ff_rvlc_rl_inter;
else rl = &ff_h263_rl_inter;
scan_table = s->intra_scantable.permutated;
@ -906,7 +906,7 @@ static inline int mpeg4_decode_block(MpegEncContext * s, DCTELEM * block,
qmul=1;
qadd=0;
if(rvlc){
rl_vlc = rvlc_rl_inter.rl_vlc[0];
rl_vlc = ff_rvlc_rl_inter.rl_vlc[0];
}else{
rl_vlc = ff_h263_rl_inter.rl_vlc[0];
}
@ -914,7 +914,7 @@ static inline int mpeg4_decode_block(MpegEncContext * s, DCTELEM * block,
qmul = s->qscale << 1;
qadd = (s->qscale - 1) | 1;
if(rvlc){
rl_vlc = rvlc_rl_inter.rl_vlc[s->qscale];
rl_vlc = ff_rvlc_rl_inter.rl_vlc[s->qscale];
}else{
rl_vlc = ff_h263_rl_inter.rl_vlc[s->qscale];
}
@ -1051,7 +1051,7 @@ static inline int mpeg4_decode_block(MpegEncContext * s, DCTELEM * block,
i -= i>>31; //if(i == -1) i=0;
}
mpeg4_pred_ac(s, block, n, dc_pred_dir);
ff_mpeg4_pred_ac(s, block, n, dc_pred_dir);
if (s->ac_pred) {
i = 63; /* XXX: not optimal */
}
@ -2004,7 +2004,7 @@ static int decode_vop_header(MpegEncContext *s, GetBitContext *gb){
if(s->pict_type == AV_PICTURE_TYPE_B)
skip_bits_long(gb, s->cplx_estimation_trash_b);
s->intra_dc_threshold= mpeg4_dc_threshold[ get_bits(gb, 3) ];
s->intra_dc_threshold= ff_mpeg4_dc_threshold[ get_bits(gb, 3) ];
if(!s->progressive_sequence){
s->top_field_first= get_bits1(gb);
s->alternate_scan= get_bits1(gb);
@ -2206,11 +2206,11 @@ static av_cold int decode_init(AVCodecContext *avctx)
done = 1;
ff_init_rl(&ff_mpeg4_rl_intra, ff_mpeg4_static_rl_table_store[0]);
ff_init_rl(&rvlc_rl_inter, ff_mpeg4_static_rl_table_store[1]);
ff_init_rl(&rvlc_rl_intra, ff_mpeg4_static_rl_table_store[2]);
ff_init_rl(&ff_rvlc_rl_inter, ff_mpeg4_static_rl_table_store[1]);
ff_init_rl(&ff_rvlc_rl_intra, ff_mpeg4_static_rl_table_store[2]);
INIT_VLC_RL(ff_mpeg4_rl_intra, 554);
INIT_VLC_RL(rvlc_rl_inter, 1072);
INIT_VLC_RL(rvlc_rl_intra, 1072);
INIT_VLC_RL(ff_rvlc_rl_inter, 1072);
INIT_VLC_RL(ff_rvlc_rl_intra, 1072);
INIT_VLC_STATIC(&dc_lum, DC_VLC_BITS, 10 /* 13 */,
&ff_mpeg4_DCtab_lum[0][1], 2, 1,
&ff_mpeg4_DCtab_lum[0][0], 2, 1, 512);
@ -2218,11 +2218,11 @@ static av_cold int decode_init(AVCodecContext *avctx)
&ff_mpeg4_DCtab_chrom[0][1], 2, 1,
&ff_mpeg4_DCtab_chrom[0][0], 2, 1, 512);
INIT_VLC_STATIC(&sprite_trajectory, SPRITE_TRAJ_VLC_BITS, 15,
&sprite_trajectory_tab[0][1], 4, 2,
&sprite_trajectory_tab[0][0], 4, 2, 128);
&ff_sprite_trajectory_tab[0][1], 4, 2,
&ff_sprite_trajectory_tab[0][0], 4, 2, 128);
INIT_VLC_STATIC(&mb_type_b_vlc, MB_TYPE_B_VLC_BITS, 4,
&mb_type_b_tab[0][1], 2, 1,
&mb_type_b_tab[0][0], 2, 1, 16);
&ff_mb_type_b_tab[0][1], 2, 1,
&ff_mb_type_b_tab[0][0], 2, 1, 16);
}
s->h263_pred = 1;

@ -468,7 +468,7 @@ static inline int get_b_cbp(MpegEncContext * s, DCTELEM block[6][64],
//FIXME this is duplicated to h263.c
static const int dquant_code[5]= {1,0,9,2,3};
void mpeg4_encode_mb(MpegEncContext * s,
void ff_mpeg4_encode_mb(MpegEncContext * s,
DCTELEM block[6][64],
int motion_x, int motion_y)
{
@ -1027,7 +1027,7 @@ static void mpeg4_encode_vol_header(MpegEncContext * s, int vo_number, int vol_n
}
/* write mpeg4 VOP header */
void mpeg4_encode_picture_header(MpegEncContext * s, int picture_number)
void ff_mpeg4_encode_picture_header(MpegEncContext * s, int picture_number)
{
int time_incr;
int time_div, time_mod;

@ -1998,7 +1998,7 @@ static av_always_inline void encode_mb_internal(MpegEncContext *s,
break;
case CODEC_ID_MPEG4:
if (CONFIG_MPEG4_ENCODER)
mpeg4_encode_mb(s, s->block, motion_x, motion_y);
ff_mpeg4_encode_mb(s, s->block, motion_x, motion_y);
break;
case CODEC_ID_MSMPEG4V2:
case CODEC_ID_MSMPEG4V3:
@ -3192,7 +3192,7 @@ static int encode_picture(MpegEncContext *s, int picture_number)
else if (CONFIG_MSMPEG4_ENCODER && s->msmpeg4_version)
msmpeg4_encode_picture_header(s, picture_number);
else if (CONFIG_MPEG4_ENCODER && s->h263_pred)
mpeg4_encode_picture_header(s, picture_number);
ff_mpeg4_encode_picture_header(s, picture_number);
else if (CONFIG_RV10_ENCODER && s->codec_id == CODEC_ID_RV10)
rv10_encode_picture_header(s, picture_number);
else if (CONFIG_RV20_ENCODER && s->codec_id == CODEC_ID_RV20)

@ -1829,7 +1829,7 @@ int ff_msmpeg4_decode_block(MpegEncContext * s, DCTELEM * block,
}
not_coded:
if (s->mb_intra) {
mpeg4_pred_ac(s, block, n, dc_pred_dir);
ff_mpeg4_pred_ac(s, block, n, dc_pred_dir);
if (s->ac_pred) {
i = 63; /* XXX: not optimal */
}

Loading…
Cancel
Save