Commit 6ae8581d authored by mattijs's avatar mattijs
Browse files

explicit constructor

parent 259a15d9
......@@ -62,7 +62,7 @@ void writeProcStats
// Determine surface bounding boxes, faces, points
List<treeBoundBox> surfBb(Pstream::nProcs());
{
surfBb[Pstream::myProcNo()] = boundBox(s.points(), false);
surfBb[Pstream::myProcNo()] = treeBoundBox(s.points());
Pstream::gatherList(surfBb);
Pstream::scatterList(surfBb);
}
......
......@@ -1858,7 +1858,7 @@ void Foam::meshRefinement::distribute(const mapDistributePolyMesh& map)
// Get local mesh bounding box. Single box for now.
List<treeBoundBox> meshBb(1);
treeBoundBox& bb = meshBb[0];
bb = boundBox(mesh_.points(), false);
bb = treeBoundBox(mesh_.points());
bb = bb.extend(rndGen, 1E-4);
// Distribute all geometry (so refinementSurfaces and shellSurfaces)
......
......@@ -276,7 +276,7 @@ bool Foam::treeDataTriSurface::overlaps
const point& p1 = points[f[1]];
const point& p2 = points[f[2]];
boundBox triBb(p0, p0);
treeBoundBox triBb(p0, p0);
triBb.min() = min(triBb.min(), p1);
triBb.min() = min(triBb.min(), p2);
......
......@@ -957,7 +957,7 @@ bool Foam::distributedTriSurfaceMesh::overlaps
{
const treeBoundBox& bb = bbs[bbI];
boundBox triBb(p0, p0);
treeBoundBox triBb(p0, p0);
triBb.min() = min(triBb.min(), p1);
triBb.min() = min(triBb.min(), p2);
......
......@@ -757,9 +757,11 @@ Foam::Map<Foam::label> Foam::surfaceFeatures::nearestSamples
) const
{
// Build tree out of all samples.
treeBoundBox bb(samples);
octree<octreeDataPoint> ppTree
(
treeBoundBox(samples), // overall search domain
bb, // overall search domain
octreeDataPoint(samples), // all information needed to do checks
1, // min levels
20.0, // maximum ratio of cubes v.s. cells
......@@ -858,9 +860,11 @@ Foam::Map<Foam::label> Foam::surfaceFeatures::nearestSamples
vector span(maxSearch, maxSearch, maxSearch);
// octree.shapes holds reference!
treeBoundBox bb(samples);
octree<octreeDataPoint> ppTree
(
treeBoundBox(samples), // overall search domain
bb, // overall search domain
octreeDataPoint(samples), // all information needed to do checks
1, // min levels
20.0, // maximum ratio of cubes v.s. cells
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment