Selection API

instant3Dhub: Selection API
instant3Dhub

Detailed Description

Control which Nodes are selected.

Selection is a basic feature to allow interacting with 3D data. The selection is reflected by changing the material of the corresponding geometry.

Classes

class  FI3DHSelectionAPI
 

Functions

TArray< int32 > AI3DHConnector::GetSelection ()
 
virtual void FI3DHSelectionAPI::AddToSelection (int32 NodeId, TUniqueFunction< void(const TArray< int32 > &Selection, EI3DHErrorCode ErrorCode)> OnComplete)=0
 
virtual void FI3DHSelectionAPI::ClearSelection (TUniqueFunction< void(EI3DHErrorCode ErrorCode)> OnComplete)=0
 
virtual TArray< int32 > FI3DHSelectionAPI::GetSelection ()=0
 

Function Documentation

◆ AddToSelection()

virtual void FI3DHSelectionAPI::AddToSelection ( int32 NodeId,
TUniqueFunction< void(const TArray< int32 > &Selection, EI3DHErrorCode ErrorCode)> OnComplete )
pure virtual

Adds the Node with the matching id to the active selection and returns the new selection.

Returns the pre-existing selection in case of error.

Note
The provided NodeId might not be part of the returned list, as the selection is collapsed to the minimum number of nodes needed to represent it.
Thread-safe. OnComplete is always called on the game thread.
Parameters
NodeIdThe id of the Node that should be added to the selection.
OnCompleteCallback called on completion:

◆ ClearSelection()

virtual void FI3DHSelectionAPI::ClearSelection ( TUniqueFunction< void(EI3DHErrorCode ErrorCode)> OnComplete)
pure virtual

Clear the active selection.

Note
Thread-safe. OnComplete is always called on the game thread.
Parameters
OnCompleteCallback called on completion:

◆ GetSelection() [1/2]

TArray< int32 > AI3DHConnector::GetSelection ( )

Returns a copy of the active selection.

Note
Thread-safe.
Returns
An array containing the IDs of all Nodes in the active selection.

◆ GetSelection() [2/2]

virtual TArray< int32 > FI3DHSelectionAPI::GetSelection ( )
pure virtual

Returns a copy of the active selection.

Note
Thread-safe.
Returns
An array containing the IDs of all Nodes in the active selection.