41#ifndef Foam_processorLODs_box
42#define Foam_processorLODs_box
76 static const label
FIXED;
124 const label refineIter,
125 const label nTgtObjects,
135 const label refineIter,
136 const label nSrcElem,
158 const label refineIter,
159 const label nSrcFaces,
168 const label nSrcElems,
169 const label nTgtElems,
186 const label maxObjectsPerLeaf,
187 const label nObjectsOfType,
188 const label nRefineIterMax = 100
193 virtual ~box() =
default;
A 1D vector of objects of type <T> that resizes itself as necessary to accept the new objects.
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
layoutTypes
The map layout (eg, of the constructMap).
processorLOD(const label maxObjectsPerLeaf, const label nObjectsOfType) noexcept
Construct from components.
void setRefineFlags(const label refineIter, const label nTgtObjects, List< labelHashSet > &fixedSendElems, List< List< labelList > > &localTgtElems, List< labelList > &refineFlags, labelList &nElems) const
Set the box refinement flags.
label nRefineIterMax_
Maximum number of refinement iterations.
List< labelList > newToOld_
Addressing per proc of new to old bound boxes.
void refineBox(const label boxi, const label refineIter, const label nSrcElem, const treeBoundBox &origBox, DynamicList< treeBoundBox > &procBoxes, DynamicList< labelList > &procBoxElems, DynamicList< label > &procNewToOld) const
virtual treeBoundBox calcSrcBox(const label srcObji) const =0
The local boundBox associated with given source object.
static const label DROP
Drop/discard.
static const label FIXED
Fixed - do not touch.
static const label nStartUpIter
Number of iterations before element indices are cached.
box(const UList< point > &srcPoints, const UList< point > &tgtPoints, const label maxObjectsPerLeaf, const label nObjectsOfType, const label nRefineIterMax=100)
Construct from list of points for source and target.
List< List< treeBoundBox > > boxes_
Per processor, the list of src bound boxes.
void writeBoxes(const List< DynamicList< treeBoundBox > > &fixedBoxes, const label iter) const
Helper function to write the boxes in OBJ format.
bool doRefineBoxes(const label refineIter, const label nSrcFaces, const List< labelList > &refineFlags, List< DynamicList< treeBoundBox > > &fixedBoxes)
Apply the box refinements.
virtual ~box()=default
Destructor.
TypeName("box")
Runtime type information.
autoPtr< mapDistribute > createMap(const label nSrcElems, const label nTgtElems, const mapDistributeBase::layoutTypes constructLayout)
Return the parallel distribution map (often linear construct order).
static const label REFINE
Refine.
const UList< point > & tgtPoints_
Reference to the target points.
virtual treeBoundBox calcTgtBox(const label tgtObji) const =0
The local boundBox associated with given target object.
const UList< point > & srcPoints_
Reference to the source points.
List< List< labelList > > boxSrcElems_
Indices of elements in the src boxes.
Standard boundBox with extra functionality for use in octree.
List< label > labelList
A List of labels.
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.