diff options
| author | assiduous <assiduous@diligentgraphics.com> | 2020-02-24 02:14:05 +0000 |
|---|---|---|
| committer | assiduous <assiduous@diligentgraphics.com> | 2020-02-24 02:14:05 +0000 |
| commit | 5b8c90c31a066ea9ace99e7874e4fa43f770a1a2 (patch) | |
| tree | bc5c8d044956667af17b0d17a5d80227a548bfd0 | |
| parent | Updated tiny gltf (diff) | |
| download | DiligentTools-5b8c90c31a066ea9ace99e7874e4fa43f770a1a2.tar.gz DiligentTools-5b8c90c31a066ea9ace99e7874e4fa43f770a1a2.zip | |
Updated cmake file to enable draco compression in tiny gltf
| -rw-r--r-- | AssetLoader/CMakeLists.txt | 7 | ||||
| -rw-r--r-- | README.md | 2 |
2 files changed, 9 insertions, 0 deletions
diff --git a/AssetLoader/CMakeLists.txt b/AssetLoader/CMakeLists.txt index 6416c54..1b4a74b 100644 --- a/AssetLoader/CMakeLists.txt +++ b/AssetLoader/CMakeLists.txt @@ -41,6 +41,13 @@ PRIVATE Diligent-TextureLoader ) +if (TARGET draco) + target_link_libraries(Diligent-AssetLoader PRIVATE draco) + target_compile_definitions(Diligent-AssetLoader PRIVATE TINYGLTF_ENABLE_DRACO) + get_target_property(DRACO_SOURCE_DIR draco SOURCE_DIR) + target_include_directories(Diligent-AssetLoader PRIVATE "${DRACO_SOURCE_DIR}/src" "${CMAKE_BINARY_DIR}") +endif() + set_target_properties(Diligent-AssetLoader PROPERTIES FOLDER DiligentTools ) @@ -5,6 +5,8 @@ and contains the following libraries: * [Texture loader](TextureLoader): a texture loading libary. The following formats are currently supported: jpg, png, tiff, dds, ktx. * [Asset Loader](AssetLoader): an asset loading libary. The library currently supports GLTF 2.0. + * To enable Draco compression, download [Draco repository](https://github.com/google/draco) and include it into + your project. Make sure that Draco source folder is processed by CMake *before* DiligentTools folder. * [Imgui](Imgui): implementation of [dear imgui](https://github.com/ocornut/imgui) with Diligent API. * [NativeApp](NativeApp): implementation of native application on supported platforms. |
