summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2019-05-17 13:34:42 +0200
committerwm4 <wm4@nowhere>2019-09-19 20:37:04 +0200
commitd9cc13f3118acea4314a13b8472f1f37e1c04805 (patch)
treee52bf84b91a54f5370e8640e235db3c7bd6eef4f
parenta80f63cb9a889a4fc5f32fb17de5d9e2eedb3e7f (diff)
downloadmpv-d9cc13f3118acea4314a13b8472f1f37e1c04805.tar.bz2
mpv-d9cc13f3118acea4314a13b8472f1f37e1c04805.tar.xz
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.
-rw-r--r--filters/f_decoder_wrapper.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/filters/f_decoder_wrapper.c b/filters/f_decoder_wrapper.c
index 0faaa72bd9..0edca5c83d 100644
--- a/filters/f_decoder_wrapper.c
+++ b/filters/f_decoder_wrapper.c
@@ -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);
}