diff --git a/copyparty/th_srv.py b/copyparty/th_srv.py index ada1c860..ab851310 100644 --- a/copyparty/th_srv.py +++ b/copyparty/th_srv.py @@ -833,7 +833,7 @@ class ThumbSrv(object): def conv_ffmpeg(self, abspath: str, tpath: str, fmt: str, vn: VFS) -> None: self.wait4ram(0.2, tpath) - ret, _, _, _ = ffprobe(abspath, int(vn.flags["convt"] / 2)) + ret, raw, strms, ctnr = ffprobe(abspath, int(vn.flags["convt"] / 2)) if not ret: return @@ -841,6 +841,13 @@ class ThumbSrv(object): # audio in a video trenchcoat return self.conv_spec(abspath, tpath, fmt, vn) + for strm in strms: + if ( + strm.get("codec_type") == "video" + and strm.get("DISPOSITION:attached_pic") == "1" + ): + return self.conv_emb_cv(abspath, tpath, fmt, vn, strm) + ext = abspath.rsplit(".")[-1].lower() if ext in ["h264", "h265"] or ext in self.fmt_ffi: seek: list[bytes] = []