if (NOT pylon_FOUND)
    find_package(pylon 6.2 REQUIRED)
endif ()
if (NOT DEFINED OpenCV_FOUND AND NOT WIN32)
    find_package(OpenCV QUIET)
endif ()

add_executable(ColorAndDepthPtp ColorAndDepthPtp.cpp)
target_link_libraries(ColorAndDepthPtp MultiCamHelper pylon::pylon)
if (NOT WIN32 AND OpenCV_FOUND)
	# The pylon image window is only available on Windows.
	# Therefore, use OpenCV for visualization on other platforms, if available.
	target_link_libraries(ColorAndDepthPtp ${OpenCV_LIBS})
	target_compile_definitions(ColorAndDepthPtp PRIVATE WITH_OPENCV=1)
	target_include_directories(ColorAndDepthPtp PRIVATE ${OpenCV_INCLUDE_DIRS} )
endif()
