UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
SkeletalMeshSourceModel.h
Go to the documentation of this file.
1// Copyright Epic Games, Inc. All Rights Reserved.
2
3#pragma once
4
5#include "MeshDescription.h"
8
9#include "SkeletalMeshSourceModel.generated.h"
10
12class USkeletalMesh;
14struct FMeshDescription;
15
16UCLASS(MinimalAPI)
25
26
27USTRUCT()
30{
32
34
36
37 // No copying allowed.
40
41 // Moving is permitted.
44
47
48#if WITH_EDITOR
55 ENGINE_API bool HasMeshDescription() const;
56
63
68 ENGINE_API FMeshDescription* GetMeshDescription() const;
69
78 ENGINE_API void CommitMeshDescription(bool bInUseHashAsGuid);
79
84
90
96
101#endif
102
107 {
108 return TriangleCount;
109 }
110
115 {
116 return VertexCount;
117 }
118
124 {
125 return Bounds;
126 }
127
131 TConstArrayView<FName> GetSkinWeightProfileNames() const;
132
136 TConstArrayView<FName> GetMorphTargetNames() const;
137
141 TOptional<FGuid> GetVertexColorGuid() const;
142
143private:
144#if WITH_EDITOR
145 USkeletalMesh* GetOwner() const;
146
152
159
165
172
179
185
190
191#endif
192
195 UPROPERTY()
196 int32 TriangleCount = 0;
197
200 UPROPERTY()
201 int32 VertexCount = 0;
202
205 UPROPERTY()
206 FBoxSphereBounds Bounds;
207
208 // List of all alternate skin weight profiles stored on the mesh,
209 // NOTE: The default value is single-entry array with NAME_None to mark
210 // that this value has not been initialized yet / TOptional does not work
211 // with containers.
212 UPROPERTY()
213 TArray<FName> CachedSkinWeightProfileNames{ NAME_None };
214
215 // List of all morph targets stored on the mesh.
216 UPROPERTY()
217 TArray<FName> CachedMorphTargetNames{ NAME_None };
218
219 UPROPERTY()
220 TOptional<bool> CachedHasVertexColors;
221
222 UPROPERTY()
223 FGuid CachedVertexColorGuid;
224
225#if WITH_EDITORONLY_DATA
230 UPROPERTY()
232
233 // Accessor mutex for the bulk data, since it can be accessed from any thread.
235#endif
236
237#if WITH_EDITOR
243#endif
244};
245
246
248 TStructOpsTypeTraitsBase2<FSkeletalMeshSourceModel>
249{
250 enum { WithCopy = false };
251};
@ INDEX_NONE
Definition CoreMiscDefines.h:150
FPlatformTypes::int32 int32
A 32-bit signed integer.
Definition Platform.h:1125
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127
UE::FPlatformRecursiveMutex FCriticalSection
Definition CriticalSection.h:53
#define UPROPERTY(...)
UObject definition macros.
Definition ObjectMacros.h:744
#define GENERATED_BODY(...)
Definition ObjectMacros.h:765
#define UCLASS(...)
Definition ObjectMacros.h:776
#define USTRUCT(...)
Definition ObjectMacros.h:746
Definition NameTypes.h:617
Definition Array.h:670
Definition SharedPointer.h:692
Definition MeshDescriptionBaseBulkData.h:25
Definition SkeletalMeshSourceModel.h:18
Definition SkeletalMeshDescription.h:13
Definition SkeletalMesh.h:440
Definition Guid.h:109
Definition MeshDescription.h:94
Definition SkinnedAssetCommon.h:129
Definition SkeletalMeshSourceModel.h:30
int32 GetVertexCountFast() const
Definition SkeletalMeshSourceModel.h:114
const FBoxSphereBounds & GetBoundsFast() const
Definition SkeletalMeshSourceModel.h:123
int32 GetTriangleCountFast() const
Definition SkeletalMeshSourceModel.h:106
Definition ObjectPtr.h:488
Definition Optional.h:131
Definition StructOpsTypeTraits.h:11
@ WithCopy
Definition StructOpsTypeTraits.h:17
Definition StructOpsTypeTraits.h:46
Definition BoxSphereBounds.h:25