FRenderAssetUpdate

This class provides a framework for loading and unloading the texture/mesh LODs.

Windows
MacOS
Linux

Inheritance Hierarchy

References

Module

Engine

Header

/Engine/Source/Runtime/Engine/Public/RenderAssetUpdate.h

Include

#include "RenderAssetUpdate.h"

Syntax

class FRenderAssetUpdate : public IRefCountedObject

Remarks

This class provides a framework for loading and unloading the texture/mesh LODs. Each thread essentially calls Tick() until the job is done. The object can be safely deleted when IsCompleted() returns true.

Variables

Name Description

Protected variable

bool

 

bDeferExecution

Defer execution even if a task pushes a new task on the same thread.

Protected variable

bool

 

bIsCancelled

Whether the task has been cancelled because the update could not proceed or because the user called Abort() .

Protected variable

FCriticalSectio ...

 

CS

Critical Section.

Protected variable

int32

 

PendingFirstMip

The index of mip that will end as being the first mip of the intermediate (future) texture/mesh.

Protected variable

int32

 

RequestedMips

The total number of mips of the intermediate (future) texture/mesh.

Protected variable

int32

 

ScheduledAsyncTasks

Number of Ticks scheduled on async tasks.

Protected variable

int32

 

ScheduledGTTasks

Number of Ticks scheduled on the game thread.

Protected variable

int32

 

ScheduledRenderTasks

Number of Ticks scheduled on the render thread.

Protected variable

UStreamableRend ...

 

StreamableAsset

The asset updated

Protected variable

ETaskState

 

TaskState

The state of the work yet to be performed to complete the update or cancelation.

Protected variable

FThreadSafeCoun ...

 

TaskSynchronization

Synchronization used for trigger the task next step execution.

Constructors

Name Description

Public function

FRenderAssetUpdate

(
    UStreamableRenderAsset * InAsse...,
    int32 InRequestedMips
)

Destructors

Name Description

Protected function Virtual

~FRenderAssetUpdate()

Functions

Name Description

Public function Virtual

void

 

Abort()

Cancel the current update.

Public function Virtual Const

bool

 

DDCIsInvalid()

Returns whether DDC of this texture needs to be regenerated.

Public function

ETaskState

 

DoLock()

Perform a lock on the object, preventing any other thread from processing a pending task in Tick() .

Public function

void

 

DoUnlock

(
    ETaskState PreviousTaskState
)

Release any lock on the object, allowing other thread to modify it.

Public function Const

int32

 

GetNumRequestedMips()

Get the number of requested mips for this update, ignoring cancellation attempts.

Public function Const

EThreadType

 

GetRelevantThread()

Return the thread relevant to the next step of execution.

Public function Const

bool

 

IsCancelled()

Returns whether the task was aborted through Abort() or cancelled.

Public function Const

bool

 

IsCompleted()

Returns whether the task has finished executing and there is no other thread possibly accessing it.

Public function Const

bool

 

IsLocked()

Protected function

void

 

MarkAsCancelled()

Set the task state as cancelled.

Protected function

void

 

ScheduleAsyncTask()

Protected function

void

 

ScheduleGTTask()

Protected function

void

 

ScheduleRenderTask()

Public function

void

 

Tick

(
    EThreadType InCurrentThread
)

Do or schedule any pending work for a given texture.

Protected function

ETaskState

 

TickInternal

(
    EThreadType InCurrentThread,
    bool bCheckForSuspension
)

Overridden from IRefCountedObject

Name Description

Public function Virtual Const

uint32

 

AddRef()

Public function Virtual Const

uint32

 

GetRefCount()

Public function Virtual Const

uint32

 

Release()

Classes

Name

Description

Protected class

FMipUpdateTask

An async task used to call tick on the pending update.

Enums

Name

Description

Public enum

ETaskState

The state of scheduled work for the update process.

Public enum

EThreadType

A thread type used for doing a part of the update process.

Typedefs

Name

Description

FAsyncMipUpdateTask

The async task to update this object, only one can be active at anytime.

Select Skin
Light
Dark

Welcome to the new Unreal Engine 4 Documentation site!

We're working on lots of new features including a feedback system so you can tell us how we are doing. It's not quite ready for use in the wild yet, so head over to the Documentation Feedback forum to tell us about this page or call out any issues you are encountering in the meantime.

We'll be sure to let you know when the new system is up and running.

Post Feedback