Commit 4dd07482 authored by Mathieu Faverge's avatar Mathieu Faverge

Add branch for Thibault

parent fb3f8597
......@@ -32,24 +32,33 @@ include (CMakeDependentOption)
### Required Packages
# Try to find Qt5 : http://forum.openscenegraph.org/viewtopic.php?t=11431
set(USE_QT5 OFF)
# QUIET option disables messages if the package cannot be found.
find_package(Qt5Widgets QUIET)
if(Qt5Widgets_FOUND)
# CMake 2.8.8 or greater required for qt5 use
if("${CMAKE_VERSION}" VERSION_GREATER 2.8.7)
set(USE_QT5 ON)
endif()
endif()
option(USE_QT5
"Use QT5 instead of QT4" OFF)
if (USE_QT5)
# QUIET option disables messages if the package cannot be found.
find_package(Qt5Widgets QUIET)
if(Qt5Widgets_FOUND)
# CMake 2.8.8 or greater required for qt5 use
if("${CMAKE_VERSION}" VERSION_GREATER 2.8.7)
set(USE_QT5 ON)
endif()
endif()
if(USE_QT5)
set(CMAKE_AUTOMOC ON)
find_package(Qt5 COMPONENTS Core Xml Widgets OpenGL UiTools REQUIRED)
find_package(Qt5Core REQUIRED)
find_package(Qt5Xml REQUIRED)
find_package(Qt5Widgets REQUIRED)
find_package(Qt5OpenGL REQUIRED)
# find_package(Qt5UiTools REQUIRED)
else(USE_QT5) # Try Qt4
find_package(Qt4 COMPONENTS QtCore QtGui QtXml REQUIRED)
set(QT_USE_QTUITOOLS ON)
set(QT_USE_QTOPENGL ON)
include(${QT_USE_FILE})
endif(USE_QT5)
#find_package(OpenGL)
......
This diff is collapsed.
......@@ -363,20 +363,15 @@ void Render_opengl::paintGL(){
glFlush();
/* Check the errors */
GLenum glerror;
glerror = glGetError();
if(glerror != GL_NO_ERROR)
message << tr("Render area : the following OpengGL error occured: ").toStdString() << (char *)gluErrorString(glerror) << Message::endw;
if(DRAWING_STATE_WAITING == _state)/* A wait is drawn, do not take car about the ruler drawing */
return;
QFont arial_font = QFont("Arial", 10);
qglColor(Qt::white);
......
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