cmake_minimum_required(VERSION 3.14)

project(WoodCamUtils LANGUAGES C CXX)

option(WOODCAM_BUILD_CLOUDVIEW3D "Build the Qt/OpenGL CloudView3D utility" ON)
option(WOODCAM_BUILD_CLOUDUTILS "Build the CloudUtils static library" ON)

# VrCommon is a header-oriented compatibility module. Keep it as an interface
# target so consumers get the canonical VZNL_Types.h include path.
if(NOT TARGET VrCommon)
    add_library(VrCommon INTERFACE)
    target_include_directories(VrCommon INTERFACE
        ${CMAKE_CURRENT_SOURCE_DIR}/VrCommon/Inc
    )
endif()

if(WOODCAM_BUILD_CLOUDVIEW3D)
    add_subdirectory(CloudView3D)
endif()

if(WOODCAM_BUILD_CLOUDUTILS)
    add_subdirectory(CloudUtils)
endif()
