compund objects

Hi !

When I create a compund object, does this create a completley new object or does it still reference the objects that make up the compound ?

As it looks most other operations create a completley new object without any references to the source objects used in the operation and if this is the case, is it possible to create a compund object in a way so that it does reference the original objects.

The reason is that by doing this, you could modify the original objects and this would show up in the compund object. This is pretty usefull in a 3D modeler, it can of course be done anyway, but this would be much slower, because the compound object would need to be recreated every time one of the source objects change.

I assume that compound objects is the best/only way to create compound/composite objects (a group of objects that are transformed and otherwise treated as one singel entity).


Yves Fricaud's picture


A compound is a set of Shapes , this compound references the original objects. But a rule in cascade topology is that you never modify a shape, you have always to build a new Shape with the modifications.

So you can't update a compound whith propagation of a shape modification, you have to build a new one. This rule has many advantages and the time to rebuild new shape with modifications is generally very small in comparaison of the time to compute the modifications.

In fact a compound is a collection of shapes. In cascade There are other possibilities to manage a collection of shapes (see package TopTools).