macro(EXAMPLE_CPP EXAMPLE_CPP_NAME) add_executable(${EXAMPLE_CPP_NAME} "${EXAMPLE_CPP_NAME}.cpp") ShowAndAbortOnWarning(${EXAMPLE_CPP_NAME}) if (UNIX) set_target_properties(${EXAMPLE_CPP_NAME} PROPERTIES COMPILE_FLAGS -Wno-unused-result ) endif () set(DEPENDENCIES "${ARGN}") foreach(DEPENDENCY IN LISTS DEPENDENCIES) target_link_libraries(${EXAMPLE_CPP_NAME} ${DEPENDENCY}) endforeach() set_target_properties(${EXAMPLE_CPP_NAME} PROPERTIES FOLDER "examples/Cpp/" RUNTIME_OUTPUT_DIRECTORY "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/examples") endmacro(EXAMPLE_CPP) EXAMPLE_CPP(CameraPoseTrajectory ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(ColorMapOptimization ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(DepthCapture ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(EvaluateFeatureMatch ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(EvaluatePCDMatch ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(FileDialog ${CMAKE_PROJECT_NAME} tinyfiledialogs) EXAMPLE_CPP(FileSystem ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(Flann ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(Image ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(IntegrateRGBD ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(LineSet ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(Log ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(OdometryRGBD ${CMAKE_PROJECT_NAME}) if (WITH_OPENMP) EXAMPLE_CPP(OpenMP ${CMAKE_PROJECT_NAME}) endif (WITH_OPENMP) EXAMPLE_CPP(PCDFileFormat ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(PointCloud ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(PoseGraph ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(ProgramOptions ${CMAKE_PROJECT_NAME}) if (BUILD_LIBREALSENSE) EXAMPLE_CPP(RealSense ${CMAKE_PROJECT_NAME} realsense) endif (BUILD_LIBREALSENSE) if (BUILD_AZURE_KINECT) EXAMPLE_CPP(AzureKinectRecord ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(AzureKinectMKVReader ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(AzureKinectViewer ${CMAKE_PROJECT_NAME}) endif (BUILD_AZURE_KINECT) EXAMPLE_CPP(RegistrationRANSAC ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(RGBDOdometry ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(TriangleMesh ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(TrimMeshBasedOnPointCloud ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(ViewDistances ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(ViewPCDMatch ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(Visualizer ${CMAKE_PROJECT_NAME}) EXAMPLE_CPP(Voxelization ${CMAKE_PROJECT_NAME})