From 8a9f004ff683a9e628149c632a7756337a5d8a22 Mon Sep 17 00:00:00 2001 From: Geoffrey McRae Date: Sun, 11 Oct 2020 19:39:47 +1100 Subject: [PATCH] [host/client] fix invalid initialization of RGBA16F --- client/renderers/EGL/texture.c | 2 +- host/platform/Windows/capture/DXGI/src/dxgi.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/client/renderers/EGL/texture.c b/client/renderers/EGL/texture.c index f26a9e54..2b5cf067 100644 --- a/client/renderers/EGL/texture.c +++ b/client/renderers/EGL/texture.c @@ -227,7 +227,7 @@ bool egl_texture_setup(EGL_Texture * texture, enum EGL_PixelFormat pixFmt, size_ texture->planes[0][1] = height; texture->planes[0][2] = stride / 8; texture->offsets[0] = 0; - texture->intFormat = GL_RGB16; + texture->intFormat = GL_RGBA16F; texture->dataType = GL_FLOAT; texture->pboBufferSize = height * stride; break; diff --git a/host/platform/Windows/capture/DXGI/src/dxgi.c b/host/platform/Windows/capture/DXGI/src/dxgi.c index a539c2aa..6781bbb2 100644 --- a/host/platform/Windows/capture/DXGI/src/dxgi.c +++ b/host/platform/Windows/capture/DXGI/src/dxgi.c @@ -482,7 +482,8 @@ static bool dxgi_init() { DXGI_FORMAT_B8G8R8A8_UNORM, DXGI_FORMAT_R8G8B8A8_UNORM, - DXGI_FORMAT_R10G10B10A2_UNORM + DXGI_FORMAT_R10G10B10A2_UNORM, + DXGI_FORMAT_R16G16B16A16_FLOAT }; // we try this twice in case we still get an error on re-initialization