Open topic with navigation
<link>.setMask
Set mask
mask
A combination of the following values:
viz.LINK_POS | Pass position information from the source to the destination. |
viz.LINK_ORI | Pass orientation information from the source to the destination. |
viz.LINK_SCALE | Pass scale information from the source to the destination. |
viz.LINK_ALL | Pass all available information from the source to the destination. A combination of all the above values. |
Remarks
This command will set the type mask for the link. The type mask is used to control which information is passed from the source object to the destination object. The default mask for a link is (viz.LINK_POS | viz.LINK_ORI).
For information to be passed from the source to the destination it must pass three tests:
1) The specified type must be set in the source mask
2) The specified type must be set in the destination mask
3) The specified type must be set in the link mask
The user cannot change the source or destination mask, those values are fixed.
Example:
You have a sensor which only outputs position data. The source mask will be viz.LINK_POS (i.e. The sensor is only capable of outputing position data)
You have a node which you want to link to the sensor. The destination mask will be viz.LINK_POS|viz.LINK_ORI|viz.LINK_SCALE (i.e. The node is capable of receiving position, orientation, and scale data)
You create a link between the objects and set the link mask to viz.LINK_POS|viz.LINK_ORI (i.e. You only want position and orientation data to be passed on). However, only the position of the node will be updated since the viz.LINK_ORI option does not pass the above 3 tests (It is not specified in the source mask of the sensor).
Return Value
None
See also