diff options
Diffstat (limited to 'Graphics/GraphicsEngineOpenGL')
| -rw-r--r-- | Graphics/GraphicsEngineOpenGL/src/TextureBaseGL.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Graphics/GraphicsEngineOpenGL/src/TextureBaseGL.cpp b/Graphics/GraphicsEngineOpenGL/src/TextureBaseGL.cpp index 06e49cd6..86b5ef40 100644 --- a/Graphics/GraphicsEngineOpenGL/src/TextureBaseGL.cpp +++ b/Graphics/GraphicsEngineOpenGL/src/TextureBaseGL.cpp @@ -579,7 +579,10 @@ void TextureBaseGL::CopyData(DeviceContextGLImpl* pDeviceCtxGL, } #if GL_ARB_copy_image - if (glCopyImageSubData) + const bool IsDefaultBackBuffer = GetGLHandle() == 0; + // We can't use glCopyImageSubData with the proxy texture of a default framebuffer + // because we don't have the texture handle. Resort to quad rendering in this case. + if (glCopyImageSubData && !IsDefaultBackBuffer) { GLint SrcSliceY = (SrcTexDesc.Type == RESOURCE_DIM_TEX_1D_ARRAY) ? SrcSlice : 0; GLint SrcSliceZ = (SrcTexDesc.Type == RESOURCE_DIM_TEX_2D_ARRAY) ? SrcSlice : 0; |
