Skip to content

@ue-too/dynamics / index / QuadTree

クラス: QuadTree<T> ​

定義: quadtree.ts:36

QuadTree spatial indexing structure for efficient collision detection.

型パラメーター ​

T ​

T extends QuadTreeObject

実装 ​

コンストラクター ​

コンストラクター ​

new QuadTree<T>(level, bounds): QuadTree<T>

定義: quadtree.ts:45

パラメータ ​

level ​

number

bounds ​

RectangleBound

戻り値 ​

QuadTree<T>

メソッド ​

clear() ​

clear(): void

定義: quadtree.ts:70

戻り値 ​

void

の実装 ​

SpatialIndex.clear


draw() ​

draw(context): void

定義: quadtree.ts:52

パラメータ ​

context ​

CanvasRenderingContext2D

戻り値 ​

void

の実装 ​

SpatialIndex.draw


getIndex() ​

getIndex(vBody): -1 | 0 | 1 | 2 | 3

定義: quadtree.ts:121

パラメータ ​

vBody ​

T

戻り値 ​

-1 | 0 | 1 | 2 | 3


insert() ​

insert(vBody): void

定義: quadtree.ts:148

パラメータ ​

vBody ​

T

戻り値 ​

void

の実装 ​

SpatialIndex.insert


retrieve() ​

retrieve(vBody): T[]

定義: quadtree.ts:183

パラメータ ​

vBody ​

T

戻り値 ​

T[]

の実装 ​

SpatialIndex.retrieve


split() ​

split(): void

定義: quadtree.ts:81

戻り値 ​

void