FindCoin3D¶
Finds Coin3D (Open Inventor):
find_package(Coin3D [...])
Coin3D is an implementation of the Open Inventor API. It provides data structures and algorithms for 3D visualization.
結果變數¶
該模組定義了以下變數:
Coin3D_FOUND
在 3.3 版被加入.
Boolean indicating whether Coin3D, Open Inventor was found.
快取變數¶
The following cache variables may also be set:
COIN3D_INCLUDE_DIRS
Directory containing the Open Inventor header files (
Inventor/So.h
).COIN3D_LIBRARIES
Coin3D libraries required for linking.
已棄用的變數¶
The following variables are provided for backward compatibility:
COIN3D_FOUND
在 4.2 版之後被棄用: Use
Coin3D_FOUND
, which has the same value.Boolean indicating whether Coin3D, Open Inventor was found.
範例¶
Finding Coin3D and conditionally creating an interface imported target that encapsulates its usage requirements for linking to a project target:
find_package(Coin3D)
if(Coin3D_FOUND AND NOT TARGET Coin3D::Coin3D)
add_library(Coin3D::Coin3D INTERFACE IMPORTED)
set_target_properties(
Coin3D::Coin3D
PROPERTIES
INTERFACE_INCLUDE_DIRECTORIES "${COIN3D_INCLUDE_DIRS}"
INTERFACE_LINK_LIBRARIES "${COIN3D_LIBRARIES}"
)
endif()
target_link_libraries(example PRIVATE Coin3D::Coin3D)