USERD_get_nsided_conn.H
Go to the documentation of this file.
2 (
3  int part_number,
4  int *nsided_conn_array
5 )
6 {
7 #ifdef ENSIGHTDEBUG
8  Info<< "Entering: USERD_get_nsided_conn"
9  << ", part_number = " << part_number
10  << endl
11  << flush;
12 #endif
13  if (part_number == 1)
14  {
15  Info<< "************* EEEEEEEEERRRRRRRRRRRRRRRRRR *************** "
16  << endl << flush;
17 
18  }
19  else if (part_number < nPatches+2)
20  {
21  //const cellList& cells = meshPtr->cells();
22  //const faceList& faces = meshPtr->faces();
23 
24  label patchi = part_number - 2;
25  const polyBoundaryMesh& bMesh = meshPtr->boundaryMesh();
26 
27  label np = 0;
28  forAll(bMesh[patchi], facei)
29  {
30  label nPoints = bMesh[patchi][facei].size();
31  if ((nPoints != 3) && (nPoints != 4))
32  {
33  for (label i=0; i<nPoints; i++)
34  {
35  nsided_conn_array[np++] = bMesh[patchi][facei][i] + 1;
36  }
37  }
38  }
39  }
40  else if (part_number == nPatches+2)
41  {
42  return Z_ERR;
43  }
44 #ifdef ENSIGHTDEBUG
45  Info<< "Exiting: USERD_get_nsided_conn" << endl
46  << flush;
47 #endif
48  return Z_OK;
49 }
label nPatches
Definition: readKivaGrid.H:402
#define forAll(list, i)
Loop across all elements in list.
Definition: UList.H:428
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Definition: label.H:59
static fvMesh * meshPtr
Definition: globalFoam.H:52
Ostream & endl(Ostream &os)
Add newline and flush stream.
Definition: Ostream.H:253
label nPoints
label patchi
Ostream & flush(Ostream &os)
Flush stream.
Definition: Ostream.H:245
messageStream Info
PrimitivePatch< face, List, const pointField > bMesh
Holder of faceList and points. (v.s. e.g. primitivePatch which references points) ...
Definition: bMesh.H:45
int USERD_get_nsided_conn(int part_number, int *nsided_conn_array)