1
0
mirror of https://github.com/mpv-player/mpv synced 2024-12-26 17:12:36 +00:00

video: fix display of cover art with vo_vdpau

vo_vdpau currently has a video queue larger than 1 entry, which causes
the video display code to never queue display the video frame. This is
because we consider cover art an endless stream of frames decoded from
the same source packet, and include special logic to actually only
decode and display 1 frame.

Also, make decode_image() also signal EOF in the cover art case.
This commit is contained in:
wm4 2014-05-22 13:50:10 +02:00
parent b37e3cc0ee
commit 2f2b3f8d5c

View File

@ -311,7 +311,7 @@ static int decode_image(struct MPContext *mpctx)
if (d_video->header->attached_picture) {
d_video->waiting_decoded_mpi =
video_decode(d_video, d_video->header->attached_picture, 0);
return 1;
return 0;
}
struct demux_packet *pkt = demux_read_packet(d_video->header);
@ -516,8 +516,10 @@ int update_video(struct MPContext *mpctx, double endpts, bool reconfig_ok,
struct vo *video_out = mpctx->video_out;
if (mpctx->d_video->header->attached_picture) {
if (video_out->hasframe || vo_has_next_frame(video_out, true))
if (video_out->hasframe)
return 0;
if (vo_has_next_frame(video_out, true))
return 2;
}
int r = video_output_image(mpctx, endpts, reconfig_ok);