1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-29 14:00:49 +03:00

0026454: Visualization, TKOpenGl - do not require deprecated function of GL_ARB_vertex_type_2_10_10_10_rev in core profile

This commit is contained in:
kgv
2015-07-17 11:17:45 +03:00
committed by bugmaster
parent 3ceb4c3c7e
commit 0e628baf3e
2 changed files with 18 additions and 40 deletions

View File

@@ -1639,7 +1639,21 @@ void OpenGl_Context::init (const Standard_Boolean theIsCoreProfile)
// load GL_ARB_vertex_type_2_10_10_10_rev (added to OpenGL 3.3 core)
const bool hasVertType21010101rev = (IsGlGreaterEqual (3, 3) || CheckExtension ("GL_ARB_vertex_type_2_10_10_10_rev"))
&& FindProcShort (glVertexP2ui)
&& FindProcShort (glVertexAttribP1ui)
&& FindProcShort (glVertexAttribP1uiv)
&& FindProcShort (glVertexAttribP2ui)
&& FindProcShort (glVertexAttribP2uiv)
&& FindProcShort (glVertexAttribP3ui)
&& FindProcShort (glVertexAttribP3uiv)
&& FindProcShort (glVertexAttribP4ui)
&& FindProcShort (glVertexAttribP4uiv);
if ( hasVertType21010101rev
&& !isCoreProfile)
{
// load deprecated functions
const bool hasVertType21010101revExt =
FindProcShort (glVertexP2ui)
&& FindProcShort (glVertexP2uiv)
&& FindProcShort (glVertexP3ui)
&& FindProcShort (glVertexP3uiv)
@@ -1668,15 +1682,9 @@ void OpenGl_Context::init (const Standard_Boolean theIsCoreProfile)
&& FindProcShort (glColorP4ui)
&& FindProcShort (glColorP4uiv)
&& FindProcShort (glSecondaryColorP3ui)
&& FindProcShort (glSecondaryColorP3uiv)
&& FindProcShort (glVertexAttribP1ui)
&& FindProcShort (glVertexAttribP1uiv)
&& FindProcShort (glVertexAttribP2ui)
&& FindProcShort (glVertexAttribP2uiv)
&& FindProcShort (glVertexAttribP3ui)
&& FindProcShort (glVertexAttribP3uiv)
&& FindProcShort (glVertexAttribP4ui)
&& FindProcShort (glVertexAttribP4uiv);
&& FindProcShort (glSecondaryColorP3uiv);
(void )hasVertType21010101revExt;
}
// load OpenGL 3.3 extra functions
has33 = IsGlGreaterEqual (3, 3)