MeshKernel
Mesh2D.hpp
1 //---- GPL ---------------------------------------------------------------------
2 //
3 // Copyright (C) Stichting Deltares, 2011-2021.
4 //
5 // This program is free software: you can redistribute it and/or modify
6 // it under the terms of the GNU General Public License as published by
7 // the Free Software Foundation version 3.
8 //
9 // This program is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 // GNU General Public License for more details.
13 //
14 // You should have received a copy of the GNU General Public License
15 // along with this program. If not, see <http://www.gnu.org/licenses/>.
16 //
17 // contact: delft3d.support@deltares.nl
18 // Stichting Deltares
19 // P.O. Box 177
20 // 2600 MH Delft, The Netherlands
21 //
22 // All indications and logos of, and references to, "Delft3D" and "Deltares"
23 // are registered trademarks of Stichting Deltares, and remain the property of
24 // Stichting Deltares. All rights reserved.
25 //
26 //------------------------------------------------------------------------------
27 
28 #pragma once
29 
30 namespace meshkernelapi
31 {
33  struct Mesh2D
34  {
36  int* edge_faces = nullptr;
37 
39  int* edge_nodes = nullptr;
40 
42  int* face_edges = nullptr;
43 
45  int* face_nodes = nullptr;
46 
48  int* nodes_per_face = nullptr;
49 
51  double* node_x = nullptr;
52 
54  double* node_y = nullptr;
55 
57  double* edge_x = nullptr;
58 
60  double* edge_y = nullptr;
61 
63  double* face_x = nullptr;
64 
66  double* face_y = nullptr;
67 
69  int num_nodes = 0;
70 
72  int num_valid_nodes = 0;
73 
75  int num_edges = 0;
76 
78  int num_valid_edges = 0;
79 
81  int num_faces = 0;
82 
84  int num_face_nodes = 0;
85  };
86 
87 } // namespace meshkernelapi
meshkernelapi::Mesh2D::num_face_nodes
int num_face_nodes
The total number of nodes composing the mesh 2d faces.
Definition: Mesh2D.hpp:84
meshkernelapi::Mesh2D::face_edges
int * face_edges
For each face the edges indices.
Definition: Mesh2D.hpp:42
meshkernelapi::Mesh2D::edge_y
double * edge_y
The y-coordinates of the mesh edges middle points.
Definition: Mesh2D.hpp:60
meshkernelapi::Mesh2D::nodes_per_face
int * nodes_per_face
The number of nodes for each mesh 2d face.
Definition: Mesh2D.hpp:48
meshkernelapi::Mesh2D::edge_x
double * edge_x
The x-coordinates of the mesh edges middle points.
Definition: Mesh2D.hpp:57
meshkernelapi::Mesh2D::num_valid_nodes
int num_valid_nodes
The number of valid mesh nodes.
Definition: Mesh2D.hpp:72
meshkernelapi::Mesh2D::node_x
double * node_x
The x-coordinates of network1d nodes.
Definition: Mesh2D.hpp:51
meshkernelapi::Mesh2D
A struct used to describe the values of an unstructured, two-dimensional mesh in a C-compatible manne...
Definition: Mesh2D.hpp:33
meshkernelapi::Mesh2D::node_y
double * node_y
The y-coordinates of network1d nodes.
Definition: Mesh2D.hpp:54
meshkernelapi
Contains all structs and functions exposed at the API level.
Definition: BoundingBox.hpp:32
meshkernelapi::Mesh2D::edge_faces
int * edge_faces
For each edge the faces indices.
Definition: Mesh2D.hpp:36
meshkernelapi::Mesh2D::face_x
double * face_x
The x-coordinates of the mesh faces mass centers.
Definition: Mesh2D.hpp:63
meshkernelapi::Mesh2D::face_nodes
int * face_nodes
The nodes composing each mesh 2d face.
Definition: Mesh2D.hpp:45
meshkernelapi::Mesh2D::face_y
double * face_y
The y-coordinates of the mesh faces mass centers.
Definition: Mesh2D.hpp:66
meshkernelapi::Mesh2D::num_nodes
int num_nodes
The number of mesh nodes.
Definition: Mesh2D.hpp:69
meshkernelapi::Mesh2D::num_edges
int num_edges
The number of edges.
Definition: Mesh2D.hpp:75
meshkernelapi::Mesh2D::edge_nodes
int * edge_nodes
The nodes composing each mesh 2d edge.
Definition: Mesh2D.hpp:39
meshkernelapi::Mesh2D::num_faces
int num_faces
The number of faces.
Definition: Mesh2D.hpp:81
meshkernelapi::Mesh2D::num_valid_edges
int num_valid_edges
The number of valid edges.
Definition: Mesh2D.hpp:78