summaryrefslogtreecommitdiff
path: root/libavcodec/dxva2_h264.c
diff options
context:
space:
mode:
authorDiego Biurrun <diego@biurrun.de>2014-08-15 20:51:01 +0200
committerDiego Biurrun <diego@biurrun.de>2014-09-01 12:23:58 +0200
commit4600a85eaa6182e5a27464f6b9cae5a9ddbf3098 (patch)
tree682c6ff54f212fd5dcc6629c06102f772f51dc61 /libavcodec/dxva2_h264.c
parent37c46743ee42df1d6986ba3c996e3af5b95511f7 (diff)
dxva2: Pass variable of correct type to IDirectXVideoDecoder_GetBuffer()
This avoids related incompatible pointer type warnings.
Diffstat (limited to 'libavcodec/dxva2_h264.c')
-rw-r--r--libavcodec/dxva2_h264.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/libavcodec/dxva2_h264.c b/libavcodec/dxva2_h264.c
index fa205c42d7..4132cd7ed9 100644
--- a/libavcodec/dxva2_h264.c
+++ b/libavcodec/dxva2_h264.c
@@ -297,6 +297,7 @@ static int commit_bitstream_and_slice_buffer(AVCodecContext *avctx,
const H264Picture *current_picture = h->cur_pic_ptr;
struct dxva2_picture_context *ctx_pic = current_picture->hwaccel_picture_private;
DXVA_Slice_H264_Short *slice = NULL;
+ void *dxva_data_ptr;
uint8_t *dxva_data, *current, *end;
unsigned dxva_size;
void *slice_data;
@@ -306,9 +307,11 @@ static int commit_bitstream_and_slice_buffer(AVCodecContext *avctx,
/* Create an annex B bitstream buffer with only slice NAL and finalize slice */
if (FAILED(IDirectXVideoDecoder_GetBuffer(ctx->decoder,
- DXVA2_BitStreamDateBufferType,
- &dxva_data, &dxva_size)))
+ DXVA2_BitStreamDateBufferType,
+ &dxva_data_ptr, &dxva_size)))
return -1;
+
+ dxva_data = dxva_data_ptr;
current = dxva_data;
end = dxva_data + dxva_size;