26 "Append line elements into a mesh.\n\n"
27 "OpenGeoSys-6 software, version " +
30 "Copyright (c) 2012-2021, OpenGeoSys Community "
31 "(http://www.opengeosys.org)",
33 TCLAP::ValueArg<std::string> mesh_in(
34 "i",
"mesh-input-file",
35 "the name of the file containing the input mesh",
true,
"",
36 "file name of input mesh");
38 TCLAP::ValueArg<std::string> mesh_out(
39 "o",
"mesh-output-file",
40 "the name of the file the mesh will be written to",
true,
"",
41 "file name of output mesh");
43 TCLAP::ValueArg<std::string> geoFileArg(
45 "the name of the geometry file which contains polylines",
true,
"",
46 "the name of the geometry file");
49 TCLAP::ValueArg<std::string> gmsh_path_arg(
"g",
"gmsh-path",
50 "the path to the gmsh binary",
51 false,
"",
"path as string");
52 cmd.add(gmsh_path_arg);
55 cmd.parse(argc, argv);
60 gmsh_path_arg.getValue());
63 if (geo_names.empty())
65 ERR(
"No geometries found.");
72 ERR(
"Could not find polylines in geometry '{:s}'.", geo_names.front());
81 ERR(
"Mesh file '{:s}' not found", mesh_in.getValue());
84 INFO(
"Mesh read: {:d} nodes, {:d} elements.", mesh->getNumberOfNodes(),
85 mesh->getNumberOfElements());
88 std::unique_ptr<MeshLib::Mesh> new_mesh =
90 INFO(
"Mesh created: {:d} nodes, {:d} elements.",
91 new_mesh->getNumberOfNodes(), new_mesh->getNumberOfElements());
void INFO(char const *fmt, Args const &... args)
void ERR(char const *fmt, Args const &... args)
Container class for geometric objects.
std::vector< std::string > getGeometryNames() const
Returns the names of all geometry vectors.
const PolylineVec * getPolylineVecObj(const std::string &name) const
The class TemplateVec takes a unique name and manages a std::vector of pointers to data elements of t...
void readGeometryFromFile(std::string const &fname, GeoLib::GEOObjects &geo_objs, std::string const &gmsh_path)
GITINFOLIB_EXPORT const std::string ogs_version
MeshLib::Mesh * readMeshFromFile(const std::string &file_name)
int writeMeshToFile(const MeshLib::Mesh &mesh, std::filesystem::path const &file_path, [[maybe_unused]] std::set< std::string > variable_output_names)