diff options
author | Kacper Michajłow <kasper93@gmail.com> | 2024-03-16 09:20:25 +0100 |
---|---|---|
committer | Kacper Michajłow <kasper93@gmail.com> | 2024-03-18 21:24:06 +0100 |
commit | cbe30f614d878c2622e86d9c5cd8da558ef16936 (patch) | |
tree | 9c692c5fff178f2f89d9b4c6059c48c400c7ec2e | |
parent | bf1c8acdac5678f5ddbe346cf12477bbc34e8ada (diff) | |
download | mpv-cbe30f614d878c2622e86d9c5cd8da558ef16936.tar.bz2 mpv-cbe30f614d878c2622e86d9c5cd8da558ef16936.tar.xz |
vo_gpu_next: don't render ASS subtitles at HDR colorspace
Upstream ASS specification says that all subtitles should be rendered
with color primaries and transfer matching their associated video. But
as expected after further discussion the decision has been made to
fallback to SDR mode in case of HDR video.
See-Also: https://github.com/libass/libass/blob/649a7c2e1fc6f4188ea1a89968560715800b883d/libass/ass_types.h#L233-L237
See-Also: libass/libass#297
See-Also: mpv-player#13381
Fixes: mpv-player#13673
-rw-r--r-- | video/out/vo_gpu_next.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/video/out/vo_gpu_next.c b/video/out/vo_gpu_next.c index bb512c7b8f..8a11e073cf 100644 --- a/video/out/vo_gpu_next.c +++ b/video/out/vo_gpu_next.c @@ -379,7 +379,7 @@ static void update_overlays(struct vo *vo, struct mp_osd_res res, } break; case SUBBITMAP_LIBASS: - if (src && item->video_color_space) + if (src && item->video_color_space && !pl_color_space_is_hdr(&src->params.color)) ol->color = src->params.color; ol->mode = PL_OVERLAY_MONOCHROME; ol->repr.alpha = PL_ALPHA_INDEPENDENT; |