diff options
Diffstat (limited to 'src/gallium/state_trackers')
-rw-r--r-- | src/gallium/state_trackers/vdpau/decode.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/gallium/state_trackers/vdpau/decode.c b/src/gallium/state_trackers/vdpau/decode.c index 47212e348ed..a5a01fb21a3 100644 --- a/src/gallium/state_trackers/vdpau/decode.c +++ b/src/gallium/state_trackers/vdpau/decode.c @@ -322,7 +322,6 @@ vlVdpDecoderRenderVC1(struct pipe_video_decoder *decoder, { struct pipe_vc1_picture_desc picture; struct pipe_video_buffer *ref_frames[2] = {}; - unsigned i; VDPAU_MSG(VDPAU_TRACE, "[VDPAU] Decoding VC-1\n"); @@ -385,6 +384,8 @@ vlVdpDecoderRender(VdpDecoder decoder, uint32_t bitstream_buffer_count, VdpBitstreamBuffer const *bitstream_buffers) { + const void * buffers[bitstream_buffer_count]; + unsigned sizes[bitstream_buffer_count]; vlVdpDecoder *vldecoder; vlVdpSurface *vlsurf; VdpStatus ret; @@ -435,9 +436,11 @@ vlVdpDecoderRender(VdpDecoder decoder, return ret; dec->begin_frame(dec); - for (i = 0; i < bitstream_buffer_count; ++i) - dec->decode_bitstream(dec, bitstream_buffers[i].bitstream_bytes, - bitstream_buffers[i].bitstream); + for (i = 0; i < bitstream_buffer_count; ++i) { + buffers[i] = bitstream_buffers[i].bitstream; + sizes[i] = bitstream_buffers[i].bitstream_bytes; + } + dec->decode_bitstream(dec, bitstream_buffer_count, buffers, sizes); dec->end_frame(dec); return ret; } |