Navigation
API > API/Runtime > API/Runtime/Engine > API/Runtime/Engine/UInstancedSkinnedMeshComponent
Description
Optimize the instance data by performing sorting according to spatial hash on the source data. Note that this reorders the instances and thus any indexing will change. By default resets the ID mapping to identity.
| Name | OptimizeInstanceData |
| Type | function |
| Header File | /Engine/Source/Runtime/Engine/Classes/Components/InstancedSkinnedMeshComponent.h |
| Include Path | #include "Components/InstancedSkinnedMeshComponent.h" |
| Source | /Engine/Source/Runtime/Engine/Private/Components/InstancedSkinnedMeshComponent.cpp |
UFUNCTION (BlueprintCallable, Category="Components|InstancedSkinnedMesh")
void OptimizeInstanceData
(
bool bShouldRetainIdMap
)
Parameters
| Name | Remarks |
|---|---|
| bShouldRetainIdMap | If true, the id mapping is updated instead of reset to identity, this retains the validity of the IDs but adds some memory and storage cost (for the ID mapping). |