Commit 97594e93 authored by Isaak Lim's avatar Isaak Lim

- updated the checkOpenGL function for the "Shader Pipeline Renderer",...

- updated the checkOpenGL function for the "Shader Pipeline Renderer", "Depth-Peeling Renderer" and the "SSAO Renderer"
- updated the checkOpenGL function for the "Depth Image Post Processor", "Sobel Post Processor", "Philips Stereo Post Processor" and "Gray Post Processor"

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@17627 383ad7c9-94d9-4d36-a494-682f7c89f535
parent a022b6be
......@@ -720,7 +720,26 @@ void DepthPeeling::renderDualPeeling(ACG::GLState* _glState, Viewer::ViewerPrope
QString DepthPeeling::checkOpenGL()
{
return QString("");
// Get version and check
QGLFormat::OpenGLVersionFlags flags = QGLFormat::openGLVersionFlags();
if ( !flags.testFlag(QGLFormat::OpenGL_Version_3_2) )
return QString("Insufficient OpenGL Version! OpenGL 3.2 or higher required");
// Check extensions
QString glExtensions = QString((const char*)glGetString(GL_EXTENSIONS));
QString missing("");
if ( !glExtensions.contains("GL_ARB_vertex_buffer_object") )
missing += "GL_ARB_vertex_buffer_object extension missing\n";
#ifndef __APPLE__
if ( !glExtensions.contains("GL_ARB_vertex_program") )
missing += "GL_ARB_vertex_program extension missing\n";
#endif
if ( !glExtensions.contains("GL_ARB_occlusion_query") )
missing += "GL_ARB_occlusion_query extension missing\n";
return missing;
}
void DepthPeeling::addRenderObject( RenderObject* _renderObject )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment