![]() |
UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
|
#include "AssetRegistry/AssetData.h"#include "Containers/Array.h"#include "Containers/Set.h"#include "Containers/UnrealString.h"#include "HAL/Platform.h"#include "Math/NumericLimits.h"#include "Math/UnrealMathUtility.h"#include "Misc/Optional.h"#include "Misc/StringBuilder.h"#include "Templates/Function.h"#include "Templates/UniquePtr.h"#include "Templates/TypeCompatibleBytes.h"#include "UObject/NameTypes.h"Go to the source code of this file.
Classes | |
| struct | UE::AssetRegistry::Private::FCachedAssetKey |
| struct | UE::AssetRegistry::Private::FCachedAssetKeyFuncs |
Namespaces | |
| namespace | UE |
| namespace | UE::AssetRegistry |
| namespace | UE::AssetRegistry::Private |
Macros | |
| #define | UE_ASSETREGISTRY_INDIRECT_ASSETDATA_POINTERS 0 |
Typedefs | |
| using | UE::AssetRegistry::Private::FAssetDataMap = TSet< FAssetData *, FCachedAssetKeyFuncs > |
| using | UE::AssetRegistry::Private::FConstAssetDataMap = TSet< const FAssetData *, FCachedAssetKeyFuncs > |
Functions | |
| FStringBuilderBase & | UE::AssetRegistry::Private::operator<< (FStringBuilderBase &Builder, const FCachedAssetKey &Key) |
| bool | UE::AssetRegistry::Private::operator== (const FCachedAssetKey &A, const FCachedAssetKey &B) |
| bool | UE::AssetRegistry::Private::operator!= (const FCachedAssetKey &A, const FCachedAssetKey &B) |
| uint32 | UE::AssetRegistry::Private::GetTypeHash (const FCachedAssetKey &A) |
| uint32 | UE::AssetRegistry::Private::HashCombineQuick (uint32 A, uint32 B) |
| #define UE_ASSETREGISTRY_INDIRECT_ASSETDATA_POINTERS 0 |
UE_ASSETREGISTRY_INDIRECT_ASSETDATA_POINTERS: Save memory in the AssetRegistryState in 64-bit systems. AssetRegistryState has multiple containers of FAssetData*. Store these containers as int32 indexes into an array of FAssetData* rather than storing the fullsize int64 pointer in each container.
Only useful for tight runtime systems since the savings is small. Increases the cputime cost of AssetRegistry queries since every read of an FAssetData* during a query now adds an extra memory read (and frequently this is a cache miss).
Defined or not, The FAssetDataMap CachedAssets structure is the authoritative list of all the FAssetData* that are present in the FAssetRegistryState.
When not defined, the FAssetDataMap structure is a TSet<FAssetData*>, with a KeyFuncs that knows how to lookup an FAssetData by its objectpath name (FCachedAssetKey). All of the other query structures use the FAssetData* pointer directly as the key.
When defined, the FAssetDataMap structure has a TSetKeyFuncs that maps from FCachedAssetKey to index (FAssetDataPtrIndex), and it has a TArray of FAssetData* that FAssetDataPtrIndex addresses. All of the other query structures use FAssetDataPtrIndex as the key.
Because of the complexity of FAssetDataMap, it should not be used outside of the implementation of FAssetRegistryState.
This optimization is disabled by default because of the increased cputime cost of queries.