# libtpms **Repository Path**: mcoder2014/libtpms ## Basic Information - **Project Name**: libtpms - **Description**: 用于生成 TPMS 多孔结构的 cpp lib - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2020-09-16 - **Last Updated**: 2021-01-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # libtpms This project is a test project about how to create a (Triply Periodic Minimal Surfaces, TPMS) porosus structure model and how to convert it into a traditional triangle mesh. This project uses the **basic marching box algorithm**, which can easily convert an implicit surface into traingle mesh with low precision. This project can alse convert some fixed triangle mesh into TPMS porosus structure, will show below. **Welcome stars!** ## Support Implicit Surface Types This project create some type of Triply Periodic Minimal Surfaces, such as: - P - D - G - I-WP - F-RD - L - Tubular P - Tubular G # Example Just some simple codes could generate TPMS shell model. ```cpp BoxTpmsSingeSurfaceAlgorithm boxTpmsSingeSurfaceAlgorithm; boxTpmsSingeSurfaceAlgorithm.setConfig(boxTpmsSingleSurfaceConfig); Mesh mesh = boxTpmsSingeSurfaceAlgorithm.process(); MeshSmoothTool smoothTool; smoothTool.basicSmooth(mesh, 10); MeshShellTool meshShellTool; meshShellTool.shell(mesh, 0.03); Exporter expoter; expoter.writeOBJ(savePath, mesh); ``` You can create many different type of TMPS porous structure using the code like the example upon. Some result of the code is screensnap at here. ![](imgs/types.png) The below is to use a insole model to create a TPMS porosus model. ![](imgs/insole.png) # Dependency 1. greater than Qt 5 2. [Starlab](https://github.com/OpenGP/starlab) 3. openmesh 8.0 4. Eigen 3 5. Assimp # Reference 1. [Marching Cubes](http://paulbourke.net/geometry/polygonise/) 2. [Computer-aided porous scaffold design for tissue engineering using triply periodic minimal surfaces](https://link.springer.com/article/10.1007/s12541-011-0008-9)