Adds a listener to an event type.
When an event of the type pType fires, the callback pListener will be called. This function
returns a unique string id that may be used in removeEventListenerById to allow simple
listener removal.
It is possible to add an object that will be included in the callback to avoid creating too many closures.
Calling twice addEventListener with the same parameters results in the second call to be ignored,
only unique pairs callback / object are allowed, in order to avoid calling multiple times the same
thing.
The id of the inserted callback (actually an UUID).
Adds a listener to an event type.
When an event of the type pType fires, the callback pListener will be called. This function
returns a unique string id that may be used in removeEventListenerById to allow simple
listener removal.
The id of the inserted callback (actually an UUID).
Gets rid of this object.
After this call, this object can no longer be used.
If the object is an InfiniteObjectDispatcherInterface, then the InfiniteObjectDispatcherInterfaceSignal.ObjectDisposed signal is emitted.
Further uses of the object (with the exception of isDisposed, getInfiniteObjectType and application id retrieval) will log a message with LogLevel.LL_UsingDisposedObject.
Tells the type of the given interface.
The type of the given interface.
Gets the current cut plane id that is manipulated or hovered on.
0 if no cut plane is currently selected, or the selected cut plane id.
Gets the CutPlaneManipulatorInterface snapped rotation angle.
This calls returns a number if the rotation is constrained to be a multiple of the given value
or undefined if no constraint is set.
The current snapped value in radian if the constraint is set, or undefined if no constraint.
Tells if the EventDispatcher has such a callback registered for the given event type.
true if such a listener is installed for the given type of event.
Tells if this object has been gotten rid off.
true if dispose has been called on this object.
Removes a listener from an event type.
If no such listener is found, then the function returns false and does nothing. You must use the exact parameters that were used in addEventListener to actually remove the listener.
The listener function that gets removed.
The listener object that was used when addEventListener was called.
true if the callback was removed else false.
Removes a listener from an event type.
If no such listener is found, then the function returns false and does nothing. You must use the exact parameters that were used in addEventListener to actually remove the listener.
The listener function that gets removed.
true if the callback was removed else false.
Removes a listener by its id.
If no such listener is found, then the function returns false and does nothing. You must use the return value of addEventListener to actually remove the listener.
true if the callback was removed else false.
Sets the cut plane id to manipulate.
Setting the id 0 is valid, it effectively unbinds the cut plane manipulator from a cut plane.
Setting an invalid id to the cut plane manipulator does nothing.
Setting the same id has no effect.
Returns true if the cut plane id exists or if 0 is set.
true if the cut plane corresponding to the id is valid or 0.
Sets the CutPlaneManipulatorInterface to set a rotation angle to be a multiple of a given value.
Setting a number will set the actual multiple value, setting undefined removes the constraint. Setting a negative or zero value is not allowed.
Returns true if the call succeeded.
The snap value to set in radian, or undefined if no value should be set.
trueif the call succeeded.
The CutPlaneManipulatorInterface interface is used to manipulate cut planes.
This is a GUI element that allows an end-user to modify the orientation/position of a cut plane.
The usage is very simple :
Depending on the number of cut planes set by setCutPlaneId, the rendering of the cut plane manipulator may be :
The CutPlaneManipulatorInterface may also be set to snap rotation values to a multiple of a given value (in radian) with setSnapRotationValue.
The user may know when the bound cut plane is modified through the CutPlaneManagerInterfaceSignal from the CutPlaneManagerInterface. She is also notified when a user interaction is started / finished with CutPlaneManipulatorInterfaceSignal signals.
See