#ifndef EZ3D_MESH_H #define EZ3D_MESH_H #include "ez3d.h" #include "stl_write.h" #include "trimesh.h" #include "image.h" /* Generate the full watertight mesh (terrain top, skirt/cliff walls, flat * bottom) from img/cfg. Exactly one of `direct` (stream to STL as facets * are produced) and `buf` (accumulate an indexed mesh for decimation) * must be non-NULL. Returns facets produced, or -1 (with a message on * stderr) if e.g. the alpha mask removes everything. */ long ez3d_build_mesh(const ez3d_image_t *img, const ez3d_config_t *cfg, stl_writer_t *direct, trimesh_t *buf); #endif /* EZ3D_MESH_H */