Mercurial > libavcodec.hg
comparison mpegvideo.c @ 189:42552c1cf360 libavcodec
fix different UMV handling for mpeg4 vs. h263 - patch by Michael Niedermayer <michaelni@gmx.at>
author | uid46427 |
---|---|
date | Thu, 10 Jan 2002 00:46:40 +0000 |
parents | 3f3b14d3a23d |
children | 883f184537e6 |
comparison
equal
deleted
inserted
replaced
188:5d56c2f7e712 | 189:42552c1cf360 |
---|---|
401 /* generic function for encode/decode called after a frame has been coded/decoded */ | 401 /* generic function for encode/decode called after a frame has been coded/decoded */ |
402 void MPV_frame_end(MpegEncContext *s) | 402 void MPV_frame_end(MpegEncContext *s) |
403 { | 403 { |
404 /* draw edge for correct motion prediction if outside */ | 404 /* draw edge for correct motion prediction if outside */ |
405 if (s->pict_type != B_TYPE) { | 405 if (s->pict_type != B_TYPE) { |
406 #if 1 | 406 if(s->avctx->codec->id!=CODEC_ID_MPEG4){ |
407 draw_edges(s->current_picture[0], s->linesize, s->mb_width*16, s->mb_height*16, EDGE_WIDTH); | 407 draw_edges(s->current_picture[0], s->linesize, s->mb_width*16, s->mb_height*16, EDGE_WIDTH); |
408 draw_edges(s->current_picture[1], s->linesize/2, s->mb_width*8, s->mb_height*8, EDGE_WIDTH/2); | 408 draw_edges(s->current_picture[1], s->linesize/2, s->mb_width*8, s->mb_height*8, EDGE_WIDTH/2); |
409 draw_edges(s->current_picture[2], s->linesize/2, s->mb_width*8, s->mb_height*8, EDGE_WIDTH/2); | 409 draw_edges(s->current_picture[2], s->linesize/2, s->mb_width*8, s->mb_height*8, EDGE_WIDTH/2); |
410 #else | 410 }else{ |
411 /* OpenDivx, but i dunno how to distinguish it from mpeg4 */ | |
411 draw_edges(s->current_picture[0], s->linesize, s->width, s->height, EDGE_WIDTH); | 412 draw_edges(s->current_picture[0], s->linesize, s->width, s->height, EDGE_WIDTH); |
412 draw_edges(s->current_picture[1], s->linesize/2, s->width/2, s->height/2, EDGE_WIDTH/2); | 413 draw_edges(s->current_picture[1], s->linesize/2, s->width/2, s->height/2, EDGE_WIDTH/2); |
413 draw_edges(s->current_picture[2], s->linesize/2, s->width/2, s->height/2, EDGE_WIDTH/2); | 414 draw_edges(s->current_picture[2], s->linesize/2, s->width/2, s->height/2, EDGE_WIDTH/2); |
414 #endif | 415 } |
415 } | 416 } |
416 } | 417 } |
417 | 418 |
418 int MPV_encode_picture(AVCodecContext *avctx, | 419 int MPV_encode_picture(AVCodecContext *avctx, |
419 unsigned char *buf, int buf_size, void *data) | 420 unsigned char *buf, int buf_size, void *data) |