Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
397b31e4
Commit
397b31e4
authored
Jun 26, 2010
by
Yannick Verdie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
New functions with QT GUI:
- fix CMake OpenGL compilation
parent
6314cd28
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
27 additions
and
4 deletions
+27
-4
CMakeLists.txt
CMakeLists.txt
+12
-3
CMakeLists.txt
modules/highgui/CMakeLists.txt
+12
-0
window_QT.h
modules/highgui/src/window_QT.h
+3
-1
No files found.
CMakeLists.txt
View file @
397b31e4
...
...
@@ -502,9 +502,16 @@ set(AUTOSWITCH_QT 0)#uses to disable QT
find_package
(
Qt4
)
# QUIET)
if
(
QT4_FOUND AND AUTOSWITCH_QT
)
set
(
WITH_QT ON CACHE BOOL
"Build with QT Backend support"
)
find_package
(
O
PEN
GL QUIET
)
find_package
(
O
pen
GL QUIET
)
if
(
QT_QTOPENGL_FOUND AND OPENGL_FOUND
)
set
(
WITH_QT_OPENGL ON CACHE BOOL
"Add OpenGL extention to QT"
)
#GLU is not mandatory but we used gluPerspective in setGL so, we need it for now.
if
(
OPENGL_GLU_FOUND
)
set
(
WITH_QT_OPENGL ON CACHE BOOL
"Add OpenGL extention to QT"
)
else
()
message
(
STATUS
"OpenGL found but not GLU, please install it"
)
endif
()
endif
()
endif
()
...
...
@@ -519,14 +526,16 @@ if (WITH_QT)
set
(
WITH_CARBON 0
)
message
(
STATUS
"QT detected, so Carbon and Cocoa disabled"
)
else
()
set
(
WITH_GTK 0
)
set
(
HAVE_GTK 0
)
set
(
WITH_GTHREAD 0
)
set
(
HAVE_GTHREAD 0
)
message
(
STATUS
"QT detected, so GTK and GThread disabled"
)
endif
()
endif
()
if
(
WITH_QT_OPENGL
)
message
(
STATUS
"OpenGL for QT enable"
)
message
(
STATUS
"OpenGL for QT enable
(with GLU)
"
)
set
(
HAVE_QT_OPENGL 1
)
add_definitions
(
-DOPENCV_GL=1
)
endif
()
...
...
modules/highgui/CMakeLists.txt
View file @
397b31e4
...
...
@@ -72,6 +72,10 @@ if(WIN32)
if
(
HAVE_QT
)
#SET(QT_USE_QTXML 1)
if
(
HAVE_QT_OPENGL
)
set
(
QT_USE_QTOPENGL TRUE
)
set
(
HIGHGUI_LIBRARIES
${
HIGHGUI_LIBRARIES
}
${
OPENGL_LIBRARIES
}
)
endif
()
INCLUDE
(
${
QT_USE_FILE
}
)
SET
(
_MOC_HEADERS src/window_QT.h
)
...
...
@@ -95,6 +99,10 @@ if(UNIX)
if
(
HAVE_QT
)
#SET(QT_USE_QTXML 1)
if
(
HAVE_QT_OPENGL
)
set
(
QT_USE_QTOPENGL TRUE
)
set
(
HIGHGUI_LIBRARIES
${
HIGHGUI_LIBRARIES
}
${
OPENGL_LIBRARIES
}
)
endif
()
INCLUDE
(
${
QT_USE_FILE
}
)
SET
(
_MOC_HEADERS src/window_QT.h
)
...
...
@@ -188,6 +196,10 @@ if(APPLE)
if
(
HAVE_QT
)
#SET(QT_USE_QTXML 1)
if
(
HAVE_QT_OPENGL
)
set
(
QT_USE_QTOPENGL TRUE
)
set
(
HIGHGUI_LIBRARIES
${
HIGHGUI_LIBRARIES
}
${
OPENGL_LIBRARIES
}
)
endif
()
INCLUDE
(
${
QT_USE_FILE
}
)
SET
(
_MOC_HEADERS src/window_QT.h
)
...
...
modules/highgui/src/window_QT.h
View file @
397b31e4
...
...
@@ -44,7 +44,9 @@
#include "precomp.hpp"
#if defined(OPENCV_GL)
#include <QGLWidget>
#include <QtOpenGL>
//#include <GL/glu.h>
//#include <QGLWidget>
#endif
#include <QAbstractEventDispatcher>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment