UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
IndexSetDecompositions.h
Go to the documentation of this file.
1// Copyright Epic Games, Inc. All Rights Reserved.
2
3#pragma once
4
6#include "VectorTypes.h"
7
8
9namespace UE
10{
11namespace Geometry
12{
13
14
21{
22protected:
23
24 struct FIndexSet
25 {
28 // todo alternate storage: set, arbitrary function
29 };
30
34
36
37public:
38
39 /*
40 * @return list of ID integers which identify the IndexSets of this Decomposition
41 */
43 {
44 return AllSetIDs;
45 }
46
52 {
53 FIndexSet* Set = new FIndexSet();
54 Set->Identifier = IDCounter++;
55 Sets.Add(Set);
56 SetIdentifierMap.Add(Set->Identifier, Set);
57 AllSetIDs.Add(Set->Identifier);
58 return Set->Identifier;
59 }
60
65 {
66 FIndexSet** Found = SetIdentifierMap.Find(SetID);
67 check(Found != nullptr);
68 return (*Found)->IndexArray;
69 }
70
75 {
76 FIndexSet*const* Found = SetIdentifierMap.Find(SetID);
77 check(Found != nullptr);
78 return (*Found)->IndexArray;
79 }
80
81};
82
83} // end namespace UE::Geometry
84} // end namespace UE
#define check(expr)
Definition AssertionMacros.h:314
FPlatformTypes::int32 int32
A 32-bit signed integer.
Definition Platform.h:1125
Definition Array.h:670
UE_NODEBUG UE_FORCEINLINE_HINT SizeType Add(ElementType &&Item)
Definition Array.h:2696
Definition IndirectArray.h:20
Definition UnrealString.h.inl:34
Definition IndexSetDecompositions.h:21
const TArray< int32 > & GetIndexSetArray(int32 SetID) const
Definition IndexSetDecompositions.h:74
int32 CreateNewIndexSet()
Definition IndexSetDecompositions.h:51
TArray< int32 > AllSetIDs
Definition IndexSetDecompositions.h:35
TArray< int32 > & GetIndexSetArray(int32 SetID)
Definition IndexSetDecompositions.h:64
const TArray< int32 > & GetIndexSetIDs() const
Definition IndexSetDecompositions.h:42
TMap< int32, FIndexSet * > SetIdentifierMap
Definition IndexSetDecompositions.h:32
int32 IDCounter
Definition IndexSetDecompositions.h:33
TIndirectArray< FIndexSet > Sets
Definition IndexSetDecompositions.h:31
Definition AdvancedWidgetsModule.cpp:13
Definition IndexSetDecompositions.h:25
TArray< int32 > IndexArray
Definition IndexSetDecompositions.h:27
int32 Identifier
Definition IndexSetDecompositions.h:26