70 (octant & RIGHTHALF) ?
max().
x() :
min().
x(),
104 if (pt.
z() > mid.
z())
137 if (pt.
x() > mid.
x())
141 else if (pt.
x() == mid.
x())
146 if (pt.
y() > mid.
y())
150 else if (pt.
y() == mid.
y())
155 if (pt.
z() > mid.
z())
159 else if (pt.
z() == mid.
z())
183 if (pt.
x() > mid.
x())
187 else if (pt.
x() == mid.
x())
196 if (pt.
y() > mid.
y())
200 else if (pt.
y() == mid.
y())
209 if (pt.
z() > mid.
z())
213 else if (pt.
z() == mid.
z())
232 vector dist = centre() - pt;
258 if (dist.x() < dist.y())
260 if (dist.y() < dist.z())
266 else if (dist.z() < dist.x())
281 if (dist.z() < dist.y())
287 else if (dist.x() < dist.z())
302 octantOrder[0] = octant;
304 octantOrder[1] = octant ^
min;
305 octantOrder[2] = octant ^ mid;
306 octantOrder[3] = octant ^
max;
308 octantOrder[4] = octantOrder[1] ^ mid;
309 octantOrder[5] = octantOrder[1] ^
max;
310 octantOrder[6] = octantOrder[2] ^
max;
312 octantOrder[7] = octantOrder[4] ^
max;
329 const scalar radiusSqr
336 return box_sphere_overlaps
364 bb.inflate(
rndGen, factor);
A 1D vector of objects of type <T> with a fixed length <N>.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
An ordered pair of two objects of type <T> with first() and second() elements.
const Cmpt & x() const noexcept
Access to the vector x component.
const Cmpt & z() const noexcept
Access to the vector z component.
const Cmpt & y() const noexcept
Access to the vector y component.
A bounding box defined in terms of min/max extrema points.
const point & max() const noexcept
Maximum describing the bounding box.
static bool box_sphere_overlaps(const point &corner0, const point &corner1, const point ¢re, const scalar radiusSqr)
Test for overlap of box and boundingSphere (centre + sqr(radius)).
const point & min() const noexcept
Minimum describing the bounding box.
boundBox()
Default construct: an inverted bounding box.
void inflate(const scalar factor)
Expand box by factor*mag(span) in all dimensions.
point centre() const
The centre (midpoint) of the bounding box.
Standard boundBox with extra functionality for use in octree.
treeBoundBox extend(Random &rndGen, const scalar s) const
Return slightly wider bounding box.
void searchOrder(const point &pt, FixedList< direction, 8 > &octantOrder) const
Calculates optimal order to look for nearest to point.
bool intersects(const point &overallStart, const vector &overallVec, const point &start, const point &end, point &pt, direction &ptBits) const
Intersects segment; set point to intersection position and face,.
point corner(const direction octant) const
Corner point of given octant.
treeBoundBox()=default
Default construct: an inverted bounding box.
bool subOverlaps(const direction octant, const boundBox &bb) const
Does sub-octant overlap/touch boundingBox?
direction subOctant(const point &pt) const
Returns octant number given point and the calculated midpoint.
@ TOPHALF
2: positive y-direction
@ RIGHTHALF
1: positive x-direction
@ FRONTHALF
4: positive z-direction
Represents 0/1 range or concept. Used for tagged dispatch or clamping.
bool operator!=(const eddy &a, const eddy &b)
label max(const labelHashSet &set, label maxValue=labelMin)
Find the max value in labelHashSet, optionally limited by second argument.
tmp< faMatrix< Type > > operator==(const faMatrix< Type > &, const faMatrix< Type > &)
line< point, const point & > linePointRef
A line using referred points.
label min(const labelHashSet &set, label minValue=labelMax)
Find the min value in labelHashSet, optionally limited by second argument.
vector point
Point is a vector.
bool ln(const fileName &src, const fileName &dst)
Create a softlink. dst should not exist. Returns true if successful.