TQuadTree

Windows
MacOS
Linux

Syntax

template<typename ElementType, int32 NodeCapacity>
class TQuadTree

Constructors

Name Description

Public function

TQuadTree()

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

Public function

TQuadTree

(
    const FBox2D& InBox,
    float InMinimumQuadSize
)

Destructors

Name Description

Public function

~TQuadTree()

Functions

Name Description

Public function Const

void

 

Duplicate

(
    TreeType& OutDuplicate
)

Does a deep copy of the tree by going through and re-creating the internal data.

Public function

void

 

Empty()

Removes all elements of the tree

Public function Const

void

 

GetElements

(
    const FBox2D& Box,
    TArray< ElementType >& ElementsOut
)

Given a 2D box, returns an array of elements within the box.

Public function

const FBox2D...

 

GetTreeBox()

Gets the TreeBox so systems can test insertions before trying to do so with invalid regions

Public function

void

 

Insert

(
    const ElementType& Element,
    const FBox2D& Box,
    const TCHAR* DebugContext
)

Inserts an object of type ElementType with an associated 2D box of size Box (log n).

Public function

bool

 

Remove

(
    const ElementType& Instance,
    const FBox2D& Box
)

Removes an object of type ElementType with an associated 2D box of size Box (log n).

Public function

void

 

Serialize

(
    FArchive& Ar
)

Operators

Name Description

Public function

TreeType &

 

operator=

(
    const TreeType& Other
)

Enums

Name

Description

Private enum

QuadNames

Typedefs

Name

Description

TreeType

References

Module

Engine

Header

Runtime/Engine/Public/GenericQuadTree.h

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