FWorldAsyncTraceState

This encapsulate World's async trace functionality.

Windows
MacOS
Linux

References

Module

Engine

Header

/Engine/Source/Runtime/Engine/Classes/Engine/World.h

Include

#include "Engine/World.h"

Syntax

struct FWorldAsyncTraceState

Remarks

This encapsulate World's async trace functionality. This contains two buffers of trace data buffer and alternates it for each tick.

You can use async trace using following APIs : AsyncLineTrace, AsyncSweep, AsyncOverlap When you use those APIs, it will be saved to AsyncTraceDataFWorldAsyncTraceState contains two buffers to rotate each frame as you might need the result in the next frame However, if you do not get the result by next frame, the result will be discarded. Use Delegate if you would like to get the result right away when available.

Variables

Name Description

Public variable

int32

 

CurrentFrame

Used as counter for Buffer swap for DataBuffer. Right now it's only 2, but it can change.

Public variable

AsyncTraceData[...

 

DataBuffer

Async Trace Data Buffer Array. For now we only saves 2 frames.

Constructors

Name Description

Public function

FWorldAsyncTraceState()

Functions

Name Description

Public function

AsyncTraceDa...

 

GetBufferForCurrentFrame()

Get the Buffer for Current Frame

Public function

AsyncTraceDa...

 

GetBufferForFrame

(
    int32 Frame
)

Get the Buffer for input Frame

Public function

AsyncTraceDa...

 

GetBufferForPreviousFrame()

Get the Buffer for Previous Frame

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss