From aacefa4ae5c6112ee7e98535e377c3806bcec85a Mon Sep 17 00:00:00 2001 From: Dudemanguy Date: Mon, 5 Oct 2020 10:27:44 -0500 Subject: vo_gpu: update render options on runtime vo_gpu has a small set of options for ra_ctx that can be set. In practice, runtime toggling doesn't matter for most of these as they have no effect while a video is playing. However, changing the alpha option during runtime can actually work depending on the backend used. mpv already detected when one of these options changed, but it made no attempt to update the options in the ra_ctx accordingly (likely because nothing made any use of this information). Another related change is to add an update_render_opts to the fns and allow invidiual backends to (optionally) use it. --- video/out/gpu/context.h | 1 + 1 file changed, 1 insertion(+) (limited to 'video/out/gpu') diff --git a/video/out/gpu/context.h b/video/out/gpu/context.h index 4cf2af9e3e..8c35eb0fc0 100644 --- a/video/out/gpu/context.h +++ b/video/out/gpu/context.h @@ -44,6 +44,7 @@ struct ra_ctx_fns { // optional. void (*wakeup)(struct ra_ctx *ctx); void (*wait_events)(struct ra_ctx *ctx, int64_t until_time_us); + void (*update_render_opts)(struct ra_ctx *ctx); // Initialize/destroy the 'struct ra' and possibly the underlying VO backend. // Not normally called by the user of the ra_ctx. -- cgit v1.2.3