UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
FTexture2DArrayMipAllocator_Reallocate Class Reference

#include <Texture2DArrayStreaming.h>

+ Inheritance diagram for FTexture2DArrayMipAllocator_Reallocate:

Classes

struct  FMallocDeleter
 

Public Member Functions

 FTexture2DArrayMipAllocator_Reallocate (UTexture *Texture)
 
 ~FTexture2DArrayMipAllocator_Reallocate ()
 
bool AllocateMips (const FTextureUpdateContext &Context, FTextureMipInfoArray &OutMipInfos, const FTextureUpdateSyncOptions &SyncOptions) final override
 
bool UploadMips (const FTextureUpdateContext &Context, const FTextureUpdateSyncOptions &SyncOptions) final override
 
void Cancel (const FTextureUpdateSyncOptions &SyncOptions) final override
 
ETickThread GetCancelThread () const final override
 
- Public Member Functions inherited from FTextureMipAllocator
 FTextureMipAllocator (UTexture *Texture, ETickState InTickState, ETickThread InTickThread)
 
 FTextureMipAllocator (const FTextureMipAllocator &)
 
 FTextureMipAllocator (FTextureMipAllocator &&)
 
virtual ~FTextureMipAllocator ()
 
FORCEINLINE ETickState GetNextTickState () const
 
FORCEINLINE ETickThread GetNextTickThread () const
 
bool FinalizeMips (const FTextureUpdateContext &Context, const FTextureUpdateSyncOptions &SyncOptions)
 
void ExecuteCancel (const FTextureUpdateSyncOptions &SyncOptions)
 
ETickThread ExecuteGetCancelThread () const
 
const FTextureRHIRefGetIntermediateTextureRHI () const
 

Protected Attributes

TArray< TUniquePtr< uint8, FMallocDeleter >, TInlineAllocator< MAX_TEXTURE_MIP_COUNT > > StreamedMipData
 
TArray< uint64, TInlineAllocator< MAX_TEXTURE_MIP_COUNT > > StreamedSliceSize
 
- Protected Attributes inherited from FTextureMipAllocator
const FStreamableRenderResourceState ResourceState
 
const int32 CurrentFirstLODIdx = INDEX_NONE
 
const int32 PendingFirstLODIdx = INDEX_NONE
 
FTextureRHIRef IntermediateTextureRHI
 

Additional Inherited Members

- Public Types inherited from FTextureMipAllocator
enum class  ETickState : uint32 { AllocateMips , UploadMips , Done }
 
enum class  ETickThread : uint32 { Async , Render , None }
 
- Protected Member Functions inherited from FTextureMipAllocator
FORCEINLINE void AdvanceTo (ETickState InState, ETickThread InThread)
 

Detailed Description

Implements a texture3d mip resizing strategy based on creating a duplicate texture and copyinng the shared mips.

Constructor & Destructor Documentation

◆ FTexture2DArrayMipAllocator_Reallocate()

FTexture2DArrayMipAllocator_Reallocate::FTexture2DArrayMipAllocator_Reallocate ( UTexture Texture)

◆ ~FTexture2DArrayMipAllocator_Reallocate()

FTexture2DArrayMipAllocator_Reallocate::~FTexture2DArrayMipAllocator_Reallocate ( )

Member Function Documentation

◆ AllocateMips()

bool FTexture2DArrayMipAllocator_Reallocate::AllocateMips ( const FTextureUpdateContext Context,
FTextureMipInfoArray OutMipInfos,
const FTextureUpdateSyncOptions SyncOptions 
)
finaloverridevirtual

Allocate the FTextureMipInfoArray and configure the entries for the new (streamed in) mips. In particular, the FTextureMipAllocator must set valid FTextureMipInfo::DestData so that the mip data provider can write the mip data to.

Parameters
Context- An update context constant throughout the FTextureStreamIn update. Gives things like which texture asset is updated and what mips are streamed in.
OutMipInfos- The array of FTextureMipInfo that must be correctly configured so that FTextureMipDataProvider know what is being requested and where to write data to.
SyncOptions- Different sync options to control when the next tick of FTextureStreamIn can be scheduled.

Return true unless the texture update needs to be aborted because of invalid data or setup.

Implements FTextureMipAllocator.

◆ Cancel()

void FTexture2DArrayMipAllocator_Reallocate::Cancel ( const FTextureUpdateSyncOptions SyncOptions)
finaloverridevirtual

Cancel the progression and release any temporary resources. Called within the FTextureStreamIn update when the stream in request is aborted or cannot complete correctly The Cancel() function is called on the thread returned by GetCancelThread().

Parameters
SyncOptions- Different sync options to control when the next tick of FTextureStreamIn can be scheduled.

Implements FTextureMipAllocator.

◆ GetCancelThread()

FTextureMipAllocator::ETickThread FTexture2DArrayMipAllocator_Reallocate::GetCancelThread ( ) const
finaloverridevirtual

Implements FTextureMipAllocator.

◆ UploadMips()

bool FTexture2DArrayMipAllocator_Reallocate::UploadMips ( const FTextureUpdateContext Context,
const FTextureUpdateSyncOptions SyncOptions 
)
finaloverridevirtual

Upload the new mip data to the GPU. The

Parameters
Context- An update context constant throughout the FTextureStreamIn update. Gives things like which texture asset is updated and what mips are streamed in.
SyncOptions- Different sync options to control when the next tick of FTextureStreamIn can be scheduled.

Return true unless the texture update needs to be aborted because of invalid data or setup.

Implements FTextureMipAllocator.

Member Data Documentation

◆ StreamedMipData

TArray<TUniquePtr<uint8, FMallocDeleter>, TInlineAllocator<MAX_TEXTURE_MIP_COUNT> > FTexture2DArrayMipAllocator_Reallocate::StreamedMipData
protected

◆ StreamedSliceSize

TArray<uint64, TInlineAllocator<MAX_TEXTURE_MIP_COUNT> > FTexture2DArrayMipAllocator_Reallocate::StreamedSliceSize
protected

The documentation for this class was generated from the following files: