Skip to main content

@novorender/api / RenderStateHighlightGroups

Interface: RenderStateHighlightGroups

Defined in: @novorender/src/core3d/state/index.ts:678

Highlight related render state.

Remarks

Highlight comes as a modest performance cost.

Group of objects may be visually highlighted through color transforms, hidden or filtered out. Currently, a maximum of 250 groups may be defined. Any objects that are not part of a highlight group will be treated according to the defaultAction property. This could help save memory when "everything else" needs to be hidden or highlighted.

A particular object can only be rendered using a single highlight. If the object id belongs to multiple groups, the last group in the groups array will determine how it's highlighted.

Hiding a group is more effective than using alpha=0.

Filtering of large group can greatly improve performance and memory consumption. Adding or removing objects to filtered groups will trigger a complete reload of the scene, however. It it thus recommended that this be used for relatively static groups only.

Properties

defaultAction

readonly defaultAction: 
| undefined
| RenderStateGroupAction;

Defined in: @novorender/src/core3d/state/index.ts:682

Highlight action for all objects current not in a highlight group.

Default Value

undefined


defaultPointVisualization

readonly defaultPointVisualization: 
| undefined
| PointVisualization;

Defined in: @novorender/src/core3d/state/index.ts:689

Point visualization for all points current not in a highlight group with point visualization. Undefined will fall back to defualtAction then to color RGBA values.

Default Value

undefined


groups

readonly groups: readonly RenderStateHighlightGroup[];

Defined in: @novorender/src/core3d/state/index.ts:692

Highlight groups, max 250.


textures?

readonly optional textures: ActiveTexturesArray;

Defined in: @novorender/src/core3d/state/index.ts:698

Names of active textures.

Remarks

The textures are downloaded in the background and may take some time to become available.