Skip to content
Snippets Groups Projects
Verified Commit 6b774728 authored by Lars Bilke's avatar Lars Bilke
Browse files

Fixed warnings in Applications.

parent 4e95dc5c
No related branches found
No related tags found
No related merge requests found
...@@ -58,13 +58,6 @@ static std::unique_ptr<MeshLib::Mesh> createMeshFromElements( ...@@ -58,13 +58,6 @@ static std::unique_ptr<MeshLib::Mesh> createMeshFromElements(
static std::vector<std::unique_ptr<MeshLib::Mesh>> extractBoundaryMeshes( static std::vector<std::unique_ptr<MeshLib::Mesh>> extractBoundaryMeshes(
MeshLib::Mesh const& mesh, std::vector<std::size_t> selected_element_ids) MeshLib::Mesh const& mesh, std::vector<std::size_t> selected_element_ids)
{ {
// Bulk mesh node searcher usef for boundary mesh identification.
auto const& mesh_node_searcher =
MeshGeoToolsLib::MeshNodeSearcher::getMeshNodeSearcher(
mesh,
std::make_unique<MeshGeoToolsLib::SearchLength>(
0)); // Exact match of nodes.
auto const material_ids = materialIDs(mesh); auto const material_ids = materialIDs(mesh);
if (material_ids == nullptr) if (material_ids == nullptr)
{ {
...@@ -155,8 +148,8 @@ int main(int argc, char* argv[]) ...@@ -155,8 +148,8 @@ int main(int argc, char* argv[])
"filename as string"); "filename as string");
cmd.add(ogs_mesh_arg); cmd.add(ogs_mesh_arg);
TCLAP::ValueArg<std::string> gmsh_mesh_arg( TCLAP::ValueArg<std::string> gmsh_mesh_arg("i", "in", "gmsh input file",
"i", "in", "gmsh input file", true, "", "filename as string"); true, "", "filename as string");
cmd.add(gmsh_mesh_arg); cmd.add(gmsh_mesh_arg);
TCLAP::SwitchArg valid_arg("v", "validation", "validate the mesh"); TCLAP::SwitchArg valid_arg("v", "validation", "validate the mesh");
......
...@@ -100,7 +100,6 @@ void markFaults(MeshLib::Mesh& mesh, MeshLib::Mesh const& fault, ...@@ -100,7 +100,6 @@ void markFaults(MeshLib::Mesh& mesh, MeshLib::Mesh const& fault,
auto mat_ids = mesh.getProperties().getPropertyVector<int>(mat_name); auto mat_ids = mesh.getProperties().getPropertyVector<int>(mat_name);
auto const& fnodes = fault.getNodes(); auto const& fnodes = fault.getNodes();
auto const& felems = fault.getElements(); auto const& felems = fault.getElements();
std::size_t const n_felems = fault.getNumberOfElements();
GeoLib::AABB const fault_aabb(fnodes.cbegin(), fnodes.cend()); GeoLib::AABB const fault_aabb(fnodes.cbegin(), fnodes.cend());
auto min_pnt = fault_aabb.getMinPoint(); auto min_pnt = fault_aabb.getMinPoint();
auto max_pnt = fault_aabb.getMaxPoint(); auto max_pnt = fault_aabb.getMaxPoint();
......
...@@ -120,7 +120,7 @@ void voteMatId(MeshLib::Node const& node, MeshLib::MeshElementGrid const& grid, ...@@ -120,7 +120,7 @@ void voteMatId(MeshLib::Node const& node, MeshLib::MeshElementGrid const& grid,
// between // between
void setMaterialIDs(MeshLib::Mesh& mesh, void setMaterialIDs(MeshLib::Mesh& mesh,
std::vector<std::unique_ptr<MeshLib::Mesh>> const& layers, std::vector<std::unique_ptr<MeshLib::Mesh>> const& layers,
std::array<double, 3> half_cell_size, bool const dilate) bool const dilate)
{ {
INFO("Setting material properties..."); INFO("Setting material properties...");
std::size_t const n_layers = layers.size(); std::size_t const n_layers = layers.size();
...@@ -313,9 +313,7 @@ int main(int argc, char* argv[]) ...@@ -313,9 +313,7 @@ int main(int argc, char* argv[])
ERR("Error creating mesh..."); ERR("Error creating mesh...");
return EXIT_FAILURE; return EXIT_FAILURE;
} }
std::array<double, 3> const half_cell_size{ setMaterialIDs(*mesh, layers, dilate_arg.getValue());
{cellsize[0] / 2.0, cellsize[1] / 2.0, cellsize[2] / 2.0}};
setMaterialIDs(*mesh, layers, half_cell_size, dilate_arg.getValue());
std::unique_ptr<MeshLib::Mesh> new_mesh(removeUnusedElements(*mesh)); std::unique_ptr<MeshLib::Mesh> new_mesh(removeUnusedElements(*mesh));
if (new_mesh == nullptr) if (new_mesh == nullptr)
......
...@@ -67,8 +67,7 @@ public: ...@@ -67,8 +67,7 @@ public:
*/ */
NodeWiseMeshPartitioner(const IntegerType num_partitions, NodeWiseMeshPartitioner(const IntegerType num_partitions,
std::unique_ptr<MeshLib::Mesh>&& mesh) std::unique_ptr<MeshLib::Mesh>&& mesh)
: _npartitions(num_partitions), : _partitions(num_partitions),
_partitions(num_partitions),
_partitioned_properties(), _partitioned_properties(),
_mesh(std::move(mesh)), _mesh(std::move(mesh)),
_nodes_global_ids(_mesh->getNumberOfNodes()), _nodes_global_ids(_mesh->getNumberOfNodes()),
...@@ -116,9 +115,6 @@ public: ...@@ -116,9 +115,6 @@ public:
MeshLib::Mesh const& mesh() const { return *_mesh; } MeshLib::Mesh const& mesh() const { return *_mesh; }
private: private:
/// Number of partitions.
IntegerType _npartitions;
/// Data for all partitions. /// Data for all partitions.
std::vector<Partition> _partitions; std::vector<Partition> _partitions;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment