TOctree

An octree.

Windows
MacOS
Linux

Inheritance Hierarchy

Syntax

template<typename ElementType, typename OctreeSemantics>
class TOctree

Remarks

An octree.

Constructors

Name Description

Public function

TOctree()

DO NOT USE. This constructor is for internal usage only for hot-reload purposes.

Public function

TOctree

(
    const FVector& InOrigin,
    float InExtent
)

Initialization constructor.

Functions

Name Description

Public function

void

 

AddElement

(
    typename TTypeTraits< ElementType >...
)

Adds an element to the octree.

Public function

void

 

ApplyOffset

(
    const FVector& InOffset,
    bool bGlobalOctree
)

Apply an arbitrary offset to all elements in the tree InOffset - offset to apply bGlobalOctree - hint that this octree is used as a boundless global volume, so only content will be shifted but not origin of the octree

Public function

void

 

Destroy()

Public function

void

 

DumpStats()

Writes stats for the octree to the log.

Public function

ElementType ...

 

GetElementById

(
    FOctreeElementId ElementId
)

Accesses an octree element by ID.

Public function Const

const Elemen...

 

GetElementById

(
    FOctreeElementId ElementId
)

Accesses an octree element by ID.

Public function Const

float

 

GetNodeLevelExtent

(
    int32 Level
)

Public function Const

FBoxCenterAn...

 

GetRootBounds()

Public function Const

SIZE_T

 

GetSizeBytes()

Public function Const

bool

 

IsValidElementId

(
    FOctreeElementId ElementId
)

Checks if given ElementId represents a valid Octree element

Public function

void

 

RemoveElement

(
    FOctreeElementId ElementId
)

Removes an element from the octree.

Public function

void

 

ShrinkElements()

Classes

Name

Description

Public class

FNode

A node in the octree.

Public class

FNodeReference

A reference to an octree node, its context, and a read lock.

Public class

TConstElementBoxIterator

Iterates over the elements in the octree that intersect a bounding box.

Public class

TConstIterator

An octree node iterator.

Typedefs

Name

Description

DefaultStackAllocator

The default iterator allocator gives the stack enough inline space to contain a path and its siblings from root to leaf.

ElementArrayType

ElementConstIt

References

Module

Engine

Header

Runtime/Engine/Public/GenericOctree.h

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