⛔ Please use https://github.com/cns-iu/hra-multi-lod/tree/main instead. ⛔
Version: 1.0.0
Release date: 19 July 2023
Multi-LOD project includes:
- a C++ library to generate multiple level of detail models using CGAL library.
- different resolution (0.2, 0.4, 0.6, 0.8) models for 3D reference organ models are provided.
- a Python library for converting glb files to off (Object File Format) files, which is the underlying 3D model format for generating multi-LOD models.
For C++ libraries [1]:
- CMake
sudo apt-get install build-essential libssl-dev cd /tmp wget https://github.com/Kitware/CMake/releases/download/v3.20.0/cmake-3.20.0.tar.gz tar -zxvf cmake-3.20.0.tar.gz cd cmake-3.20.0 ./bootstrap make sudo make install
- Boost
sudo apt-get update sudo apt-get install libboost-all-dev
- GMP
sudo apt-get install libgmp-dev
- MPFR
sudo apt-get install libmpfr-dev
- CGAL
sudo apt-get install libcgal-dev
- Eigen3
sudo apt install libeigen3-dev
For Python library [3]:
- pygltflib
pip install pygltflib
We use CMake to configure the program with third-party dependencies and generate the native build system by creating a CMakeLists.txt file.
mkdir build
cd build
cmake ..
make
In the model directory:
- multi_lod_0.2: Models where the number of edges of the models drops below 20% of the initial count.
- multi_lod_0.4: Models where the number of edges of the models drops below 40% of the initial count.
- multi_lod_0.6: Models where the number of edges of the models drops below 60% of the initial count.
- multi_lod_0.8: Models where the number of edges of the models drops below 80% of the initial count.
- convert glb files of 3D models to off (Object File Format) files:
cd $scripts python glb_parser.py input_dir_3D_model_glb output_dir_3D_model_off
- generate different LOD models by specifiying the resolution parameter
$k$ ,./build/lod_generator body_path ./multi_lod_k k, e.g., ./build/lod_generator ./model/plain_v4 ./multi_lod_0.2 0.2, or chmod +x ./run.sh ./run.sh
note: