mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
COMP/ENH: Update assignments to constructors to compile with clang. Add tensor->triad conversion.
This commit is contained in:
@ -466,8 +466,8 @@ int main(int argc, char *argv[])
|
||||
labelListList pointPoints;
|
||||
autoPtr<mapDistribute> meshDistributor = buildMap(mesh, pointPoints);
|
||||
|
||||
triadField alignments = buildAlignmentField(mesh);
|
||||
pointField points = buildPointField(mesh);
|
||||
triadField alignments(buildAlignmentField(mesh));
|
||||
pointField points(buildPointField(mesh));
|
||||
|
||||
mesh.printInfo(Info);
|
||||
|
||||
|
||||
@ -168,7 +168,8 @@ public:
|
||||
);
|
||||
|
||||
//- Inserts points into the triangulation if the point is within
|
||||
// the circumsphere of another cell
|
||||
// the circumsphere of another cell. Returns HashSet of failed
|
||||
// point insertions
|
||||
template<class PointIterator>
|
||||
labelPairHashSet rangeInsertReferredWithInfo
|
||||
(
|
||||
|
||||
@ -585,7 +585,7 @@ Foam::label Foam::cellShapeControl::refineMesh
|
||||
const autoPtr<backgroundMeshDecomposition>& decomposition
|
||||
)
|
||||
{
|
||||
const pointField cellCentres = shapeControlMesh_.cellCentres();
|
||||
const pointField cellCentres(shapeControlMesh_.cellCentres());
|
||||
|
||||
Info<< " Created cell centres" << endl;
|
||||
|
||||
@ -682,7 +682,7 @@ Foam::label Foam::cellShapeControl::refineMesh
|
||||
)
|
||||
);
|
||||
verts.last().targetCellSize() = lastCellSize;
|
||||
verts.last().alignment() = tensor::I;
|
||||
verts.last().alignment() = triad::unset;
|
||||
}
|
||||
}
|
||||
|
||||
@ -704,8 +704,8 @@ void Foam::cellShapeControl::smoothMesh()
|
||||
pointPoints
|
||||
);
|
||||
|
||||
triadField alignments = buildAlignmentField(shapeControlMesh_);
|
||||
pointField points = buildPointField(shapeControlMesh_);
|
||||
triadField alignments(buildAlignmentField(shapeControlMesh_));
|
||||
pointField points(buildPointField(shapeControlMesh_));
|
||||
// Setup the sizes and alignments on each point
|
||||
triadField fixedAlignments(shapeControlMesh_.vertexCount(), triad::unset);
|
||||
|
||||
@ -721,12 +721,7 @@ void Foam::cellShapeControl::smoothMesh()
|
||||
{
|
||||
const tensor& alignment = vit->alignment();
|
||||
|
||||
fixedAlignments[vit->index()] = triad
|
||||
(
|
||||
alignment.x(),
|
||||
alignment.y(),
|
||||
alignment.z()
|
||||
);
|
||||
fixedAlignments[vit->index()] = alignment;
|
||||
}
|
||||
}
|
||||
|
||||
@ -881,12 +876,7 @@ void Foam::cellShapeControl::smoothMesh()
|
||||
{
|
||||
if (vit->real())
|
||||
{
|
||||
vit->alignment() = tensor
|
||||
(
|
||||
alignments[vit->index()].x(),
|
||||
alignments[vit->index()].y(),
|
||||
alignments[vit->index()].z()
|
||||
);
|
||||
vit->alignment() = alignments[vit->index()];
|
||||
}
|
||||
}
|
||||
|
||||
@ -911,9 +901,7 @@ void Foam::cellShapeControl::smoothMesh()
|
||||
{
|
||||
if (vit->referred())
|
||||
{
|
||||
const triad& t = alignments[referredPoints[referredI++]];
|
||||
|
||||
vit->alignment() = tensor(t.x(), t.y(), t.z());
|
||||
vit->alignment() = alignments[referredPoints[referredI++]];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -684,7 +684,7 @@ void Foam::cellShapeControlMesh::insertBoundingPoints(const boundBox& bb)
|
||||
boundBox bbInflate = bb;
|
||||
bbInflate.inflate(10);
|
||||
|
||||
pointField pts = bbInflate.points();
|
||||
pointField pts(bbInflate.points());
|
||||
|
||||
forAll(pts, pI)
|
||||
{
|
||||
|
||||
@ -263,8 +263,6 @@ Foam::triSurfaceScalarField Foam::automatic::load()
|
||||
|
||||
surfaceCellSize.write();
|
||||
|
||||
debug = 1;
|
||||
|
||||
if (debug)
|
||||
{
|
||||
faceList faces(surface_.size());
|
||||
|
||||
@ -212,9 +212,8 @@ void Foam::conformalVoronoiMesh::checkDuals()
|
||||
|
||||
typedef CGAL::Exact_predicates_exact_constructions_kernel EK2;
|
||||
typedef CGAL::Regular_triangulation_euclidean_traits_3<EK2> EK;
|
||||
typedef CGAL::Cartesian_converter<typename baseK::Kernel, EK2> To_exact;
|
||||
typedef CGAL::Cartesian_converter<EK2, typename baseK::Kernel>
|
||||
Back_from_exact;
|
||||
typedef CGAL::Cartesian_converter<baseK::Kernel, EK2> To_exact;
|
||||
typedef CGAL::Cartesian_converter<EK2, baseK::Kernel> Back_from_exact;
|
||||
|
||||
// PackedBoolList bPoints(number_of_finite_cells());
|
||||
|
||||
@ -392,13 +391,13 @@ void Foam::conformalVoronoiMesh::checkDuals()
|
||||
CGAL::Gmpq z(CGAL::to_double(masterPoint.z()));
|
||||
|
||||
std::cout<< "master = " << x << " " << y << " " << z
|
||||
<< endl;
|
||||
<< std::endl;
|
||||
|
||||
CGAL::Gmpq xs(CGAL::to_double(closestPoint.x()));
|
||||
CGAL::Gmpq ys(CGAL::to_double(closestPoint.y()));
|
||||
CGAL::Gmpq zs(CGAL::to_double(closestPoint.z()));
|
||||
std::cout<< "slave = " << xs << " " << ys << " " << zs
|
||||
<< endl;
|
||||
<< std::endl;
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
@ -142,7 +142,7 @@ inline int CGAL::indexedVertex<Gt, Vb>::index() const
|
||||
|
||||
|
||||
template<class Gt, class Vb>
|
||||
inline typename CGAL::indexedVertex<Gt, Vb>::vertexType&
|
||||
inline Foam::indexedVertexEnum::vertexType&
|
||||
CGAL::indexedVertex<Gt, Vb>::type()
|
||||
{
|
||||
return type_;
|
||||
@ -150,7 +150,7 @@ CGAL::indexedVertex<Gt, Vb>::type()
|
||||
|
||||
|
||||
template<class Gt, class Vb>
|
||||
inline typename CGAL::indexedVertex<Gt, Vb>::vertexType
|
||||
inline Foam::indexedVertexEnum::vertexType
|
||||
CGAL::indexedVertex<Gt, Vb>::type() const
|
||||
{
|
||||
return type_;
|
||||
|
||||
Reference in New Issue
Block a user