diff options
author | Anton Khirnov <anton@khirnov.net> | 2012-11-21 21:34:46 +0100 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2013-03-08 07:38:30 +0100 |
commit | 759001c534287a96dc96d1e274665feb7059145d (patch) | |
tree | 6ace9560c20aa30db92067c5b45d7bd86e458d10 /libavcodec/h264.h | |
parent | 6e7b50b4270116ded8b874d76cb7c5b1a0341827 (diff) | |
download | ffmpeg-759001c534287a96dc96d1e274665feb7059145d.tar.gz |
lavc decoders: work with refcounted frames.
Diffstat (limited to 'libavcodec/h264.h')
-rw-r--r-- | libavcodec/h264.h | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/libavcodec/h264.h b/libavcodec/h264.h index e3e28911f5..e33f37e359 100644 --- a/libavcodec/h264.h +++ b/libavcodec/h264.h @@ -266,8 +266,6 @@ typedef struct H264Context { Picture *DPB; Picture *cur_pic_ptr; Picture cur_pic; - int picture_count; - int picture_range_start, picture_range_end; int pixel_shift; ///< 0 for 8-bit H264, 1 for high-bit-depth H264 int chroma_qp[2]; // QPc @@ -621,6 +619,11 @@ typedef struct H264Context { uint8_t *bipred_scratchpad; uint8_t *edge_emu_buffer; int16_t *dc_val_base; + + AVBufferPool *qscale_table_pool; + AVBufferPool *mb_type_pool; + AVBufferPool *motion_val_pool; + AVBufferPool *ref_index_pool; } H264Context; extern const uint8_t ff_h264_chroma_qp[3][QP_MAX_NUM + 1]; ///< One chroma qp table for each supported bit depth (8, 9, 10). @@ -876,7 +879,7 @@ static av_always_inline void write_back_motion_list(H264Context *h, int b_xy, int b8_xy, int mb_type, int list) { - int16_t(*mv_dst)[2] = &h->cur_pic.f.motion_val[list][b_xy]; + int16_t(*mv_dst)[2] = &h->cur_pic.motion_val[list][b_xy]; int16_t(*mv_src)[2] = &h->mv_cache[list][scan8[0]]; AV_COPY128(mv_dst + 0 * b_stride, mv_src + 8 * 0); AV_COPY128(mv_dst + 1 * b_stride, mv_src + 8 * 1); @@ -897,7 +900,7 @@ static av_always_inline void write_back_motion_list(H264Context *h, } { - int8_t *ref_index = &h->cur_pic.f.ref_index[list][b8_xy]; + int8_t *ref_index = &h->cur_pic.ref_index[list][b8_xy]; int8_t *ref_cache = h->ref_cache[list]; ref_index[0 + 0 * 2] = ref_cache[scan8[0]]; ref_index[1 + 0 * 2] = ref_cache[scan8[4]]; @@ -915,7 +918,7 @@ static av_always_inline void write_back_motion(H264Context *h, int mb_type) if (USES_LIST(mb_type, 0)) { write_back_motion_list(h, b_stride, b_xy, b8_xy, mb_type, 0); } else { - fill_rectangle(&h->cur_pic.f.ref_index[0][b8_xy], + fill_rectangle(&h->cur_pic.ref_index[0][b8_xy], 2, 2, 2, (uint8_t)LIST_NOT_USED, 1); } if (USES_LIST(mb_type, 1)) |