summaryrefslogtreecommitdiff
path: root/libavcodec/h263.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2002-07-25 20:22:36 +0000
committerMichael Niedermayer <michaelni@gmx.at>2002-07-25 20:22:36 +0000
commitb5a093b3a9f22f559a6c40f8e8a33efa16da269d (patch)
tree5f57d0af84907a41906551ab033216f9254aa7ed /libavcodec/h263.c
parentbc4a1ffe96f544b0380431d7c9fc4c997d01e065 (diff)
different edge positions fixed with edge emu / dr1
Originally committed as revision 814 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/h263.c')
-rw-r--r--libavcodec/h263.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/libavcodec/h263.c b/libavcodec/h263.c
index fdebcab47a..3b183830b9 100644
--- a/libavcodec/h263.c
+++ b/libavcodec/h263.c
@@ -1348,6 +1348,8 @@ void mpeg4_encode_picture_header(MpegEncContext * s, int picture_number)
s->y_dc_scale_table= ff_mpeg4_y_dc_scale_table; //FIXME add short header support
s->c_dc_scale_table= ff_mpeg4_c_dc_scale_table;
+ s->h_edge_pos= s->width;
+ s->v_edge_pos= s->height;
}
static void h263_dc_scale(MpegEncContext * s)
@@ -3851,11 +3853,15 @@ int mpeg4_decode_picture_header(MpegEncContext * s)
printf("Error, header damaged or not MPEG4 header (f_code=0)\n");
return -1; // makes no sense to continue, as the MV decoding will break very quickly
}
- }
+ }else
+ s->f_code=1;
+
if (s->pict_type == B_TYPE) {
s->b_code = get_bits(&s->gb, 3);
//printf("b-code %d\n", s->b_code);
- }
+ }else
+ s->b_code=1;
+
//printf("quant:%d fcode:%d bcode:%d type:%d\n", s->qscale, s->f_code, s->b_code, s->pict_type);
if(!s->scalability){
if (s->shape!=RECT_SHAPE && s->pict_type!=I_TYPE) {
@@ -3884,6 +3890,10 @@ int mpeg4_decode_picture_header(MpegEncContext * s)
s->y_dc_scale_table= ff_mpeg4_y_dc_scale_table; //FIXME add short header support
s->c_dc_scale_table= ff_mpeg4_c_dc_scale_table;
+ if(s->divx_version==0 || s->divx_version < 500){
+ s->h_edge_pos= s->width;
+ s->v_edge_pos= s->height;
+ }
return 0;
}