Mercurial > libavcodec.hg
comparison h264.c @ 11047:ec682347e19e libavcodec
Export H264 profile and level in AVCodecContext.
Patch by Rafa¸«³l Carr¸«±, rafael D carre A gmail
author | cehoyos |
---|---|
date | Thu, 28 Jan 2010 20:57:29 +0000 |
parents | b37a53d101c3 |
children | 4a95670ed5f1 |
comparison
equal
deleted
inserted
replaced
11046:15add32dd717 | 11047:ec682347e19e |
---|---|
2525 hx->s.data_partitioning = 0; | 2525 hx->s.data_partitioning = 0; |
2526 | 2526 |
2527 if((err = decode_slice_header(hx, h))) | 2527 if((err = decode_slice_header(hx, h))) |
2528 break; | 2528 break; |
2529 | 2529 |
2530 avctx->profile = hx->sps.profile_idc; | |
2531 avctx->level = hx->sps.level_idc; | |
2532 | |
2530 if (s->avctx->hwaccel && h->current_slice == 1) { | 2533 if (s->avctx->hwaccel && h->current_slice == 1) { |
2531 if (s->avctx->hwaccel->start_frame(s->avctx, NULL, 0) < 0) | 2534 if (s->avctx->hwaccel->start_frame(s->avctx, NULL, 0) < 0) |
2532 return -1; | 2535 return -1; |
2533 } | 2536 } |
2534 | 2537 |
2557 hx->intra_gb_ptr= | 2560 hx->intra_gb_ptr= |
2558 hx->inter_gb_ptr= NULL; | 2561 hx->inter_gb_ptr= NULL; |
2559 | 2562 |
2560 if ((err = decode_slice_header(hx, h)) < 0) | 2563 if ((err = decode_slice_header(hx, h)) < 0) |
2561 break; | 2564 break; |
2565 | |
2566 avctx->profile = hx->sps.profile_idc; | |
2567 avctx->level = hx->sps.level_idc; | |
2562 | 2568 |
2563 hx->s.data_partitioning = 1; | 2569 hx->s.data_partitioning = 1; |
2564 | 2570 |
2565 break; | 2571 break; |
2566 case NAL_DPB: | 2572 case NAL_DPB: |