Given triSurface and intersection creates the intersected (properly triangulated) surface. (note: intersection is the list of points and edges 'shared' by two surfaces) More...
Public Member Functions | |
ClassName ("intersectedSurface") | |
intersectedSurface () | |
intersectedSurface (const triSurface &surf) | |
intersectedSurface (const triSurface &surf, const bool isFirstSurface, const surfaceIntersection &inter) | |
const labelList & | intersectionEdges () const |
const labelList & | faceMap () const |
label | nSurfacePoints () const |
bool | isSurfacePoint (const label pointi) const |
![]() | |
ClassName ("triSurface") | |
triSurface () | |
triSurface (const triSurface &surf) | |
triSurface (triSurface &&surf) | |
triSurface (const List< labelledTri > &triangles, const geometricSurfacePatchList &patches, const pointField &pts) | |
triSurface (List< labelledTri > &triangles, const geometricSurfacePatchList &patches, pointField &pts, const bool reuse) | |
triSurface (const List< labelledTri > &triangles, const pointField &pts) | |
triSurface (const triFaceList &triangles, const pointField &pts) | |
triSurface (const fileName &name, const scalar scaleFactor=-1) | |
triSurface (const fileName &name, const word &fileType, const scalar scaleFactor=-1) | |
triSurface (Istream &is) | |
triSurface (const Time &d) | |
triSurface (const IOobject &io, const dictionary &dict, const bool isGlobal=true) | |
virtual | ~triSurface () |
void | clearOut () |
void | clearTopology () |
void | clearPatchMeshAddr () |
void | swap (triSurface &surf) |
const geometricSurfacePatchList & | patches () const noexcept |
geometricSurfacePatchList & | patches () noexcept |
const List< labelledTri > & | surfFaces () const noexcept |
const labelListList & | sortedEdgeFaces () const |
const labelList & | edgeOwner () const |
const vectorField & | Sf () const |
const scalarField & | magSf () const |
const vectorField & | Cf () const |
List< surfZone > | sortedZones (labelList &faceMap) const |
void | triFaceFaces (List< face > &plainFaceList) const |
virtual void | movePoints (const pointField &pts) |
virtual void | swapPoints (pointField &pts) |
virtual void | scalePoints (const scalar scaleFactor) |
void | checkTriangles (const bool verbose) |
void | checkEdges (const bool verbose) |
void | cleanup (const bool verbose) |
void | compactPoints (labelList &pointMap=const_cast< labelList & >(labelList::null())) |
void | markZone (const boolList &borderEdge, const label facei, const label currentZone, labelList &faceZone) const |
label | markZones (const boolList &borderEdge, labelList &faceZone) const |
template<class BoolListType > | |
void | subsetMeshMap (const BoolListType &include, labelList &pointMap, labelList &faceMap) const |
triSurface | subsetMesh (const UList< bool > &include, labelList &pointMap, labelList &faceMap) const |
triSurface | subsetMesh (const bitSet &include, labelList &pointMap, labelList &faceMap) const |
triSurface | subsetMesh (const UList< bool > &include) const |
triSurface | subsetMesh (const bitSet &include) const |
triSurface | subsetMesh (const wordRes &includeNames, const wordRes &excludeNames=wordRes()) const |
void | swapFaces (List< labelledTri > &faceLst) |
void | transfer (triSurface &surf) |
void | transfer (MeshedSurface< labelledTri > &surf) |
void | write (Ostream &os) const |
void | write (const fileName &, const bool sortByRegion=false) const |
void | write (const fileName &filename, const word &fileType, const bool sortByRegion=false) const |
void | write (const Time &d) const |
void | writeStats (Ostream &os) const |
void | operator= (const triSurface &surf) |
void | operator= (triSurface &&surf) |
void | operator= (MeshedSurface< labelledTri > &&surf) |
![]() | |
PrimitivePatch (const ::Foam::List< labelledTri > &faces, const pointField &points) | |
PrimitivePatch (::Foam::List< labelledTri > &&faces, const pointField &points) | |
PrimitivePatch (::Foam::List< labelledTri > &faces, pointField &points, const bool reuse) | |
PrimitivePatch (const PrimitivePatch< ::Foam::List< labelledTri >, pointField > &pp) | |
virtual | ~PrimitivePatch () |
void | clearOut () |
void | clearGeom () |
void | clearTopology () |
void | clearPatchMeshAddr () |
void | swap (PrimitivePatch &)=delete |
const Field< point_type > & | points () const noexcept |
label | nFaces () const noexcept |
label | nPoints () const |
label | nEdges () const |
const edgeList & | edges () const |
const edgeList::subList | internalEdges () const |
const edgeList::subList | boundaryEdges () const |
label | nInternalEdges () const |
label | nBoundaryEdges () const |
bool | isInternalEdge (const label edgei) const |
const labelList & | boundaryPoints () const |
const labelListList & | faceFaces () const |
const labelListList & | edgeFaces () const |
const labelListList & | faceEdges () const |
const labelListList & | pointEdges () const |
const labelListList & | pointFaces () const |
const List< face_type > & | localFaces () const |
labelList | boundaryFaces () const |
labelList | uniqBoundaryFaces () const |
const labelList & | meshPoints () const |
const Map< label > & | meshPointMap () const |
const Field< point_type > & | localPoints () const |
const labelList & | localPointOrder () const |
label | whichPoint (const label gp) const |
edge | meshEdge (const label edgei) const |
edge | meshEdge (const edge &e) const |
label | meshEdge (const label edgei, const edgeList &allEdges, const labelListList &pointEdges) const |
label | findEdge (const edge &e) const |
labelList | meshEdges (const edgeList &allEdges, const labelListList &cellEdges, const labelList &faceCells) const |
labelList | meshEdges (const edgeList &allEdges, const labelListList &pointEdges) const |
labelList | meshEdges (const labelUList &edgeLabels, const edgeList &allEdges, const labelListList &pointEdges) const |
const Field< point_type > & | faceCentres () const |
const Field< point_type > & | faceAreas () const |
const Field< scalar > & | magFaceAreas () const |
const Field< point_type > & | faceNormals () const |
const Field< point_type > & | pointNormals () const |
bool | hasFaceAreas () const |
bool | hasFaceCentres () const |
bool | hasFaceNormals () const |
bool | hasPointNormals () const |
bool | hasBoundaryPoints () const |
bool | hasFaceFaces () const |
bool | hasEdgeFaces () const |
bool | hasFaceEdges () const |
bool | hasPointEdges () const |
bool | hasPointFaces () const |
bool | hasMeshPointMap () const |
List< objectHit > | projectPoints (const ToPatch &targetPatch, const Field< point_type > &projectionDirection, const intersection::algorithm=intersection::FULL_RAY, const intersection::direction=intersection::VECTOR) const |
Foam::List< Foam::objectHit > | projectPoints (const ToPatch &targetPatch, const Field< typename Foam::PrimitivePatch< ::Foam::List< labelledTri >, pointField >::point_type > &projectionDirection, const intersection::algorithm alg, const intersection::direction dir) const |
List< objectHit > | projectFaceCentres (const ToPatch &targetPatch, const Field< point_type > &projectionDirection, const intersection::algorithm=intersection::FULL_RAY, const intersection::direction=intersection::VECTOR) const |
Foam::List< Foam::objectHit > | projectFaceCentres (const ToPatch &targetPatch, const Field< typename Foam::PrimitivePatch< ::Foam::List< labelledTri >, pointField >::point_type > &projectionDirection, const intersection::algorithm alg, const intersection::direction dir) const |
const labelListList & | edgeLoops () const |
surfaceTopo | surfaceType () const |
bool | checkTopology (const bool report=false, labelHashSet *setPtr=nullptr) const |
bool | checkPointManifold (const bool report=false, labelHashSet *setPtr=nullptr) const |
virtual void | movePoints (const Field< point_type > &) |
void | operator= (const PrimitivePatch< ::Foam::List< labelledTri >, pointField > &rhs) |
void | operator= (PrimitivePatch< ::Foam::List< labelledTri >, pointField > &&rhs) |
label | whichEdge (const edge &e) const |
![]() | |
ClassName ("PrimitivePatch") | |
PrimitivePatchBase ()=default | |
![]() | |
constexpr | List () noexcept |
List (const label len) | |
List (const label len, const T &val) | |
List (const label len, const Foam::zero) | |
List (const Foam::one, const T &val) | |
List (const Foam::one, T &&val) | |
List (const Foam::one, const Foam::zero) | |
List (const List< T > &a) | |
List (const UList< T > &a) | |
List (List< T > &a, bool reuse) | |
List (const UList< T > &list, const labelUList &indices) | |
List (const UList< T > &list, const FixedList< label, N > &indices) | |
List (const FixedList< T, N > &list) | |
List (const PtrList< T > &list) | |
List (const SLList< T > &list) | |
List (const IndirectListBase< T, Addr > &list) | |
List (std::initializer_list< T > list) | |
List (List< T > &&list) | |
List (DynamicList< T, SizeMin > &&list) | |
List (SortableList< T > &&list) | |
List (SLList< T > &&list) | |
List (Istream &is) | |
List (const label len) | |
List (const label len, const T &val) | |
List (const label len, const Foam::zero) | |
List (const Foam::one, const T &val) | |
List (const Foam::one, T &&val) | |
List (const Foam::one, const Foam::zero) | |
List (const UList< T > &a) | |
List (const List< T > &a) | |
List (List< T > &a, bool reuse) | |
List (const UList< T > &list, const labelUList &indices) | |
List (const PtrList< T > &list) | |
List (const SLList< T > &list) | |
List (std::initializer_list< T > list) | |
List (List< T > &&list) | |
List (SortableList< T > &&list) | |
List (SLList< T > &&list) | |
constexpr | List () noexcept |
List (Istream &is) | |
autoPtr< List< T > > | clone () const |
~List () | |
void | clear () |
void | resize (const label len) |
void | resize (const label len, const T &val) |
void | resize (const label newLen) |
void | resize_nocopy (const label len) |
void | setSize (const label n) |
void | setSize (const label n, const T &val) |
void | append (const T &val) |
void | append (T &&val) |
void | append (const UList< T > &list) |
void | append (const IndirectListBase< T, Addr > &list) |
void | append (const T &val) |
void | append (T &&val) |
void | append (const UList< T > &list) |
label | appendUniq (const T &val) |
void | transfer (List< T > &list) |
void | transfer (DynamicList< T, SizeMin > &list) |
void | transfer (SortableList< T > &list) |
void | transfer (List< T > &list) |
void | transfer (SortableList< T > &list) |
T & | newElmt (const label i) |
void | operator= (const UList< T > &a) |
void | operator= (const List< T > &list) |
void | operator= (const SLList< T > &list) |
void | operator= (const IndirectListBase< T, Addr > &list) |
void | operator= (const FixedList< T, N > &list) |
void | operator= (std::initializer_list< T > list) |
void | operator= (const T &val) |
void | operator= (const Foam::zero) |
void | operator= (List< T > &&list) |
void | operator= (DynamicList< T, SizeMin > &&list) |
void | operator= (SortableList< T > &&list) |
void | operator= (SLList< T > &&list) |
void | operator= (const UList< T > &a) |
void | operator= (const List< T > &list) |
void | operator= (const SLList< T > &list) |
void | operator= (std::initializer_list< T > list) |
void | operator= (List< T > &&list) |
void | operator= (SortableList< T > &&list) |
void | operator= (SLList< T > &&list) |
void | operator= (const T &val) |
void | operator= (const Foam::zero) |
Istream & | readList (Istream &is) |
Istream & | readList (Istream &is) |
Istream & | readList (Istream &is) |
void | shallowCopy (const UList< T > &)=delete |
std::enable_if< std::is_same< bool, TypeT >::value, bool >::type | set (const label i, bool val=true) |
Static Public Attributes | |
static const label | UNVISITED = 0 |
static const label | STARTTOEND = 1 |
static const label | ENDTOSTART = 2 |
static const label | BOTH = STARTTOEND | ENDTOSTART |
Additional Inherited Members | |
![]() | |
typedef bool | BoundaryMesh |
typedef labelledTri | face_type |
typedef point | point_type |
![]() | |
enum | surfaceTopo |
typedef std::remove_reference< ::Foam::List< labelledTri > >::type::value_type | face_type |
typedef std::remove_reference< pointField >::type::value_type | point_type |
typedef ::Foam::List< labelledTri > | FaceListType |
typedef pointField | PointFieldType |
typedef face_type | FaceType |
![]() | |
typedef SubList< T > | subList |
![]() | |
static fileName | triSurfInstance (const Time &) |
static wordHashSet | readTypes () |
static wordHashSet | writeTypes () |
static bool | canReadType (const word &fileType, bool verbose=false) |
static bool | canWriteType (const word &fileType, bool verbose=false) |
static bool | canRead (const fileName &name, bool verbose=false) |
static fileName | relativeFilePath (const IOobject &io, const fileName &f, const bool isGlobal=true) |
static fileName | checkFile (const IOobject &io, const bool isGlobal=true) |
static fileName | checkFile (const IOobject &io, const dictionary &dict, const bool isGlobal=true) |
static fileName | findFile (const IOobject &io, const bool isGlobal=true) |
static fileName | findFile (const IOobject &io, const dictionary &dict, const bool isGlobal=true) |
static autoPtr< triSurface > | New (const fileName &name, const word &fileType) |
static autoPtr< triSurface > | New (const fileName &name) |
![]() | |
static const List< T > & | null () |
![]() | |
pointField & | storedPoints () |
List< labelledTri > & | storedFaces () |
Given triSurface and intersection creates the intersected (properly triangulated) surface. (note: intersection is the list of points and edges 'shared' by two surfaces)
The resulting surface will have the points from the surface first in the point list (0 .. nSurfacePoints-1)
Note: problematic are the cut-edges which are completely inside a face. These will not be visited by a edge-point-edge walk. These are handled by resplitFace which first connects the 'floating' edges to triangle edges with two extra edges and then tries the splitting again. Seems to work (mostly). Will probably fail for boundary edge (edge with only face).
Note: points are compact, i.e. points().size() == localPoints().size() (though points() probably not localPoints())
Definition at line 79 of file intersectedSurface.H.
Definition at line 994 of file intersectedSurface.C.
intersectedSurface | ( | const triSurface & | surf | ) |
Definition at line 1003 of file intersectedSurface.C.
intersectedSurface | ( | const triSurface & | surf, |
const bool | isFirstSurface, | ||
const surfaceIntersection & | inter | ||
) |
Definition at line 1013 of file intersectedSurface.C.
References Foam::abort(), DynamicList::append(), surfaceIntersection::cutEdges(), surfaceIntersection::cutPoints(), Foam::constant::electromagnetic::e, edgeSurface::edges(), Foam::endl(), edgeSurface::faceEdges(), PrimitivePatch< FaceList, PointField >::faceEdges(), PrimitivePatch< FaceList, PointField >::faceNormals(), Foam::FatalError, FatalErrorInFunction, forAll, edge::found(), PrimitivePatch< FaceList, PointField >::localFaces(), n, edgeSurface::nSurfaceEdges(), edgeSurface::nSurfacePoints(), triSurface::operator=(), triSurface::patches(), edgeSurface::points(), List::setSize(), DynamicList::shrink(), and Foam::Zero.
ClassName | ( | "intersectedSurface" | ) |
|
inline |
Definition at line 266 of file intersectedSurface.H.
Referenced by booleanSurface::booleanSurface().
|
inline |
Definition at line 272 of file intersectedSurface.H.
Referenced by booleanSurface::booleanSurface().
|
inline |
Definition at line 278 of file intersectedSurface.H.
Referenced by booleanSurface::booleanSurface().
|
inline |
Definition at line 284 of file intersectedSurface.H.
Referenced by booleanSurface::booleanSurface().
|
static |
Definition at line 85 of file intersectedSurface.H.
|
static |
Definition at line 86 of file intersectedSurface.H.
|
static |
Definition at line 87 of file intersectedSurface.H.
|
static |
Definition at line 88 of file intersectedSurface.H.
Copyright © 2011-2018 OpenFOAM | OPENFOAM® is a registered trademark of OpenCFD Ltd.