mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-10 18:51:21 +03:00
0032302: Visualization, TKOpenGles - do not use window buffer by default
OpenGl_Caps::useSystemBuffer is now set to FALSE on both OpenGL and OpenGL ES. OpenGl_Caps::buffersNoSwap and OpenGl_Caps::buffersOpaqueAlpha are now set to TRUE by default on WebGL.
This commit is contained in:
parent
87b68a0fd6
commit
d85cd274c4
@ -31,23 +31,14 @@ OpenGl_Caps::OpenGl_Caps()
|
|||||||
keepArrayData (Standard_False),
|
keepArrayData (Standard_False),
|
||||||
ffpEnable (Standard_False),
|
ffpEnable (Standard_False),
|
||||||
usePolygonMode (Standard_False),
|
usePolygonMode (Standard_False),
|
||||||
#if !defined(GL_ES_VERSION_2_0)
|
|
||||||
useSystemBuffer (Standard_False),
|
useSystemBuffer (Standard_False),
|
||||||
#else
|
|
||||||
useSystemBuffer (Standard_True),
|
|
||||||
#endif
|
|
||||||
swapInterval (1),
|
swapInterval (1),
|
||||||
useZeroToOneDepth (Standard_False),
|
useZeroToOneDepth (Standard_False),
|
||||||
buffersNoSwap (Standard_False),
|
buffersNoSwap (Standard_False),
|
||||||
buffersOpaqueAlpha(Standard_False),
|
buffersOpaqueAlpha(Standard_False),
|
||||||
contextStereo (Standard_False),
|
contextStereo (Standard_False),
|
||||||
#ifdef OCCT_DEBUG
|
|
||||||
contextDebug (Standard_True),
|
|
||||||
contextSyncDebug (Standard_True),
|
|
||||||
#else
|
|
||||||
contextDebug (Standard_False),
|
contextDebug (Standard_False),
|
||||||
contextSyncDebug (Standard_False),
|
contextSyncDebug (Standard_False),
|
||||||
#endif
|
|
||||||
contextNoAccel (Standard_False),
|
contextNoAccel (Standard_False),
|
||||||
#if !defined(GL_ES_VERSION_2_0)
|
#if !defined(GL_ES_VERSION_2_0)
|
||||||
contextCompatible (Standard_True),
|
contextCompatible (Standard_True),
|
||||||
@ -62,7 +53,14 @@ OpenGl_Caps::OpenGl_Caps()
|
|||||||
suppressExtraMsg (Standard_True),
|
suppressExtraMsg (Standard_True),
|
||||||
glslDumpLevel (OpenGl_ShaderProgramDumpLevel_Off)
|
glslDumpLevel (OpenGl_ShaderProgramDumpLevel_Off)
|
||||||
{
|
{
|
||||||
//
|
#if defined(__EMSCRIPTEN__)
|
||||||
|
buffersNoSwap = true; // swap has no effect in WebGL
|
||||||
|
buffersOpaqueAlpha = true; // avoid unexpected blending of canvas with page background
|
||||||
|
#endif
|
||||||
|
#ifdef OCCT_DEBUG
|
||||||
|
contextDebug = true;
|
||||||
|
contextSyncDebug = true;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
// =======================================================================
|
// =======================================================================
|
||||||
|
Loading…
x
Reference in New Issue
Block a user