46 const searchableSurface& surface,
47 const scalar& defaultCellSize,
48 const labelList regionIndices
61 coeffsDict().
get<scalar>(
"distanceCoeff") * defaultCellSize
63 distanceSqr_(
sqr(distance_))
72 const pointIndexHit& hitPt,
75 scalarField& shapeSizes
80 const scalar distanceCellSize =
88 shapePts[0] = pt -
n*distance_;
89 shapePts[1] = pt +
n*distance_;
91 shapeSizes[0] = distanceCellSize;
92 shapeSizes[1] = distanceCellSize;
99 shapePts[0] = pt -
n*distance_;
100 shapeSizes[0] = distanceCellSize;
105 shapeSizes.resize(1);
107 shapePts[0] = pt -
n*distance_;
108 shapeSizes[0] = distanceCellSize;
137 const point& hitPt = hitInfo.point();
138 const label index = hitInfo.index();
140 if (sideMode_ == rmBothsides)
142 size = surfaceCellSizeFunction_().interpolate(hitPt, index);
149 if (hitInfo.point().dist(pt) < snapToSurfaceTol_)
151 size = surfaceCellSizeFunction_().interpolate(hitPt, index);
159 surface_.getVolumeType(ptF, vTL);
161 bool functionApplied =
false;
165 sideMode_ == smInside
169 size = surfaceCellSizeFunction_().interpolate(hitPt, index);
171 functionApplied =
true;
175 sideMode_ == smOutside
179 size = surfaceCellSizeFunction_().interpolate(hitPt, index);
181 functionApplied =
true;
184 return functionApplied;
Macros for easy insertion into run-time selection tables.
#define addToRunTimeSelectionTable(baseType, thisType, argNames)
Add to construction table with typeName as the key.
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
Abstract base class for specifying target cell sizes.
sideMode sideMode_
Mode of size specification, i.e. inside, outside or bothSides.
autoPtr< surfaceCellSizeFunction > surfaceCellSizeFunction_
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
A Vector of values with scalar precision, where scalar is float/double depending on the compilation f...
@ OUTSIDE
A location outside the volume.
@ INSIDE
A location inside the volume.
#define defineTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information.
List< ReturnType > get(const UPtrList< T > &list, const AccessOp &aop)
List of values generated by applying the access operation to each list item.
const wordList surface
Standard surface field types (scalar, vector, tensor, etc).
dimensionedSymmTensor sqr(const dimensionedVector &dv)
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
vector point
Point is a vector.
vectorField pointField
pointField is a vectorField.
PointIndexHit< point > pointIndexHit
A PointIndexHit with a 3D point.