mirror of https://github.com/mpv-player/mpv
sd_ass: fix font aspect ratio with non-ASS subs
For subtitles that were not ASS, the subtitle font aspect was always set to that of the video, the exact opposite of how it was supposed to behave.
This commit is contained in:
parent
77a00e444f
commit
3d439368a1
|
@ -188,13 +188,13 @@ static void get_bitmaps(struct sd *sd, struct mp_osd_res dim, double pts,
|
|||
if (pts == MP_NOPTS_VALUE || !sd->ass_renderer)
|
||||
return;
|
||||
|
||||
bool use_vs_aspect = !ctx->is_converted &&
|
||||
opts->ass_style_override ? opts->ass_vsfilter_aspect_compat : 1;
|
||||
|
||||
ASS_Renderer *renderer = sd->ass_renderer;
|
||||
double scale = dim.display_par;
|
||||
if (use_vs_aspect)
|
||||
if (!ctx->is_converted && (!opts->ass_style_override ||
|
||||
opts->ass_vsfilter_aspect_compat))
|
||||
{
|
||||
scale = scale * dim.video_par;
|
||||
}
|
||||
mp_ass_configure(renderer, opts, &dim);
|
||||
ass_set_aspect_ratio(renderer, scale, 1);
|
||||
#if LIBASS_VERSION >= 0x01020000
|
||||
|
|
Loading…
Reference in New Issue