Re: [MPlayer-users] [feature request] subtitles in separate window or console
Reimar Döffinger <[email protected]> Sun, 27 Feb 2022 10:42:15 +0100
| Newsgroups | gmane.comp.video.mplayer.devel,gmane.comp.video.mplayer.user |
|---|---|
| Message-ID | <[email protected]> |
> On 1 Feb 2022, at 18:49, Nicolas George <[email protected]> wrote: > > Reimar Döffinger (12022-02-01): >> But it seem a very special feature to add an option or something for it really... > > I agree. > > On the other hand, an option to send the subtitles to -identify output > would rather make sense I thin, and it would allow to implement the > feature easily. Patch to just always send subtitle text to -identify, without extra option. Does that seem reasonable? _______________________________________________ MPlayer-dev-eng mailing list [email protected] https://lists.mplayerhq.hu/mailman/listinfo/mplayer-dev-eng
id_sub_text.diff
(application/octet-stream, 571 B)
Index: mplayer.c
===================================================================
--- mplayer.c (revision 38349)
+++ mplayer.c (working copy)
@@ -1537,6 +1537,12 @@
set_osd_msg(OSD_MSG_SUB_BASE + i, 1, display_time, "%s", subs->text[i]);
}
}
+ }
+ if (!mp_msg_test(MSGT_IDENTIFY, MSGL_V))
+ return;
+ for (i = 0; i < SUB_MAX_TEXT; i++) {
+ const char *txt = !subs || i >= subs->lines || !subs->text[i] ? "" : subs->text[i];
+ mp_msg(MSGT_IDENTIFY, MSGL_V, "ID_SUB_TEXT_%i=%s\n", i, txt);
}
}