Main Content

copy

Copy all properties from another actor

Since R2022b

    Description

    copy(self,other) copies the contents of the actor specified by other to the actor object self.

    copy(self,other,copyChildren) additionally copies the children of the actor.

    copy(self,other,copyChildren,useSourcePosition) also provides an option for the source actor to retain its location.

    Input Arguments

    collapse all

    Actor object, specified as a sim3d.Actor object, which is the destination actor to which a copy is made.

    Example: copy(actor1,actor2)

    Actor object, specified as a sim3d.Actor object. This object is the source actor from which properties are copied.

    Option to copy children from other to self, specified as either 1 (true) or 0 (false). If true, the copy function copies all children and their properties from the specified source. If false, the function does not copy these properties.

    Data Types: logical

    Option for source actor to retain its location, specified as either 1 (true) or 0 (false). When true, the copy function leaves the position of self (translation, rotation) as-is.

    Example: copy(actor1, actor2, false, true)

    Data Types: logical

    Version History

    Introduced in R2022b

    See Also

    | |