visualization-tools

Home > @visualization-tools/core > IHitTestComponent

IHitTestComponent interface

A component to test if an entity is under the cursor / finger.

Signature:

export interface IHitTestComponent<TUpdateArg, TTraits extends IHitTestableTrait, TComponentState> 

Methods

Method Description
hitTest(entity, dataId, position, updateArg) Perform the test.
index(entity, updateArg, componentState) Where a hit test requires generating / modifying a data structure, this can be done here.