1
0
mirror of https://github.com/mpv-player/mpv synced 2024-12-28 10:02:17 +00:00

f_decoder_wrapper: move cover art retrieval

This is basically a refactor in preparation for future changes and
shouldn't have much influence on actual behavior.
This commit is contained in:
wm4 2019-05-17 13:34:42 +02:00
parent a80f63cb9a
commit d9cc13f311

View File

@ -580,6 +580,11 @@ static void read_frame(struct priv *p)
if (!frame.type)
return;
if (p->header->attached_picture && frame.type == MP_FRAME_VIDEO) {
p->decoded_coverart = mp_frame_ref(frame);
p->coverart_returned = 1;
}
if (p->public.attempt_framedrops) {
int dropped = MPMAX(0, p->packets_without_output - 1);
p->public.attempt_framedrops =
@ -615,11 +620,6 @@ static void read_frame(struct priv *p)
return;
}
if (p->header->attached_picture && frame.type == MP_FRAME_VIDEO) {
p->decoded_coverart = mp_frame_ref(frame);
p->coverart_returned = 1;
}
mp_pin_in_write(pin, frame);
}