Commit 4e85ec2c authored by Markus Wiedemann's avatar Markus Wiedemann

-- upload of first project

parent 828ff2db
# vorlesung_vr_projekte
In this repository, projects from students attending the lecture virtual reality are published. Each project has its own subdirectory.
Please note that those projects are specifically developed for our cave-like installation and won't run without changes on a desktop computer.
cmake_minimum_required(VERSION 2.8)
# Project Name
PROJECT(MyProject)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14")
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${PROJECT_SOURCE_DIR}/modules/")
set(project_LIBRARIES)
##################################################################################################################
#list(APPEND project_LIBRARIES pthread)
find_package(synch REQUIRED)
list(APPEND project_LIBRARIES synch )
set(EXECUTABLE_OUTPUT_PATH ${CMAKE_CURRENT_LIST_DIR}/exe/)
find_package(Magnum REQUIRED
GL
GlfwApplication
MeshTools
Shaders
SceneGraph
Trade
Shapes
Primitives)
list(APPEND project_LIBRARIES
Magnum::GlfwApplication
Magnum::GL
Magnum::Magnum
Magnum::Shaders
Magnum::MeshTools
Magnum::SceneGraph
Magnum::Trade
Magnum::Shapes
Magnum::Primitives)
##################################################################################################################
include_directories(${CMAKE_SOURCE_DIR} )
add_executable(${PROJECT_NAME} src/MyProject.cpp)
target_link_libraries(${PROJECT_NAME} ${project_LIBRARIES})
add_executable(${PROJECT_NAME}_server src/MyProject_server.cpp)
target_link_libraries(${PROJECT_NAME}_server ${project_LIBRARIES})
#!/bin/bash
mkdir -p build
cd build && cmake -C ../user.cmake .. && cmake --build .
cd ..
<?xml version="1.0" encoding="utf-8"?>
<broadcastAddress>224.0.0.1</broadcastAddress>
<serverAddress>129.187.15.208</serverAddress>
<broadcastPort>30001</broadcastPort>
<stereo>false</stereo>
<walls>
<addresses>
<address>node1</address>
</addresses>
<sizes>
<size>-30 155 50 -30 185 50 30 155 50</size>
</sizes>
<geometries>
<cavewall>800 600 0 0</cavewall>
</geometries>
</walls>
<?xml version="1.0" encoding="utf-8"?>
<broadcastAddress>224.0.0.1</broadcastAddress>
<serverAddress>129.187.15.208</serverAddress>
<broadcastPort>30001</broadcastPort>
<stereo>false</stereo>
<walls>
<addresses>
<address>node1</address>
<address>node2</address>
</addresses>
<sizes>
<size>-30 155 50 -30 185 50 30 155 50</size>
<size>-30 155 50 -30 185 50 30 155 50</size>
</sizes>
<geometries>
<cavewall>800 600 0 0</cavewall>
<cavewall>800 600 0 0</cavewall>
</geometries>
</walls>
This diff is collapsed.
#.rst:
# Find EGL
# --------
#
# Finds the EGL library. This module defines:
#
# EGL_FOUND - True if EGL library is found
# EGL::EGL - EGL imported target
#
# Additionally these variables are defined for internal usage:
#
# EGL_LIBRARY - EGL library
# EGL_INCLUDE_DIR - Include dir
#
#
# This file is part of Magnum.
#
# Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018
# Vladimír Vondruš <mosra@centrum.cz>
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the "Software"),
# to deal in the Software without restriction, including without limitation
# the rights to use, copy, modify, merge, publish, distribute, sublicense,
# and/or sell copies of the Software, and to permit persons to whom the
# Software is furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included
# in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
# DEALINGS IN THE SOFTWARE.
#
# Library
if(NOT CORRADE_TARGET_EMSCRIPTEN)
find_library(EGL_LIBRARY NAMES
EGL
# ANGLE (CMake doesn't search for lib prefix on Windows)
libEGL
# On iOS a part of OpenGLES
OpenGLES)
set(EGL_LIBRARY_NEEDED EGL_LIBRARY)
endif()
# Include dir
find_path(EGL_INCLUDE_DIR NAMES
EGL/egl.h
# iOS
EAGL.h)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(EGL DEFAULT_MSG
${EGL_LIBRARY_NEEDED}
EGL_INCLUDE_DIR)
if(NOT TARGET EGL::EGL)
if(EGL_LIBRARY_NEEDED)
# Work around BUGGY framework support on macOS
# http://public.kitware.com/pipermail/cmake/2016-April/063179.html
if(APPLE AND ${EGL_LIBRARY} MATCHES "\\.framework$")
add_library(EGL::EGL INTERFACE IMPORTED)
set_property(TARGET EGL::EGL APPEND PROPERTY
INTERFACE_LINK_LIBRARIES ${EGL_LIBRARY})
else()
add_library(EGL::EGL UNKNOWN IMPORTED)
set_property(TARGET EGL::EGL PROPERTY
IMPORTED_LOCATION ${EGL_LIBRARY})
endif()
else()
# This won't work in CMake 2.8.12, but that affects Emscripten only so
# I assume people building for that are not on that crap old Ubuntu
# 14.04 LTS
add_library(EGL::EGL INTERFACE IMPORTED)
endif()
set_target_properties(EGL::EGL PROPERTIES
INTERFACE_INCLUDE_DIRECTORIES ${EGL_INCLUDE_DIR})
endif()
#.rst:
# Find GLFW
# ---------
#
# Finds the GLFW library using its cmake config if that exists, otherwise
# falls back to finding it manually. This module defines:
#
# GLFW_FOUND - True if GLFW library is found
# GLFW::GLFW - GLFW imported target
#
# Additionally, in case the config was not found, these variables are defined
# for internal usage:
#
# GLFW_LIBRARY - GLFW library
# GLFW_INCLUDE_DIR - Root include dir
#
#
# This file is part of Magnum.
#
# Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018
# Vladimír Vondruš <mosra@centrum.cz>
# Copyright © 2016 Jonathan Hale <squareys@googlemail.com>
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the "Software"),
# to deal in the Software without restriction, including without limitation
# the rights to use, copy, modify, merge, publish, distribute, sublicense,
# and/or sell copies of the Software, and to permit persons to whom the
# Software is furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included
# in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
# DEALINGS IN THE SOFTWARE.
#
# GLFW installs cmake package config files to shared/ folder which handles
# dependencies in case GLFW is built statically. We're making an INTERFACE
# target for it, which is supported only since CMake 3.0.
if(NOT CMAKE_VERSION VERSION_LESS 3.0.0)
find_package(glfw3 CONFIG)
endif()
if(TARGET glfw)
if(NOT TARGET GLFW::GLFW)
# Aliases of (global) targets are only supported in CMake 3.11, so we
# work around it by this. This is easier than fetching all possible
# properties (which are impossible to track of) and then attempting to
# rebuild them into a new target.
add_library(GLFW::GLFW INTERFACE IMPORTED)
set_target_properties(GLFW::GLFW PROPERTIES INTERFACE_LINK_LIBRARIES glfw)
endif()
# Just to make FPHSA print some meaningful location, nothing else
get_target_property(_GLFW_INTERFACE_INCLUDE_DIRECTORIES glfw INTERFACE_INCLUDE_DIRECTORIES)
find_package_handle_standard_args("GLFW" DEFAULT_MSG
_GLFW_INTERFACE_INCLUDE_DIRECTORIES)
return()
endif()
# In case no config file was found, try manually finding the library.
find_library(GLFW_LIBRARY NAMES glfw glfw3)
# Include dir
find_path(GLFW_INCLUDE_DIR
NAMES GLFW/glfw3.h)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args("GLFW" DEFAULT_MSG
GLFW_LIBRARY
GLFW_INCLUDE_DIR)
if(NOT TARGET GLFW::GLFW)
# CMake 3.0 doesn't propagate the local target as dependency upwards
# the tree and then complains that GLFW::GLFW target was not found,
# which it shouldn't. This is reproducible with the base bootstrap
# project *and* when using Magnum as CMake subproject. Works with both
# 2.8.12 and 3.1, so I'm assuming this is a CMake 3.0 bug. The
# workaround is to make the target GLOBAL so it's propagated upwards
# the tree unconditionally. For some reason, UNKNOWN targets can't be
# marked as GLOBAL, so I'm biting the bullet and saying the library is
# shared -- CMake 3.0 is only on Debian Jessie now and I'm assuming GLFW
# comes from system package, which *should be* shared. Hopefully this won't
# bite back in the future.
if(CMAKE_VERSION VERSION_GREATER "2.8.12.2" AND CMAKE_VERSION VERSION_LESS "3.1.0")
set(_GLFW_IMPORTED_LIBRARY_KIND SHARED IMPORTED GLOBAL)
else()
set(_GLFW_IMPORTED_LIBRARY_KIND UNKNOWN IMPORTED)
endif()
add_library(GLFW::GLFW ${_GLFW_IMPORTED_LIBRARY_KIND})
# Work around BUGGY framework support on macOS
# https://cmake.org/Bug/view.php?id=14105
if(CORRADE_TARGET_APPLE AND ${GLFW_LIBRARY} MATCHES "\\.framework$")
set_property(TARGET GLFW::GLFW PROPERTY IMPORTED_LOCATION ${GLFW_LIBRARY}/GLFW)
else()
set_property(TARGET GLFW::GLFW PROPERTY IMPORTED_LOCATION ${GLFW_LIBRARY})
endif()
set_property(TARGET GLFW::GLFW PROPERTY
INTERFACE_INCLUDE_DIRECTORIES ${GLFW_INCLUDE_DIR})
endif()
mark_as_advanced(GLFW_LIBRARY GLFW_INCLUDE_DIR)
#.rst:
# Find Leap
# --------
#
# Finds the Leap library. This module defines:
#
# Leap_FOUND - True if Leap library is found
# Leap::Leap - Leap imported target
#
# Additionally these variables are defined for internal usage:
#
# Leap_LIBRARY - Leap library
# Leap_INCLUDE_DIR - Include dir
#
#
# This file is part of Magnum.
#
# Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018
# Vladimír Vondruš <mosra@centrum.cz>
# Copyright © 2018 Jonathan Hale <squareys@googlemail.com>
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the "Software"),
# to deal in the Software without restriction, including without limitation
# the rights to use, copy, modify, merge, publish, distribute, sublicense,
# and/or sell copies of the Software, and to permit persons to whom the
# Software is furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included
# in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
# DEALINGS IN THE SOFTWARE.
#
if(NOT LEAP_SDK_ROOT)
find_path(LEAP_SDK_ROOT LeapSDK)
if(LEAP_SDK_ROOT)
set(LEAP_SDK_ROOT "${LEAP_SDK_ROOT}/LeapSDK")
endif()
endif()
# Find include directory
find_path(Leap_INCLUDE_DIR NAMES Leap.h HINTS ${LEAP_SDK_ROOT}/include)
if(CMAKE_SIZEOF_VOID_P EQUAL 8)
# Compiling for 64 bit
set(_Leap_ARCH "x64")
else()
# Compiling for 32 bit
set(_Leap_ARCH "x86")
endif()
if(MINGW)
# On Windows with MinGW, we link to "LeapSDK/lib/<arch>/Leap.dll"
find_library(Leap_LIBRARY NAMES Leap.dll HINTS "${LEAP_SDK_ROOT}/lib/${_Leap_ARCH}")
else()
# On Linux, "LeapSDK/lib/<arch>/libLeap.so"
# On Mac, "LeapSDK/lib/libLeap.dylib"
# On Windows, "LeapSDK/lib/<arch>/Leap.lib"
find_library(Leap_LIBRARY NAMES Leap libLeap HINTS "${LEAP_SDK_ROOT}/lib/${_Leap_ARCH}" "${LEAP_SDK_ROOT}/lib/")
endif()
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Leap DEFAULT_MSG
Leap_LIBRARY
Leap_INCLUDE_DIR)
mark_as_advanced(FORCE
Leap_LIBRARY
Leap_INCLUDE_DIR)
if(NOT TARGET Leap::Leap)
add_library(Leap::Leap UNKNOWN IMPORTED)
set_target_properties(Leap::Leap PROPERTIES
IMPORTED_LOCATION ${Leap_LIBRARY}
INTERFACE_INCLUDE_DIRECTORIES ${Leap_INCLUDE_DIR})
endif()
This diff is collapsed.
#.rst:
# Find Magnum extras
# ------------------
#
# Finds Magnum extras. Basic usage::
#
# find_package(MagnumExtras REQUIRED)
#
# This command tries to find Magnum extras and then defines the following:
#
# MagnumExtras_FOUND - Whether Magnum extras were found
#
# This command alone is useless without specifying the components:
#
# Ui - Ui library
# ui-gallery - magnum-ui-gallery executable
#
# Example usage with specifying additional components is:
#
# find_package(MagnumExtras REQUIRED Ui)
#
# For each component is then defined:
#
# MagnumExtras_*_FOUND - Whether the component was found
# MagnumExtras::* - Component imported target
#
# The package is found if either debug or release version of each requested
# library is found. If both debug and release libraries are found, proper
# version is chosen based on actual build configuration of the project (i.e.
# Debug build is linked to debug libraries, Release build to release
# libraries).
#
# Additionally these variables are defined for internal usage:
#
# MAGNUMEXTRAS_INCLUDE_DIR - Magnum extras include dir (w/o
# dependencies)
# MAGNUMEXTRAS_*_LIBRARY_DEBUG - Debug version of given library, if found
# MAGNUMEXTRAS_*_LIBRARY_RELEASE - Release version of given library, if
# found
#
#
# This file is part of Magnum.
#
# Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018
# Vladimír Vondruš <mosra@centrum.cz>
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the "Software"),
# to deal in the Software without restriction, including without limitation
# the rights to use, copy, modify, merge, publish, distribute, sublicense,
# and/or sell copies of the Software, and to permit persons to whom the
# Software is furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included
# in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
# DEALINGS IN THE SOFTWARE.
#
# Corrade library dependencies
set(_MAGNUMEXTRAS_CORRADE_DEPENDENCIES )
foreach(_component ${MagnumExtras_FIND_COMPONENTS})
if(_component STREQUAL Ui)
set(_MAGNUMEXTRAS_${_component}_CORRADE_DEPENDENCIES Interconnect)
endif()
list(APPEND _MAGNUMEXTRAS_CORRADE_DEPENDENCIES ${_MAGNUMEXTRAS_${_component}_CORRADE_DEPENDENCIES})
endforeach()
find_package(Corrade REQUIRED ${_MAGNUMEXTRAS_CORRADE_DEPENDENCIES})
# Magnum library dependencies
set(_MAGNUMEXTRAS_MAGNUM_DEPENDENCIES )
foreach(_component ${MagnumExtras_FIND_COMPONENTS})
if(_component STREQUAL Ui)
set(_MAGNUMEXTRAS_${_component}_MAGNUM_DEPENDENCIES Text)
endif()
list(APPEND _MAGNUMEXTRAS_MAGNUM_DEPENDENCIES ${_MAGNUMEXTRAS_${_component}_MAGNUM_DEPENDENCIES})
endforeach()
find_package(Magnum REQUIRED ${_MAGNUMEXTRAS_MAGNUM_DEPENDENCIES})
# Global integration include dir
find_path(MAGNUMEXTRAS_INCLUDE_DIR Magnum
HINTS ${MAGNUM_INCLUDE_DIR})
mark_as_advanced(MAGNUMEXTRAS_INCLUDE_DIR)
# Component distinction (listing them explicitly to avoid mistakes with finding
# components from other repositories)
set(_MAGNUMEXTRAS_LIBRARY_COMPONENT_LIST Ui)
set(_MAGNUMEXTRAS_EXECUTABLE_COMPONENT_LIST ui-gallery)
# Inter-component dependencies
set(_MAGNUMEXTRAS_ui-gallery_DEPENDENCIES Ui)
# Ensure that all inter-component dependencies are specified as well
set(_MAGNUMEXTRAS_ADDITIONAL_COMPONENTS )
foreach(_component ${MagnumExtras_FIND_COMPONENTS})
# Mark the dependencies as required if the component is also required
if(MagnumExtras_FIND_REQUIRED_${_component})
foreach(_dependency ${_MAGNUMEXTRAS_${_component}_DEPENDENCIES})
set(MagnumExtras_FIND_REQUIRED_${_dependency} TRUE)
endforeach()
endif()
list(APPEND _MAGNUMEXTRAS_ADDITIONAL_COMPONENTS ${_MAGNUMEXTRAS_${_component}_DEPENDENCIES})
endforeach()
# Join the lists, remove duplicate components
if(_MAGNUMEXTRAS_ADDITIONAL_COMPONENTS)
list(INSERT MagnumExtras_FIND_COMPONENTS 0 ${_MAGNUMEXTRAS_ADDITIONAL_COMPONENTS})
endif()
if(MagnumExtras_FIND_COMPONENTS)
list(REMOVE_DUPLICATES MagnumExtras_FIND_COMPONENTS)
endif()
# Convert components lists to regular expressions so I can use if(MATCHES).
# TODO: Drop this once CMake 3.3 and if(IN_LIST) can be used
foreach(_WHAT LIBRARY EXECUTABLE)
string(REPLACE ";" "|" _MAGNUMEXTRAS_${_WHAT}_COMPONENTS "${_MAGNUMEXTRAS_${_WHAT}_COMPONENT_LIST}")
set(_MAGNUMEXTRAS_${_WHAT}_COMPONENTS "^(${_MAGNUMEXTRAS_${_WHAT}_COMPONENTS})$")
endforeach()
# Additional components
foreach(_component ${MagnumExtras_FIND_COMPONENTS})
string(TOUPPER ${_component} _COMPONENT)
# Create imported target in case the library is found. If the project is
# added as subproject to CMake, the target already exists and all the
# required setup is already done from the build tree.
if(TARGET MagnumExtras::${_component})
set(MagnumExtras_${_component}_FOUND TRUE)
else()
# Library components
if(_component MATCHES ${_MAGNUMEXTRAS_LIBRARY_COMPONENTS})
add_library(MagnumExtras::${_component} UNKNOWN IMPORTED)
# Try to find both debug and release version
find_library(MAGNUMEXTRAS_${_COMPONENT}_LIBRARY_DEBUG Magnum${_component}-d)
find_library(MAGNUMEXTRAS_${_COMPONENT}_LIBRARY_RELEASE Magnum${_component})
mark_as_advanced(MAGNUMEXTRAS_${_COMPONENT}_LIBRARY_DEBUG
MAGNUMEXTRAS_${_COMPONENT}_LIBRARY_RELEASE)
if(MAGNUMEXTRAS_${_COMPONENT}_LIBRARY_RELEASE)
set_property(TARGET MagnumExtras::${_component} APPEND PROPERTY
IMPORTED_CONFIGURATIONS RELEASE)
set_property(TARGET MagnumExtras::${_component} PROPERTY
IMPORTED_LOCATION_RELEASE ${MAGNUMEXTRAS_${_COMPONENT}_LIBRARY_RELEASE})
endif()
if(MAGNUMEXTRAS_${_COMPONENT}_LIBRARY_DEBUG)
set_property(TARGET MagnumExtras::${_component} APPEND PROPERTY
IMPORTED_CONFIGURATIONS DEBUG)
set_property(TARGET MagnumExtras::${_component} PROPERTY
IMPORTED_LOCATION_DEBUG ${MAGNUMEXTRAS_${_COMPONENT}_LIBRARY_DEBUG})
endif()
endif()
# Executables
if(_component MATCHES ${_MAGNUMEXTRAS_EXECUTABLE_COMPONENTS})
add_executable(MagnumExtras::${_component} IMPORTED)
find_program(MAGNUMEXTRAS_${_COMPONENT}_EXECUTABLE magnum-${_component})
mark_as_advanced(MAGNUMEXTRAS_${_COMPONENT}_EXECUTABLE)
if(MAGNUMEXTRAS_${_COMPONENT}_EXECUTABLE)
set_property(TARGET MagnumExtras::${_component} PROPERTY
IMPORTED_LOCATION ${MAGNUMEXTRAS_${_COMPONENT}_EXECUTABLE})
endif()
endif()
# No special setup required for Ui library
# Find library includes
if(_component MATCHES ${_MAGNUMEXTRAS_LIBRARY_COMPONENTS})
find_path(_MAGNUMEXTRAS_${_COMPONENT}_INCLUDE_DIR
NAMES ${_component}.h
HINTS ${MAGNUMEXTRAS_INCLUDE_DIR}/Magnum/${_component})
endif()
if(_component MATCHES ${_MAGNUMEXTRAS_LIBRARY_COMPONENTS})
# Link to Corrade dependencies, link to core Magnum library and
# other Magnum dependencies
foreach(_dependency ${_MAGNUMEXTRAS_${_component}_CORRADE_DEPENDENCIES})
set_property(TARGET MagnumExtras::${_component} APPEND PROPERTY
INTERFACE_LINK_LIBRARIES Corrade::${_dependency})
endforeach()
set_property(TARGET MagnumExtras::${_component} APPEND PROPERTY
INTERFACE_LINK_LIBRARIES Magnum::Magnum)
foreach(_dependency ${_MAGNUMEXTRAS_${_component}_MAGNUM_DEPENDENCIES})
set_property(TARGET MagnumExtras::${_component} APPEND PROPERTY
INTERFACE_LINK_LIBRARIES Magnum::${_dependency})
endforeach()
# Add inter-project dependencies
foreach(_dependency ${_MAGNUMEXTRAS_${_component}_DEPENDENCIES})
set_property(TARGET MagnumExtras::${_component} APPEND PROPERTY
INTERFACE_LINK_LIBRARIES MagnumExtras::${_dependency})
endforeach()
endif()
# Decide if the library was found
if((_component MATCHES ${_MAGNUMEXTRAS_LIBRARY_COMPONENTS} AND _MAGNUMEXTRAS_${_COMPONENT}_INCLUDE_DIR AND (MAGNUMEXTRAS_${_COMPONENT}_LIBRARY_DEBUG OR MAGNUMEXTRAS_${_COMPONENT}_LIBRARY_RELEASE)) OR (_component MATCHES ${_MAGNUMEXTRAS_EXECUTABLE_COMPONENTS} AND MAGNUMEXTRAS_${_COMPONENT}_EXECUTABLE))
set(MagnumExtras_${_component}_FOUND TRUE)
else()
set(MagnumExtras_${_component}_FOUND FALSE)
endif()
endif()
endforeach()
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(MagnumExtras
REQUIRED_VARS MAGNUMEXTRAS_INCLUDE_DIR
HANDLE_COMPONENTS)
#.rst:
# Find OVR
# --------
#
# Finds the OVR library. This module defines:
#