summaryrefslogtreecommitdiff
path: root/libavcodec/ituh263dec.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2012-02-16 00:49:16 +0100
committerMichael Niedermayer <michaelni@gmx.at>2012-02-16 01:34:37 +0100
commit6cb2085278bdd3ee83d5ed528d98c78756ee7277 (patch)
treeda57b6491e07c2deb9cf57e3cd595323d118c244 /libavcodec/ituh263dec.c
parent8812c97b98321f82763b7c9c1363c7c1f6cace8f (diff)
parent210f72845c11fbab7b913a4f18ffd67e99d2dd4f (diff)
Merge remote-tracking branch 'qatar/master'
* qatar/master: (27 commits) ppc: Add ff_ prefix to nonstatic symbols sh4: Add ff_ prefix to nonstatic symbols mpegvideo: Add ff_ prefix to nonstatic functions rtjpeg: Add ff_ prefix to nonstatic symbols rv: Add ff_ prefix to nonstatic symbols vp56: Add ff_ prefix to nonstatic symbols vorbis: Add ff_ prefix to nonstatic symbols msmpeg4: Add ff_ prefix to nonstatic symbols vc1: Add ff_ prefix to nonstatic symbols msmpeg4: Add ff_ prefixes to nonstatic symbols snow: Add ff_ prefix to nonstatic symbols mpeg12: Add ff_ prefix to nonstatic symbols mpeg4: Add ff_ prefixes to nonstatic symbols lagarith: Add ff_ prefix to lag_rac_init libavcodec: Add ff_ prefix to j_rev_dct* dsputil: Add ff_ prefix to inv_zigzag_direct16 libavcodec: Prefix fdct_ifast, fdct_ifast248 dsputil: Add ff_ prefix to the dsputil*_init* functions libavcodec: Add ff_ prefix to some nonstatic symbols vlc/rl: Add ff_ prefix to the nonstatic symbols ... Conflicts: libavcodec/Makefile libavcodec/allcodecs.c libavcodec/dnxhddec.c libavcodec/ffv1.c libavcodec/h263.h libavcodec/h263dec.c libavcodec/h264.c libavcodec/mpegvideo.c libavcodec/mpegvideo_enc.c libavcodec/nuv.c libavcodec/ppc/dsputil_ppc.c libavcodec/proresdsp.c libavcodec/svq3.c libavcodec/version.h libavformat/dv.h libavformat/dvenc.c libavformat/matroskadec.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/ituh263dec.c')
-rw-r--r--libavcodec/ituh263dec.c86
1 files changed, 43 insertions, 43 deletions
diff --git a/libavcodec/ituh263dec.c b/libavcodec/ituh263dec.c
index f058c9b848..e92af33eaf 100644
--- a/libavcodec/ituh263dec.c
+++ b/libavcodec/ituh263dec.c
@@ -103,7 +103,7 @@ static VLC cbpc_b_vlc;
/* init vlcs */
/* XXX: find a better solution to handle static init */
-void h263_decode_init_vlc(MpegEncContext *s)
+void ff_h263_decode_init_vlc(MpegEncContext *s)
{
static int done = 0;
@@ -120,18 +120,18 @@ void h263_decode_init_vlc(MpegEncContext *s)
&ff_h263_cbpy_tab[0][1], 2, 1,
&ff_h263_cbpy_tab[0][0], 2, 1, 64);
INIT_VLC_STATIC(&mv_vlc, MV_VLC_BITS, 33,
- &mvtab[0][1], 2, 1,
- &mvtab[0][0], 2, 1, 538);
- init_rl(&ff_h263_rl_inter, ff_h263_static_rl_table_store[0]);
- init_rl(&rl_intra_aic, ff_h263_static_rl_table_store[1]);
+ &ff_mvtab[0][1], 2, 1,
+ &ff_mvtab[0][0], 2, 1, 538);
+ ff_init_rl(&ff_h263_rl_inter, ff_h263_static_rl_table_store[0]);
+ ff_init_rl(&ff_rl_intra_aic, ff_h263_static_rl_table_store[1]);
INIT_VLC_RL(ff_h263_rl_inter, 554);
- INIT_VLC_RL(rl_intra_aic, 554);
+ INIT_VLC_RL(ff_rl_intra_aic, 554);
INIT_VLC_STATIC(&h263_mbtype_b_vlc, H263_MBTYPE_B_VLC_BITS, 15,
- &h263_mbtype_b_tab[0][1], 2, 1,
- &h263_mbtype_b_tab[0][0], 2, 1, 80);
+ &ff_h263_mbtype_b_tab[0][1], 2, 1,
+ &ff_h263_mbtype_b_tab[0][0], 2, 1, 80);
INIT_VLC_STATIC(&cbpc_b_vlc, CBPC_B_VLC_BITS, 4,
- &cbpc_b_tab[0][1], 2, 1,
- &cbpc_b_tab[0][0], 2, 1, 8);
+ &ff_cbpc_b_tab[0][1], 2, 1,
+ &ff_cbpc_b_tab[0][0], 2, 1, 8);
}
}
@@ -240,7 +240,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)
@@ -257,7 +257,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)
@@ -271,7 +271,7 @@ int ff_h263_resync(MpegEncContext *s){
return -1;
}
-int h263_decode_motion(MpegEncContext * s, int pred, int f_code)
+int ff_h263_decode_motion(MpegEncContext * s, int pred, int f_code)
{
int code, val, sign, shift;
code = get_vlc2(&s->gb, mv_vlc.table, MV_VLC_BITS, 2);
@@ -381,16 +381,16 @@ static void preview_obmc(MpegEncContext *s){
if ((cbpc & 16) == 0) {
s->current_picture.f.mb_type[xy] = MB_TYPE_16x16 | MB_TYPE_L0;
/* 16x16 motion prediction */
- mot_val= h263_pred_motion(s, 0, 0, &pred_x, &pred_y);
+ mot_val= ff_h263_pred_motion(s, 0, 0, &pred_x, &pred_y);
if (s->umvplus)
mx = h263p_decode_umotion(s, pred_x);
else
- mx = h263_decode_motion(s, pred_x, 1);
+ mx = ff_h263_decode_motion(s, pred_x, 1);
if (s->umvplus)
my = h263p_decode_umotion(s, pred_y);
else
- my = h263_decode_motion(s, pred_y, 1);
+ my = ff_h263_decode_motion(s, pred_y, 1);
mot_val[0 ]= mot_val[2 ]=
mot_val[0+stride]= mot_val[2+stride]= mx;
@@ -399,16 +399,16 @@ static void preview_obmc(MpegEncContext *s){
} else {
s->current_picture.f.mb_type[xy] = MB_TYPE_8x8 | MB_TYPE_L0;
for(i=0;i<4;i++) {
- mot_val = h263_pred_motion(s, i, 0, &pred_x, &pred_y);
+ mot_val = ff_h263_pred_motion(s, i, 0, &pred_x, &pred_y);
if (s->umvplus)
mx = h263p_decode_umotion(s, pred_x);
else
- mx = h263_decode_motion(s, pred_x, 1);
+ mx = ff_h263_decode_motion(s, pred_x, 1);
if (s->umvplus)
my = h263p_decode_umotion(s, pred_y);
else
- my = h263_decode_motion(s, pred_y, 1);
+ my = ff_h263_decode_motion(s, pred_y, 1);
if (s->umvplus && (mx - pred_x) == 1 && (my - pred_y) == 1)
skip_bits1(&s->gb); /* Bit stuffing to prevent PSC */
mot_val[0] = mx;
@@ -432,7 +432,7 @@ static void h263_decode_dquant(MpegEncContext *s){
if(s->modified_quant){
if(get_bits1(&s->gb))
- s->qscale= modified_quant_tab[get_bits1(&s->gb)][ s->qscale ];
+ s->qscale= ff_modified_quant_tab[get_bits1(&s->gb)][ s->qscale ];
else
s->qscale= get_bits(&s->gb, 5);
}else
@@ -450,7 +450,7 @@ static int h263_decode_block(MpegEncContext * s, DCTELEM * block,
scan_table = s->intra_scantable.permutated;
if (s->h263_aic && s->mb_intra) {
- rl = &rl_intra_aic;
+ rl = &ff_rl_intra_aic;
i = 0;
if (s->ac_pred) {
if (s->h263_aic_dir)
@@ -467,7 +467,7 @@ static int h263_decode_block(MpegEncContext * s, DCTELEM * block,
component = (n <= 3 ? 0 : n - 4 + 1);
level = s->last_dc[component];
if (s->rv10_first_dc_coded[component]) {
- diff = rv_decode_dc(s, n);
+ diff = ff_rv_decode_dc(s, n);
if (diff == 0xffff)
return -1;
level += diff;
@@ -539,7 +539,7 @@ retry:
if (i >= 64){
if(s->alt_inter_vlc && rl == &ff_h263_rl_inter && !s->mb_intra){
//Looks like a hack but no, it's the way it is supposed to work ...
- rl = &rl_intra_aic;
+ rl = &ff_rl_intra_aic;
i = 0;
s->gb= gb;
s->dsp.clear_block(block);
@@ -556,7 +556,7 @@ retry:
}
not_coded:
if (s->mb_intra && s->h263_aic) {
- h263_pred_acdc(s, block, n);
+ ff_h263_pred_acdc(s, block, n);
i = 63;
}
s->block_last_index[n] = i;
@@ -655,11 +655,11 @@ int ff_h263_decode_mb(MpegEncContext *s,
s->current_picture.f.mb_type[xy] = MB_TYPE_16x16 | MB_TYPE_L0;
/* 16x16 motion prediction */
s->mv_type = MV_TYPE_16X16;
- h263_pred_motion(s, 0, 0, &pred_x, &pred_y);
+ ff_h263_pred_motion(s, 0, 0, &pred_x, &pred_y);
if (s->umvplus)
mx = h263p_decode_umotion(s, pred_x);
else
- mx = h263_decode_motion(s, pred_x, 1);
+ mx = ff_h263_decode_motion(s, pred_x, 1);
if (mx >= 0xffff)
return -1;
@@ -667,7 +667,7 @@ int ff_h263_decode_mb(MpegEncContext *s,
if (s->umvplus)
my = h263p_decode_umotion(s, pred_y);
else
- my = h263_decode_motion(s, pred_y, 1);
+ my = ff_h263_decode_motion(s, pred_y, 1);
if (my >= 0xffff)
return -1;
@@ -680,18 +680,18 @@ int ff_h263_decode_mb(MpegEncContext *s,
s->current_picture.f.mb_type[xy] = MB_TYPE_8x8 | MB_TYPE_L0;
s->mv_type = MV_TYPE_8X8;
for(i=0;i<4;i++) {
- mot_val = h263_pred_motion(s, i, 0, &pred_x, &pred_y);
+ mot_val = ff_h263_pred_motion(s, i, 0, &pred_x, &pred_y);
if (s->umvplus)
mx = h263p_decode_umotion(s, pred_x);
else
- mx = h263_decode_motion(s, pred_x, 1);
+ mx = ff_h263_decode_motion(s, pred_x, 1);
if (mx >= 0xffff)
return -1;
if (s->umvplus)
my = h263p_decode_umotion(s, pred_y);
else
- my = h263_decode_motion(s, pred_y, 1);
+ my = ff_h263_decode_motion(s, pred_y, 1);
if (my >= 0xffff)
return -1;
s->mv[0][i][0] = mx;
@@ -763,11 +763,11 @@ int ff_h263_decode_mb(MpegEncContext *s,
//FIXME UMV
if(USES_LIST(mb_type, 0)){
- int16_t *mot_val= h263_pred_motion(s, 0, 0, &mx, &my);
+ int16_t *mot_val= ff_h263_pred_motion(s, 0, 0, &mx, &my);
s->mv_dir = MV_DIR_FORWARD;
- mx = h263_decode_motion(s, mx, 1);
- my = h263_decode_motion(s, my, 1);
+ mx = ff_h263_decode_motion(s, mx, 1);
+ my = ff_h263_decode_motion(s, my, 1);
s->mv[0][0][0] = mx;
s->mv[0][0][1] = my;
@@ -776,11 +776,11 @@ int ff_h263_decode_mb(MpegEncContext *s,
}
if(USES_LIST(mb_type, 1)){
- int16_t *mot_val= h263_pred_motion(s, 0, 1, &mx, &my);
+ int16_t *mot_val= ff_h263_pred_motion(s, 0, 1, &mx, &my);
s->mv_dir |= MV_DIR_BACKWARD;
- mx = h263_decode_motion(s, mx, 1);
- my = h263_decode_motion(s, my, 1);
+ mx = ff_h263_decode_motion(s, mx, 1);
+ my = ff_h263_decode_motion(s, my, 1);
s->mv[1][0][0] = mx;
s->mv[1][0][1] = my;
@@ -831,8 +831,8 @@ intra:
}
while(pb_mv_count--){
- h263_decode_motion(s, 0, 1);
- h263_decode_motion(s, 0, 1);
+ ff_h263_decode_motion(s, 0, 1);
+ ff_h263_decode_motion(s, 0, 1);
}
/* decode each block */
@@ -866,7 +866,7 @@ end:
}
/* most is hardcoded. should extend to handle all h263 streams */
-int h263_decode_picture_header(MpegEncContext *s)
+int ff_h263_decode_picture_header(MpegEncContext *s)
{
int format, width, height, i;
uint32_t startcode;
@@ -918,8 +918,8 @@ int h263_decode_picture_header(MpegEncContext *s)
if (format != 7 && format != 6) {
s->h263_plus = 0;
/* H.263v1 */
- width = h263_format[format][0];
- height = h263_format[format][1];
+ width = ff_h263_format[format][0];
+ height = ff_h263_format[format][1];
if (!width)
return -1;
@@ -1026,8 +1026,8 @@ int h263_decode_picture_header(MpegEncContext *s)
s->avctx->sample_aspect_ratio= ff_h263_pixel_aspect[s->aspect_ratio_info];
}
} else {
- width = h263_format[format][0];
- height = h263_format[format][1];
+ width = ff_h263_format[format][0];
+ height = ff_h263_format[format][1];
s->avctx->sample_aspect_ratio= (AVRational){12,11};
}
if ((width == 0) || (height == 0))