From 8b4a995a9d7ee7b65a5d2c893d72844d551d9697 Mon Sep 17 00:00:00 2001 From: Guido Cella Date: Wed, 29 Nov 2023 09:05:18 +0100 Subject: [PATCH] playloop: use a 16:9 ratio with --force-window ca2b05c0fb changed the window size with --force-window and no video tracks to be closer to 16:9, but I don't see why we shouldn't have an actual 16:9 ratio. The advantage is that subtitles with fullscreen and no video tracks will have the same size and position (depending on the values of --sub-scale-with-window and --sub-use-margins) as with 16:9 videos, because there will be no (invisible) black bars. --- player/playloop.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/player/playloop.c b/player/playloop.c index 60596da76d21e..3a10f6faee35b 100644 --- a/player/playloop.c +++ b/player/playloop.c @@ -1030,8 +1030,12 @@ int handle_force_window(struct MPContext *mpctx, bool force) break; } } + + // Use a 16:9 aspect ratio so that fullscreen on a 16:9 screen will not + // have vertical margins, which can lead to a different size or position + // of subtitles than with 16:9 videos. int w = 960; - int h = 480; + int h = 540; struct mp_image_params p = { .imgfmt = config_format, .w = w, .h = h,