SEARCH
TOOLBOX
LANGUAGES
How to create data dependencies

How to create data dependencies

From SOFAWiki

Jump to: navigation, search

Data values can be linked in SOFA as follow:

<Node name="Group">
	<Object type="BoxROI" name="box_roi" box="0 0 0 1 1 1" drawSize="0"/>
	<Object type="FixedConstraint" indices="@[-1].indices" drawSize="0"/>
</Node>

In the example, the Data indices gets its value from another Data in the graph.

indices="@[-1].indices"

The notation used is described below:

  • @: The value of the Data is linked to another Data (Data Parent) in the graph.
  • [-1] : Relative position of the object where the Data Parent is declared (BoxROI in the example).

NOTE: The object searched can be found as well by name.

indices="@box_roi.indices"
  • . : Divide the object and the Data Parent.
  • indices : Data Parent.