diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2014-03-17 13:22:40 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-03-17 13:22:40 +0100 |
commit | 29be9b5301212d29186a05f262a6ce04ddbc168c (patch) | |
tree | 893ee3e5fb5ccf0bbcb751aefb22ad1b3387671b /libavcodec/dxva2_h264.c | |
parent | 2a37e560dccb81328f610c51e74ce6cc53f1a5c7 (diff) | |
download | ffmpeg-29be9b5301212d29186a05f262a6ce04ddbc168c.tar.gz |
avcodec/dxva2: fix pointers after H264Picture
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/dxva2_h264.c')
-rw-r--r-- | libavcodec/dxva2_h264.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libavcodec/dxva2_h264.c b/libavcodec/dxva2_h264.c index 854bfcd38e..30184ab6d1 100644 --- a/libavcodec/dxva2_h264.c +++ b/libavcodec/dxva2_h264.c @@ -51,7 +51,7 @@ static void fill_picture_parameters(struct dxva_context *ctx, const H264Context memset(pp, 0, sizeof(*pp)); /* Configure current picture */ fill_picture_entry(&pp->CurrPic, - ff_dxva2_get_surface_index(ctx, current_picture), + ff_dxva2_get_surface_index(ctx, ¤t_picture->f), h->picture_structure == PICT_BOTTOM_FIELD); /* Configure the set of references */ pp->UsedForReferenceFlags = 0; @@ -67,7 +67,7 @@ static void fill_picture_parameters(struct dxva_context *ctx, const H264Context } if (r) { fill_picture_entry(&pp->RefFrameList[i], - ff_dxva2_get_surface_index(ctx, r), + ff_dxva2_get_surface_index(ctx, &r->f), r->long_ref != 0); if ((r->reference & PICT_TOP_FIELD) && r->field_poc[0] != INT_MAX) @@ -243,9 +243,9 @@ static void fill_slice_long(AVCodecContext *avctx, DXVA_Slice_H264_Long *slice, unsigned plane; unsigned index; if (ctx->workaround & FF_DXVA2_WORKAROUND_INTEL_CLEARVIDEO) - index = ff_dxva2_get_surface_index(ctx, r); + index = ff_dxva2_get_surface_index(ctx, &r->f); else - index = get_refpic_index(pp, ff_dxva2_get_surface_index(ctx, r)); + index = get_refpic_index(pp, ff_dxva2_get_surface_index(ctx, &r->f)); fill_picture_entry(&slice->RefPicList[list][i], index, r->reference == PICT_BOTTOM_FIELD); for (plane = 0; plane < 3; plane++) { @@ -448,7 +448,7 @@ static int dxva2_h264_end_frame(AVCodecContext *avctx) if (ctx_pic->slice_count <= 0 || ctx_pic->bitstream_size <= 0) return -1; - ret = ff_dxva2_common_end_frame(avctx, h->cur_pic_ptr, + ret = ff_dxva2_common_end_frame(avctx, &h->cur_pic_ptr->f, &ctx_pic->pp, sizeof(ctx_pic->pp), &ctx_pic->qm, sizeof(ctx_pic->qm), commit_bitstream_and_slice_buffer); |