{"id":28383050,"url":"https://github.com/opendronemap/dem2mesh","last_synced_at":"2025-06-25T07:30:52.839Z","repository":{"id":33471673,"uuid":"154209131","full_name":"OpenDroneMap/dem2mesh","owner":"OpenDroneMap","description":"Quickly generate 2.5D meshes from elevation models.","archived":false,"fork":false,"pushed_at":"2023-12-07T01:04:57.000Z","size":230,"stargazers_count":89,"open_issues_count":1,"forks_count":20,"subscribers_count":11,"default_branch":"master","last_synced_at":"2025-06-21T22:30:07.163Z","etag":null,"topics":["25d","3d","dem","dsm","geotiff","mesh"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/OpenDroneMap.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2018-10-22T20:05:23.000Z","updated_at":"2025-05-28T12:18:27.000Z","dependencies_parsed_at":"2024-01-11T19:14:57.928Z","dependency_job_id":"948071d9-1a81-4cb8-98d9-4a564736d983","html_url":"https://github.com/OpenDroneMap/dem2mesh","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/OpenDroneMap/dem2mesh","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenDroneMap%2Fdem2mesh","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenDroneMap%2Fdem2mesh/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenDroneMap%2Fdem2mesh/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenDroneMap%2Fdem2mesh/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/OpenDroneMap","download_url":"https://codeload.github.com/OpenDroneMap/dem2mesh/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenDroneMap%2Fdem2mesh/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261826884,"owners_count":23215660,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["25d","3d","dem","dsm","geotiff","mesh"],"created_at":"2025-05-30T05:11:45.528Z","updated_at":"2025-06-25T07:30:52.834Z","avatar_url":"https://github.com/OpenDroneMap.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# dem2mesh\n\nFast generation of 2.5D meshes from elevation models.\n\n![image](https://user-images.githubusercontent.com/1951843/47350997-15d3da00-d685-11e8-8d9f-e394fc17859e.png)\n\n![image](https://user-images.githubusercontent.com/1951843/47351205-7e22bb80-d685-11e8-87c5-33b21ae05b75.png)\n\n## Quickstart\n\n```bash\ndocker run -it --rm -v /path-your-data:/data kladess/dem2mesh dem2mesh -rtc -verbose -inputFile /data/dem.tif -outputFile /data/mesh.ply\n```\n\n## Dependencies\n\nGDAL and OpenMP are the only dependencies. To install it run:\n\n```\nsudo apt-get install -y libgdal-dev libomp-dev\n```\n\n## Building\n\n```bash\nmkdir build \u0026\u0026 cd build\ncmake ..\nmake\n``` \n\n## Running\n\n```bash\n./dem2mesh -rtc -verbose -inputFile dem.tif -outputFile mesh.ply\n```\n\n:warning: The DEM should use a coordinate reference system (CRS) that has matching horizontal and vertical units (for example, UTM). If you are getting stretched or deformed results, double check your CRS and use `gdalwarp` to reproject the raster DEM. https://www.gdal.org/gdalwarp.html\n\n## Options\n\n| Flag | Description | Required |\n| --- | --- | --- |\n| -inputFile | Path to DEM raster datasource (GDAL compatible) | ✔ |\n| -outputFile | Path to PLY mesh output | ✔ |\n| -maxVertexCount | Target number of vertices for the output mesh. This number is not always guaranteed to be reached. Defaults to `100000` | |\n| -maxTileLength | Max length of a tile. Smaller values take longer to process but reduce memory usage by splitting the meshing process into tiles. Defaults to `1000`. | |\n| -aggressiveness | Value between `1` and `10` that specifies how \"aggressive\" the mesh simplification process should be at each iteration. Higher values simplify the mesh more aggressively but can decrease the fidelity of the mesh. Defaults to `5`. | |\n| -bandNum | Raster band # to use. Defaults to `1`. | |\n| -maxConcurrency | Maximum number of threads to use. Defaults to all CPUs available. | |\n| -edgeSwapThreshold | Dot product threshold (between 0-1) to perform edge collapses. Performing edge collapses can violate the 2.5D constraints, but leads to better triangles for vertical structures. Defaults to `disabled`. | |\n| -rtc | Use Relative To Center (RTC) X/Y coordinates in the output PLY mesh. This can be useful since most 3D visualization software use floating coordinate precision to represent vertices and using absolute coordinates might lead to jittering artifacts. | |\n| -verbose | Print verbose output. | |\n\n## FAQ\n\n### How does it compare to https://github.com/heremaps/tin-terrain ?\n\nThe main difference is the meshing approach and output type. Tin-terrain uses a greedy approach, dem2mesh uses a gridding + simplification approach. Tin-terrain can output to quantized-mesh format (useful for displaying in Cesium), dem2mesh does not.\n\nThe meshing approach changes the way triangles are placed in the mesh. Greedy approaches tend to generate areas with large triangles in flat parts of the mesh, which is something we wanted to avoid in dem2mesh. The gridding approach generates more evenly sized and distributed triangles. Good sized triangles are important in OpenDroneMap for generating good orthophotos during the texturing step.\n\n## Credits\n\n- Fast Quadric Mesh Simplification code modified from https://github.com/sp4cerat/Fast-Quadric-Mesh-Simplification\n- Command line parser library modified from https://github.com/mkazhdan/PoissonRecon\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopendronemap%2Fdem2mesh","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fopendronemap%2Fdem2mesh","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopendronemap%2Fdem2mesh/lists"}