Mercurial > libavcodec.hg
comparison mpeg12.c @ 8832:3eaabd9c4371 libavcodec
Remove redundant CONFIG_XVMC option, CONFIG_MPEG_XVMC_DECODER suffices.
author | diego |
---|---|
date | Sat, 14 Feb 2009 15:37:40 +0000 |
parents | 9e7d7122a421 |
children | 6ce8ebfc9d86 |
comparison
equal
deleted
inserted
replaced
8831:27616b326d57 | 8832:3eaabd9c4371 |
---|---|
299 | 299 |
300 skip_bits1(&s->gb); /* marker */ | 300 skip_bits1(&s->gb); /* marker */ |
301 }else | 301 }else |
302 memset(s->last_mv, 0, sizeof(s->last_mv)); /* reset mv prediction */ | 302 memset(s->last_mv, 0, sizeof(s->last_mv)); /* reset mv prediction */ |
303 s->mb_intra = 1; | 303 s->mb_intra = 1; |
304 #if CONFIG_XVMC | 304 #if CONFIG_MPEG_XVMC_DECODER |
305 //if 1, we memcpy blocks in xvmcvideo | 305 //if 1, we memcpy blocks in xvmcvideo |
306 if(s->avctx->xvmc_acceleration > 1){ | 306 if(s->avctx->xvmc_acceleration > 1){ |
307 XVMC_pack_pblocks(s,-1);//inter are always full blocks | 307 XVMC_pack_pblocks(s,-1);//inter are always full blocks |
308 if(s->swap_uv){ | 308 if(s->swap_uv){ |
309 exchange_uv(s); | 309 exchange_uv(s); |
512 if (cbp <= 0){ | 512 if (cbp <= 0){ |
513 av_log(s->avctx, AV_LOG_ERROR, "invalid cbp at %d %d\n", s->mb_x, s->mb_y); | 513 av_log(s->avctx, AV_LOG_ERROR, "invalid cbp at %d %d\n", s->mb_x, s->mb_y); |
514 return -1; | 514 return -1; |
515 } | 515 } |
516 | 516 |
517 #if CONFIG_XVMC | 517 #if CONFIG_MPEG_XVMC_DECODER |
518 //if 1, we memcpy blocks in xvmcvideo | 518 //if 1, we memcpy blocks in xvmcvideo |
519 if(s->avctx->xvmc_acceleration > 1){ | 519 if(s->avctx->xvmc_acceleration > 1){ |
520 XVMC_pack_pblocks(s,cbp); | 520 XVMC_pack_pblocks(s,cbp); |
521 if(s->swap_uv){ | 521 if(s->swap_uv){ |
522 exchange_uv(s); | 522 exchange_uv(s); |
1646 if(s->picture_structure == PICT_BOTTOM_FIELD){ | 1646 if(s->picture_structure == PICT_BOTTOM_FIELD){ |
1647 s->current_picture.data[i] += s->current_picture_ptr->linesize[i]; | 1647 s->current_picture.data[i] += s->current_picture_ptr->linesize[i]; |
1648 } | 1648 } |
1649 } | 1649 } |
1650 } | 1650 } |
1651 #if CONFIG_XVMC | 1651 #if CONFIG_MPEG_XVMC_DECODER |
1652 // MPV_frame_start will call this function too, | 1652 // MPV_frame_start will call this function too, |
1653 // but we need to call it on every field | 1653 // but we need to call it on every field |
1654 if(s->avctx->xvmc_acceleration) | 1654 if(s->avctx->xvmc_acceleration) |
1655 XVMC_field_start(s,avctx); | 1655 XVMC_field_start(s,avctx); |
1656 #endif | 1656 #endif |
1737 s->q_scale_type, s->intra_vlc_format, s->repeat_first_field, s->chroma_420_type ? "420" :""); | 1737 s->q_scale_type, s->intra_vlc_format, s->repeat_first_field, s->chroma_420_type ? "420" :""); |
1738 } | 1738 } |
1739 } | 1739 } |
1740 | 1740 |
1741 for(;;) { | 1741 for(;;) { |
1742 #if CONFIG_XVMC | 1742 #if CONFIG_MPEG_XVMC_DECODER |
1743 //If 1, we memcpy blocks in xvmcvideo. | 1743 //If 1, we memcpy blocks in xvmcvideo. |
1744 if(s->avctx->xvmc_acceleration > 1) | 1744 if(s->avctx->xvmc_acceleration > 1) |
1745 XVMC_init_block(s);//set s->block | 1745 XVMC_init_block(s);//set s->block |
1746 #endif | 1746 #endif |
1747 | 1747 |
1919 MpegEncContext *s = &s1->mpeg_enc_ctx; | 1919 MpegEncContext *s = &s1->mpeg_enc_ctx; |
1920 | 1920 |
1921 if (!s1->mpeg_enc_ctx_allocated || !s->current_picture_ptr) | 1921 if (!s1->mpeg_enc_ctx_allocated || !s->current_picture_ptr) |
1922 return 0; | 1922 return 0; |
1923 | 1923 |
1924 #if CONFIG_XVMC | 1924 #if CONFIG_MPEG_XVMC_DECODER |
1925 if(s->avctx->xvmc_acceleration) | 1925 if(s->avctx->xvmc_acceleration) |
1926 XVMC_field_end(s); | 1926 XVMC_field_end(s); |
1927 #endif | 1927 #endif |
1928 /* end of slice reached */ | 1928 /* end of slice reached */ |
1929 if (/*s->mb_y<<field_pic == s->mb_height &&*/ !s->first_field) { | 1929 if (/*s->mb_y<<field_pic == s->mb_height &&*/ !s->first_field) { |
2485 CODEC_CAP_DRAW_HORIZ_BAND | CODEC_CAP_DR1 | CODEC_CAP_TRUNCATED | CODEC_CAP_DELAY, | 2485 CODEC_CAP_DRAW_HORIZ_BAND | CODEC_CAP_DR1 | CODEC_CAP_TRUNCATED | CODEC_CAP_DELAY, |
2486 .flush= ff_mpeg_flush, | 2486 .flush= ff_mpeg_flush, |
2487 .long_name= NULL_IF_CONFIG_SMALL("MPEG-1 video"), | 2487 .long_name= NULL_IF_CONFIG_SMALL("MPEG-1 video"), |
2488 }; | 2488 }; |
2489 | 2489 |
2490 #if CONFIG_XVMC | 2490 #if CONFIG_MPEG_XVMC_DECODER |
2491 static av_cold int mpeg_mc_decode_init(AVCodecContext *avctx){ | 2491 static av_cold int mpeg_mc_decode_init(AVCodecContext *avctx){ |
2492 Mpeg1Context *s; | 2492 Mpeg1Context *s; |
2493 | 2493 |
2494 if( avctx->thread_count > 1) | 2494 if( avctx->thread_count > 1) |
2495 return -1; | 2495 return -1; |