summaryrefslogtreecommitdiffstats
path: root/video/out
diff options
context:
space:
mode:
authorNiklas Haas <git@haasn.dev>2023-05-27 11:16:06 +0200
committerNiklas Haas <github-daiK1o@haasn.dev>2023-05-27 11:37:48 +0200
commit7595ea7c7c11402e91121bab9c68cd73c720b8a1 (patch)
treea85bd72c7623b0204090a8ee4568d76fa0c5d669 /video/out
parentb216c09ade7b56efb97fe82754b72b1620f67098 (diff)
downloadmpv-7595ea7c7c11402e91121bab9c68cd73c720b8a1.tar.bz2
mpv-7595ea7c7c11402e91121bab9c68cd73c720b8a1.tar.xz
vo_gpu_next: respect `gl->flipped`
This fixes flipped rendering on angle/dxinterop instances.
Diffstat (limited to 'video/out')
-rw-r--r--video/out/gpu_next/context.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/video/out/gpu_next/context.c b/video/out/gpu_next/context.c
index 96f255d448..2887cff938 100644
--- a/video/out/gpu_next/context.c
+++ b/video/out/gpu_next/context.c
@@ -144,12 +144,13 @@ struct gpu_ctx *gpu_ctx_create(struct vo *vo, struct gl_video_opts *gl_opts)
#if HAVE_GL && defined(PL_HAVE_OPENGL)
if (ra_is_gl(ctx->ra_ctx->ra)) {
+ struct GL *gl = ra_gl_get(ctx->ra_ctx->ra);
pl_opengl opengl = pl_opengl_create(ctx->pllog,
pl_opengl_params(
.debug = ctx_opts->debug,
.allow_software = ctx_opts->allow_sw,
- .get_proc_addr_ex = (void *) ra_gl_get(ctx->ra_ctx->ra)->get_fn,
- .proc_ctx = ra_gl_get(ctx->ra_ctx->ra)->fn_ctx,
+ .get_proc_addr_ex = (void *) gl->get_fn,
+ .proc_ctx = gl->fn_ctx,
# if HAVE_EGL
.egl_display = eglGetCurrentDisplay(),
.egl_context = eglGetCurrentContext(),
@@ -164,6 +165,7 @@ struct gpu_ctx *gpu_ctx_create(struct vo *vo, struct gl_video_opts *gl_opts)
ctx->swapchain = pl_opengl_create_swapchain(opengl, pl_opengl_swapchain_params(
.max_swapchain_depth = vo->opts->swapchain_depth,
+ .framebuffer.flipped = gl->flipped,
));
if (!ctx->swapchain)
goto err_out;