Mercurial > mplayer.hg
changeset 28723:68893c41ae26
Handle vdp_decoder_create failures better, in particular avoid unrelated
error messages and retry creating a decoder.
author | reimar |
---|---|
date | Sat, 28 Feb 2009 10:43:28 +0000 |
parents | 5f24919c13ef |
children | 307da077861c |
files | libvo/vo_vdpau.c |
diffstat | 1 files changed, 5 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/libvo/vo_vdpau.c Sat Feb 28 10:06:52 2009 +0000 +++ b/libvo/vo_vdpau.c Sat Feb 28 10:43:28 2009 +0000 @@ -785,6 +785,11 @@ } vdp_st = vdp_decoder_create(vdp_device, vdp_decoder_profile, vid_width, vid_height, max_refs, &decoder); CHECK_ST_WARNING("Failed creating VDPAU decoder"); + if (vdp_st != VDP_STATUS_OK) { + decoder = VDP_INVALID_HANDLE; + decoder_max_refs = 0; + return VO_FALSE; + } decoder_max_refs = max_refs; } vdp_st = vdp_decoder_render(decoder, rndr->surface, (void *)&rndr->info, rndr->bitstream_buffers_used, rndr->bitstream_buffers);