]> OCCT Git - occt-copy.git/commit
0030364: Visualization, TKOpenGl - allow initializing a Surface-less EGL context CR30364_730
authorkgv <kgv@opencascade.com>
Mon, 12 Nov 2018 12:46:40 +0000 (15:46 +0300)
committerkgv <kgv@opencascade.com>
Wed, 5 Dec 2018 14:59:06 +0000 (17:59 +0300)
commitac7e3c5f919fb565eba740c15d6d8c93a04358e1
treee5beedb5a7500202da13c94fe9abfeafa09c1f4c
parent42da0d5115bff683c6b596e66cdeaff957f81e7d
0030364: Visualization, TKOpenGl - allow initializing a Surface-less EGL context

OpenGl_Context::MakeCurrent()/OpenGl_Context::IsCurrent() have been modified to NOT fail
in case if myWindow is EGL_NO_SURFACE (valid off-screen rendering case within EGL).
OpenGl_GraphicDriver::InitEglContext() now finds EGL surface config in case if it has not been passed by argument.

OpenGl_Window constructor now allows wrapping an off-screen rendering surface EGL_NO_SURFACE.
However, it still creates a dummy surface eglCreatePbufferSurface() to workaround bugs in some GLES drivers (Vivante GC2000).

V3d_View::SetWindow()/V3d_View::MustBeResized()/V3d_Viewer::SetViewOn() have been modified
to avoid implicit View redraw (leading to undefined behavior/crashes in case if rendering
should be done into default FBO defined right after V3d_View initialization).
src/OpenGl/OpenGl_Context.cxx
src/OpenGl/OpenGl_GraphicDriver.cxx
src/OpenGl/OpenGl_Window.cxx
src/V3d/V3d_View.cxx
src/V3d/V3d_Viewer.cxx