![]() |
UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
|
#include <StreamingTexture.h>
Public Types | |
| enum | EOptionalMipsState : uint8 { OMS_NotCached , OMS_NoOptionalMips , OMS_HasOptionalMips , OMS_Num } |
Static Public Member Functions | |
| static const TCHAR * | GetStreamingAssetTypeStr (EStreamableRenderAssetType InAssetType) |
| static float | GetDefaultExtraBoost (bool bUseNewMetrics) |
| static float | GetExtraBoost (TextureGroup LODGroup, const FRenderAssetStreamingSettings &Settings) |
Self-contained structure to manage a streaming texture/mesh, possibly on a separate thread.
| FStreamingRenderAsset::FStreamingRenderAsset | ( | UStreamableRenderAsset * | InRenderAsset, |
| TSharedPtr< int32, ESPMode::ThreadSafe > & | InSimpleStreamableAssetManagerIndex, | ||
| const int32 * | NumStreamedMips, | ||
| int32 | NumLODGroups, | ||
| const FRenderAssetStreamingSettings & | Settings | ||
| ) |
| void FStreamingRenderAsset::CacheStreamingMetaData | ( | ) |
| void FStreamingRenderAsset::CancelStreamingRequest | ( | ) |
Reduce the maximum allowed resolution by 1 mip. Return the size freed by doing so.
| int64 FStreamingRenderAsset::DropOneMip_Async | ( | ) |
Reduce BudgetedMip by 1 and return the size freed by doing so.
Return the memory delta in bytes caused by max resolution change. Actual memory reduction is smaller or equal.
| int64 FStreamingRenderAsset::GetDropOneMipMemDelta | ( | ) | const |
Return the memory delta in bytes if a mip is successfully dropped.
|
static |
|
inline |
|
inline |
Returns the amount of memory used by the texture/mesh given a specified number of mip-maps, in bytes.
| MipCount | Number of mip-maps to account for |
|
inlinestatic |
| int32 FStreamingRenderAsset::GetWantedMipsFromSize | ( | float | Size, |
| float | InvMaxScreenSizeOverAllViews | ||
| ) | const |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
| int64 FStreamingRenderAsset::KeepOneMip_Async | ( | ) |
Increase BudgetedMip by 1, up to resident mips, and return the size taken.
| void FStreamingRenderAsset::SetPerfectWantedMips_Async | ( | float | MaxSize, |
| float | MaxSize_VisibleOnly, | ||
| float | MaxScreenSizeOverAllViews, | ||
| int32 | MaxNumForcedLODs, | ||
| bool | InLooksLowRes, | ||
| const FRenderAssetStreamingSettings & | Settings | ||
| ) |
Set the wanted mips from the async task data
| void FStreamingRenderAsset::StreamWantedMips | ( | FRenderAssetStreamingManager & | Manager | ) |
| void FStreamingRenderAsset::StreamWantedMipsUsingCachedData | ( | FRenderAssetStreamingManager & | Manager | ) |
| void FStreamingRenderAsset::UpdateDynamicData | ( | const int32 * | NumStreamedMips, |
| int32 | NumLODGroups, | ||
| const FRenderAssetStreamingSettings & | Settings, | ||
| bool | bWaitForMipFading, | ||
| TArray< UStreamableRenderAsset * > * | DeferredTickCBAssets = nullptr |
||
| ) |
Update data that the engine could change through gameplay.
| bool FStreamingRenderAsset::UpdateLoadOrderPriority_Async | ( | const FRenderAssetStreamingSettings & | Settings | ) |
Init load order. Return wether this texture has any load/unload request
| void FStreamingRenderAsset::UpdateOptionalMipsState_Async | ( | ) |
Init BudgetedMip and update RetentionPriority. Returns the size that would be taken if all budgeted mips where loaded.
Once the wanted mips are computed, the async task will check if everything fits in the budget. This only consider the highest mip that will be requested eventually, so that slip requests are stables.
| void FStreamingRenderAsset::UpdateStaticData | ( | const FRenderAssetStreamingSettings & | Settings | ) |
Update data that should not change unless changing settings.
| FStreamableRenderResourceState FStreamingRenderAsset::UpdateStreamingStatus | ( | bool | bWaitForMipFading, |
| TArray< UStreamableRenderAsset * > * | DeferredTickCBAssets = nullptr |
||
| ) |
Lightweight version of UpdateDynamicData.
| union { ... } FStreamingRenderAsset |
(1) Cached memory sizes for each possible mipcount.
| uint8 FStreamingRenderAsset::bCachedForceFullyLoadHeuristic |
(5)
| uint8 FStreamingRenderAsset::bForceFullyLoad |
(2) Whether the texture should be forcibly fully loaded.
| uint8 FStreamingRenderAsset::bForceFullyLoadHeuristic |
(4) Same as force fully load, but takes into account component settings.
| uint8 FStreamingRenderAsset::bHasUpdatePending |
(3) Wheter the streamer has streaming plans for this texture.
| uint8 FStreamingRenderAsset::bIgnoreStreamingMipBias |
(2) Whether the texture resolution should be affected by the memory budget. Only effective when forced fully resident.
| uint8 FStreamingRenderAsset::bIsTerrainTexture |
(1) Whether the texture should be forcibly fully loaded.
| uint8 FStreamingRenderAsset::bIsVirtualTexture |
(1) Whether the texture uses virtual texture streaming.
| uint8 FStreamingRenderAsset::bLoadWithHigherPriority |
(1) Whether the texture is loaded with higher priority.
| uint8 FStreamingRenderAsset::bLooksLowRes |
(4) Same as force fully load, but takes into account component settings.
| uint8 FStreamingRenderAsset::bMissingTooManyMips |
(4) Whether too many desired MIPs or LODs are missing.
| float FStreamingRenderAsset::BoostFactor |
(1) Sum of all boost factors that applies to this texture/mesh.
| int8 FStreamingRenderAsset::BudgetedMips |
(4) The max allowed mips (based on Visible and Hidden wanted mips) in order to fit in budget.
| int32 FStreamingRenderAsset::BudgetMipBias |
(4) A persistent bias applied to this texture. Increase whenever the streamer needs to make sacrifices to fit in budget
| uint8 FStreamingRenderAsset::bUseUnkownRefHeuristic |
(4) Whether this has not component referencing it.
| int8 FStreamingRenderAsset::CachedVisibleWantedMips |
(5)
| int8 FStreamingRenderAsset::CachedWantedMips |
(5)
| uint32 FStreamingRenderAsset::CumulativeLODSizes[FStreamableRenderResourceState::MAX_LOD_COUNT] |
| uint32 FStreamingRenderAsset::CumulativeLODSizes_Mesh[FStreamableRenderResourceState::MAX_LOD_COUNT/2] |
| float FStreamingRenderAsset::DynamicBoostFactor |
(3) Extra gameplay boost factor. Reset after every update.
| int8 FStreamingRenderAsset::HiddenWantedMips |
(4) Wanted mips for non visible instances.
| double FStreamingRenderAsset::InstanceRemovedTimestamp |
(3) If non-zero, the most recent time an instance location was removed for this texture.
| float FStreamingRenderAsset::LastRenderTime |
(2) How much game time has elapsed since the texture was bound for rendering. Based on FApp::GetCurrentTime().
| TBitArray FStreamingRenderAsset::LevelIndexUsage |
(5)
| int32 FStreamingRenderAsset::LoadOrderPriority |
(4) The load request priority.
| int32 FStreamingRenderAsset::LODGroup |
(1) Cached texture/mesh LOD group.
| float FStreamingRenderAsset::LODScreenSizes[FStreamableRenderResourceState::MAX_LOD_COUNT/2] |
| int8 FStreamingRenderAsset::MaxAllowedMips |
(2) Max mip to be requested by the streaming
| int8 FStreamingRenderAsset::MinAllowedMips |
(2) Min mip to be requested by the streaming
| int32 FStreamingRenderAsset::NoRefLODBias |
(2) LOD bias applied to no-ref meshes
| float FStreamingRenderAsset::NormalizedScreenSize |
(4) Normalized screen size. Only used by meshes.
| int8 FStreamingRenderAsset::NumForcedMips |
(4) Number of LODs forced resident. Only used by meshes currently
| int8 FStreamingRenderAsset::NumMissingMips |
(4) How many mips are missing to satisfy ideal quality because of max size limitation. Used to prevent sacrificing mips that are already visually sacrificed.
| FIoFilenameHash FStreamingRenderAsset::OptionalFileHash = INVALID_IO_FILENAME_HASH |
(1) The optional mip filename hash, see FRenderAssetStreamingManager::OnPakFileChanged()
| EOptionalMipsState FStreamingRenderAsset::OptionalMipsState |
(2) Cached state on disk of the optional mips for this streaming texture
| UStreamableRenderAsset* FStreamingRenderAsset::RenderAsset |
(1) Texture/mesh to manage. Note that this becomes null when the texture/mesh is removed.
| EStreamableRenderAssetType FStreamingRenderAsset::RenderAssetType |
(1)
| int8 FStreamingRenderAsset::RequestedMips |
(2) Min number of mip-maps requested by the streaming system.
| int8 FStreamingRenderAsset::ResidentMips |
(2) Cached number of mip-maps in memory (including the base mip)
| int32 FStreamingRenderAsset::RetentionPriority |
(4) Retention priority used to sacrifice mips when out of budget.
| TSharedPtr<int32, ESPMode::ThreadSafe> FStreamingRenderAsset::SimpleStreamableAssetManagerIndex |
(1) Index in SSAM. Note that the underlying index becomes INDEX_NONE when the texture/mesh is removed.
| int8 FStreamingRenderAsset::VisibleWantedMips |
(4) Max wanted mips for visible instances.
| int8 FStreamingRenderAsset::WantedMips |
(4) The mip that will be requested. Note, that some texture are loaded using split requests, so that the first request can be smaller than budgeted mip.