40 template<
typename TriangleMeshType>
46 template<
typename TriangleMeshType>
60 template<
typename TriangleType>
71 template<
typename TriangleMeshType>
75 for (
int32 VID = 0; VID <
Mesh.MaxVertexID(); VID++)
77 if (!
Mesh.IsVertex(VID))
103 template<
typename TriangleMeshType>
107 for (
int32 VID = 0; VID <
Mesh.MaxVertexID(); VID++)
109 if (!
Mesh.IsVertex(VID))
123 for (
auto It =
SetIDToBounds.CreateConstIterator(); It; ++It)
131 if (It.Value().Intersects(
NextIt.Value()))
139 template<
typename TriangleMeshType>
143 for (
int32 VID = 0; VID <
Mesh.MaxVertexID(); VID++)
145 if (!
Mesh.IsVertex(VID))
189 template<
typename TriangleMeshType>
194 for (
int32 VID = 0; VID <
Mesh.MaxVertexID(); VID++)
196 if (!
Mesh.IsVertex(VID))
205 if (!ComponentMap.Contains(SetID))
224 if (!ComponentMap.Contains(SetID))
253 Contiguous[(*Loc)++] = VID;
300 template<
typename TriangleType>
#define ensure( InExpression)
Definition AssertionMacros.h:464
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127
void Init()
Definition LockFreeList.h:4
Definition ArrayView.h:139
void SetNum(SizeType NewNum, EAllowShrinking AllowShrinking=UE::Core::Private::AllowShrinkingByDefault< AllocatorType >())
Definition Array.h:2308
UE_NODEBUG UE_FORCEINLINE_HINT SizeType Add(ElementType &&Item)
Definition Array.h:2696
UE_NODEBUG UE_FORCEINLINE_HINT bool Find(const ElementType &Item, SizeType &Index) const
Definition Array.h:1302
Definition AssetRegistryState.h:50
Definition UnrealString.h.inl:34
Definition VertexConnectedComponents.h:23
FVertexConnectedComponents(int32 MaxVertexID)
Definition VertexConnectedComponents.h:30
bool EnumerateContiguousComponentsFromArray(const TArray< int32 > &ContiguousComponentsArray, TFunctionRef< bool(int32, TArrayView< const int32 >)> ProcessComponentFn)
Definition VertexConnectedComponents.h:269
void ConnectOverlappingComponents(const TriangleMeshType &Mesh, int32 KeepSizeThreshold=0)
Definition VertexConnectedComponents.h:104
void ConnectVertices(int32 VertexID0, int32 VertexID1)
Definition VertexConnectedComponents.h:306
int32 GetComponent(int32 VertexID)
Definition VertexConnectedComponents.h:290
void Init(const TriangleMeshType &Mesh)
Definition VertexConnectedComponents.h:41
void ConnectTriangles(const TriangleMeshType &Mesh)
Definition VertexConnectedComponents.h:47
bool HasMultipleComponents(const TriangleMeshType &Mesh, int32 KeepSizeThreshold=0)
Definition VertexConnectedComponents.h:140
void ConnectTriangles(TArrayView< const TriangleType > Triangles)
Definition VertexConnectedComponents.h:61
bool HasMultipleComponents(int32 MaxVID, int32 KeepSizeThreshold=0)
Definition VertexConnectedComponents.h:166
FSizedDisjointSet DisjointSet
Definition VertexConnectedComponents.h:314
FVertexConnectedComponents()
Definition VertexConnectedComponents.h:25
TMap< int32, int32 > MakeComponentMap(int32 MaxVID, int32 KeepSizeThreshold=0)
Definition VertexConnectedComponents.h:213
void Init(int32 MaxVertexID)
Definition VertexConnectedComponents.h:35
int32 GetComponentSize(int32 VertexID)
Definition VertexConnectedComponents.h:295
void ConnectCloseVertices(const TriangleMeshType &Mesh, double CloseVertexThreshold, int32 KeepSizeThreshold=0)
Definition VertexConnectedComponents.h:72
TArray< int32 > MakeContiguousComponentsArray(int32 MaxVID)
Definition VertexConnectedComponents.h:233
int32 GetComponent(const TriangleType &Triangle)
Definition VertexConnectedComponents.h:301
TMap< int32, int32 > MakeComponentMap(const TriangleMeshType &Mesh, int32 KeepSizeThreshold=0)
Definition VertexConnectedComponents.h:190
Definition PointHashGrid3.h:33
T DistanceSquared(const UE::Math::TVector2< T > &V1, const UE::Math::TVector2< T > &V2)
Definition VectorTypes.h:82
Definition AdvancedWidgetsModule.cpp:13
Definition IndexTypes.h:158
Disjoint set with additional storage to track the size of each set.
Definition SizedDisjointSet.h:12
int32 Union(int32 A, int32 B)
Definition SizedDisjointSet.h:54
int32 Find(int32 Idx)
Definition SizedDisjointSet.h:74
void Init(int32 NumIDs)
Definition SizedDisjointSet.h:21
int32 GetSize(int32 Idx) const
Definition SizedDisjointSet.h:102
TArray< int32 > Sizes
Definition SizedDisjointSet.h:13
static TAxisAlignedBox3< double > Empty()
Definition BoxTypes.h:382
void Contain(const TVector< RealType > &V)
Definition BoxTypes.h:438