summaryrefslogtreecommitdiffstats
path: root/examples/opengl
diff options
context:
space:
mode:
authorKai Köhne <kai.koehne@qt.io>2022-11-15 22:00:14 +0100
committerKai Köhne <kai.koehne@qt.io>2022-11-17 19:59:11 +0100
commitf562711c642cba7bed6c96d452437ffc9b25edc4 (patch)
tree4fdfc0718caadac4341b295af0132d3310d49fb5 /examples/opengl
parentbec264c15fe07382009def3c4bbef3f3b689b6eb (diff)
Examples: Use qt_standard_project_setup()
Change-Id: I0ceab08108b7e58e4e2ed25db9e3c289f5c0ddac Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'examples/opengl')
-rw-r--r--examples/opengl/2dpainting/CMakeLists.txt4
-rw-r--r--examples/opengl/computegles31/CMakeLists.txt4
-rw-r--r--examples/opengl/contextinfo/CMakeLists.txt4
-rw-r--r--examples/opengl/cube/CMakeLists.txt4
-rw-r--r--examples/opengl/hellogl2/CMakeLists.txt4
-rw-r--r--examples/opengl/hellogles3/CMakeLists.txt4
-rw-r--r--examples/opengl/hellowindow/CMakeLists.txt4
-rw-r--r--examples/opengl/openglwindow/CMakeLists.txt4
-rw-r--r--examples/opengl/paintedwindow/CMakeLists.txt4
-rw-r--r--examples/opengl/qopenglwidget/CMakeLists.txt4
-rw-r--r--examples/opengl/qopenglwindow/CMakeLists.txt4
-rw-r--r--examples/opengl/textures/CMakeLists.txt4
-rw-r--r--examples/opengl/threadedqopenglwidget/CMakeLists.txt4
13 files changed, 26 insertions, 26 deletions
diff --git a/examples/opengl/2dpainting/CMakeLists.txt b/examples/opengl/2dpainting/CMakeLists.txt
index 8f508090be..c6f320ffe7 100644
--- a/examples/opengl/2dpainting/CMakeLists.txt
+++ b/examples/opengl/2dpainting/CMakeLists.txt
@@ -4,8 +4,6 @@
cmake_minimum_required(VERSION 3.16)
project(2dpainting LANGUAGES CXX)
-set(CMAKE_AUTOMOC ON)
-
if(NOT DEFINED INSTALL_EXAMPLESDIR)
set(INSTALL_EXAMPLESDIR "examples")
endif()
@@ -14,6 +12,8 @@ set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/2dpainting")
find_package(Qt6 REQUIRED COMPONENTS Core Gui OpenGL OpenGLWidgets Widgets)
+qt_standard_project_setup()
+
qt_add_executable(2dpainting
glwidget.cpp glwidget.h
helper.cpp helper.h
diff --git a/examples/opengl/computegles31/CMakeLists.txt b/examples/opengl/computegles31/CMakeLists.txt
index ea1cc23eb7..ccbf158036 100644
--- a/examples/opengl/computegles31/CMakeLists.txt
+++ b/examples/opengl/computegles31/CMakeLists.txt
@@ -4,8 +4,6 @@
cmake_minimum_required(VERSION 3.16)
project(computegles31 LANGUAGES CXX)
-set(CMAKE_AUTOMOC ON)
-
if(NOT DEFINED INSTALL_EXAMPLESDIR)
set(INSTALL_EXAMPLESDIR "examples")
endif()
@@ -14,6 +12,8 @@ set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/computegles31")
find_package(Qt6 REQUIRED COMPONENTS Core Gui OpenGL)
+qt_standard_project_setup()
+
qt_add_executable(computegles31
glwindow.cpp glwindow.h
main.cpp
diff --git a/examples/opengl/contextinfo/CMakeLists.txt b/examples/opengl/contextinfo/CMakeLists.txt
index fbec66adc5..7b49a02a53 100644
--- a/examples/opengl/contextinfo/CMakeLists.txt
+++ b/examples/opengl/contextinfo/CMakeLists.txt
@@ -4,8 +4,6 @@
cmake_minimum_required(VERSION 3.16)
project(contextinfo LANGUAGES CXX)
-set(CMAKE_AUTOMOC ON)
-
if(NOT DEFINED INSTALL_EXAMPLESDIR)
set(INSTALL_EXAMPLESDIR "examples")
endif()
@@ -14,6 +12,8 @@ set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/contextinfo")
find_package(Qt6 REQUIRED COMPONENTS Core Gui OpenGL Widgets)
+qt_standard_project_setup()
+
qt_add_executable(contextinfo
main.cpp
renderwindow.cpp renderwindow.h
diff --git a/examples/opengl/cube/CMakeLists.txt b/examples/opengl/cube/CMakeLists.txt
index eadfce631a..ea999ed4e5 100644
--- a/examples/opengl/cube/CMakeLists.txt
+++ b/examples/opengl/cube/CMakeLists.txt
@@ -4,8 +4,6 @@
cmake_minimum_required(VERSION 3.16)
project(cube LANGUAGES CXX)
-set(CMAKE_AUTOMOC ON)
-
if(NOT DEFINED INSTALL_EXAMPLESDIR)
set(INSTALL_EXAMPLESDIR "examples")
endif()
@@ -14,6 +12,8 @@ set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/cube")
find_package(Qt6 REQUIRED COMPONENTS Core Gui OpenGL OpenGLWidgets Widgets)
+qt_standard_project_setup()
+
qt_add_executable(cube
geometryengine.cpp geometryengine.h
main.cpp
diff --git a/examples/opengl/hellogl2/CMakeLists.txt b/examples/opengl/hellogl2/CMakeLists.txt
index 2095c0ebf2..f15c5ffe85 100644
--- a/examples/opengl/hellogl2/CMakeLists.txt
+++ b/examples/opengl/hellogl2/CMakeLists.txt
@@ -4,8 +4,6 @@
cmake_minimum_required(VERSION 3.16)
project(hellogl2 LANGUAGES CXX)
-set(CMAKE_AUTOMOC ON)
-
if(NOT DEFINED INSTALL_EXAMPLESDIR)
set(INSTALL_EXAMPLESDIR "examples")
endif()
@@ -14,6 +12,8 @@ set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/hellogl2")
find_package(Qt6 REQUIRED COMPONENTS Core Gui OpenGL OpenGLWidgets Widgets)
+qt_standard_project_setup()
+
qt_add_executable(hellogl2
glwidget.cpp glwidget.h
logo.cpp logo.h
diff --git a/examples/opengl/hellogles3/CMakeLists.txt b/examples/opengl/hellogles3/CMakeLists.txt
index 230a6da8b0..aa54ec9b93 100644
--- a/examples/opengl/hellogles3/CMakeLists.txt
+++ b/examples/opengl/hellogles3/CMakeLists.txt
@@ -4,8 +4,6 @@
cmake_minimum_required(VERSION 3.16)
project(hellogles3 LANGUAGES CXX)
-set(CMAKE_AUTOMOC ON)
-
if(NOT DEFINED INSTALL_EXAMPLESDIR)
set(INSTALL_EXAMPLESDIR "examples")
endif()
@@ -14,6 +12,8 @@ set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/hellogles3")
find_package(Qt6 REQUIRED COMPONENTS Core Gui OpenGL)
+qt_standard_project_setup()
+
qt_add_executable(hellogles3
../hellogl2/logo.cpp ../hellogl2/logo.h
glwindow.cpp glwindow.h
diff --git a/examples/opengl/hellowindow/CMakeLists.txt b/examples/opengl/hellowindow/CMakeLists.txt
index 00291e8918..3ac623a99a 100644
--- a/examples/opengl/hellowindow/CMakeLists.txt
+++ b/examples/opengl/hellowindow/CMakeLists.txt
@@ -4,8 +4,6 @@
cmake_minimum_required(VERSION 3.16)
project(hellowindow LANGUAGES CXX)
-set(CMAKE_AUTOMOC ON)
-
if(NOT DEFINED INSTALL_EXAMPLESDIR)
set(INSTALL_EXAMPLESDIR "examples")
endif()
@@ -14,6 +12,8 @@ set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/hellowindow")
find_package(Qt6 REQUIRED COMPONENTS Core Gui OpenGL)
+qt_standard_project_setup()
+
qt_add_executable(hellowindow
hellowindow.cpp hellowindow.h
main.cpp
diff --git a/examples/opengl/openglwindow/CMakeLists.txt b/examples/opengl/openglwindow/CMakeLists.txt
index 250c8f70db..a22f92dcd8 100644
--- a/examples/opengl/openglwindow/CMakeLists.txt
+++ b/examples/opengl/openglwindow/CMakeLists.txt
@@ -4,8 +4,6 @@
cmake_minimum_required(VERSION 3.16)
project(openglwindow LANGUAGES CXX)
-set(CMAKE_AUTOMOC ON)
-
if(NOT DEFINED INSTALL_EXAMPLESDIR)
set(INSTALL_EXAMPLESDIR "examples")
endif()
@@ -14,6 +12,8 @@ set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/openglwindow")
find_package(Qt6 REQUIRED COMPONENTS Core Gui OpenGL)
+qt_standard_project_setup()
+
qt_add_executable(openglwindow
main.cpp
openglwindow.cpp openglwindow.h
diff --git a/examples/opengl/paintedwindow/CMakeLists.txt b/examples/opengl/paintedwindow/CMakeLists.txt
index 782e9f14c7..53ae5a01e2 100644
--- a/examples/opengl/paintedwindow/CMakeLists.txt
+++ b/examples/opengl/paintedwindow/CMakeLists.txt
@@ -4,8 +4,6 @@
cmake_minimum_required(VERSION 3.16)
project(paintedwindow LANGUAGES CXX)
-set(CMAKE_AUTOMOC ON)
-
if(NOT DEFINED INSTALL_EXAMPLESDIR)
set(INSTALL_EXAMPLESDIR "examples")
endif()
@@ -14,6 +12,8 @@ set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/paintedwindow")
find_package(Qt6 REQUIRED COMPONENTS Core Gui OpenGL)
+qt_standard_project_setup()
+
qt_add_executable(paintedwindow
main.cpp
paintedwindow.cpp paintedwindow.h
diff --git a/examples/opengl/qopenglwidget/CMakeLists.txt b/examples/opengl/qopenglwidget/CMakeLists.txt
index dcb0411a3e..293d0b5037 100644
--- a/examples/opengl/qopenglwidget/CMakeLists.txt
+++ b/examples/opengl/qopenglwidget/CMakeLists.txt
@@ -4,8 +4,6 @@
cmake_minimum_required(VERSION 3.16)
project(qopenglwidget LANGUAGES CXX)
-set(CMAKE_AUTOMOC ON)
-
if(NOT DEFINED INSTALL_EXAMPLESDIR)
set(INSTALL_EXAMPLESDIR "examples")
endif()
@@ -14,6 +12,8 @@ set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/qopenglwidget")
find_package(Qt6 REQUIRED COMPONENTS Core Gui OpenGL OpenGLWidgets Widgets)
+qt_standard_project_setup()
+
qt_add_executable(qopenglwidget
bubble.cpp bubble.h
glwidget.cpp glwidget.h
diff --git a/examples/opengl/qopenglwindow/CMakeLists.txt b/examples/opengl/qopenglwindow/CMakeLists.txt
index be03f24f9b..fd9f59b63e 100644
--- a/examples/opengl/qopenglwindow/CMakeLists.txt
+++ b/examples/opengl/qopenglwindow/CMakeLists.txt
@@ -4,8 +4,6 @@
cmake_minimum_required(VERSION 3.16)
project(qopenglwindow LANGUAGES CXX)
-set(CMAKE_AUTOMOC ON)
-
if(NOT DEFINED INSTALL_EXAMPLESDIR)
set(INSTALL_EXAMPLESDIR "examples")
endif()
@@ -14,6 +12,8 @@ set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/qopenglwindow")
find_package(Qt6 REQUIRED COMPONENTS Core Gui OpenGL)
+qt_standard_project_setup()
+
qt_add_executable(qopenglwindow
background_renderer.cpp background_renderer.h
main.cpp
diff --git a/examples/opengl/textures/CMakeLists.txt b/examples/opengl/textures/CMakeLists.txt
index 08a044c9b7..bf22cda67f 100644
--- a/examples/opengl/textures/CMakeLists.txt
+++ b/examples/opengl/textures/CMakeLists.txt
@@ -4,8 +4,6 @@
cmake_minimum_required(VERSION 3.16)
project(textures LANGUAGES CXX)
-set(CMAKE_AUTOMOC ON)
-
if(NOT DEFINED INSTALL_EXAMPLESDIR)
set(INSTALL_EXAMPLESDIR "examples")
endif()
@@ -14,6 +12,8 @@ set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/textures")
find_package(Qt6 REQUIRED COMPONENTS Core Gui OpenGL OpenGLWidgets Widgets)
+qt_standard_project_setup()
+
qt_add_executable(textures
glwidget.cpp glwidget.h
main.cpp
diff --git a/examples/opengl/threadedqopenglwidget/CMakeLists.txt b/examples/opengl/threadedqopenglwidget/CMakeLists.txt
index 0a944ef0b5..23cedd81bd 100644
--- a/examples/opengl/threadedqopenglwidget/CMakeLists.txt
+++ b/examples/opengl/threadedqopenglwidget/CMakeLists.txt
@@ -4,8 +4,6 @@
cmake_minimum_required(VERSION 3.16)
project(threadedqopenglwidget LANGUAGES CXX)
-set(CMAKE_AUTOMOC ON)
-
if(NOT DEFINED INSTALL_EXAMPLESDIR)
set(INSTALL_EXAMPLESDIR "examples")
endif()
@@ -14,6 +12,8 @@ set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/threadedqopenglwidget")
find_package(Qt6 REQUIRED COMPONENTS Core Gui OpenGL OpenGLWidgets Widgets)
+qt_standard_project_setup()
+
qt_add_executable(threadedqopenglwidget
renderer.cpp renderer.h
glwidget.cpp glwidget.h