Model.morphhypermorphvector#

Model.morphhypermorphvector(collectionhand, vec, sym, con, mag)#

Creates shapes in the direction of a vector for handles on the collection.

Parameters:
  • collectionhand (Collection) – The collection containing the handle entities to create shapes.

  • vec (hwTriple) – The hwTriple object defining the vector components. User can also supply a Python list of three doubles.

  • sym (int) –

    0 - Do not use symmetry

    1 - Use symmetry

  • con (int) –

    0 - Do not use constraints

    1 - Use constraints

  • mag (double) – Magnitude of perturbation.

Example#

Create a shape for each handle on the collction in the direction of the specified vector at the given magnitude. If symmetry is used, all handles linked to the handles in the collection by symmetry will also be perturbed. If constraints are used, they will be applied to the perturbations#
import hm
import hm.entities as ent

model = hm.Model()

model.morphhypermorphvector(
collectionhand=hm.CollectionByInteractiveSelection(model, ent.Handle),
vec=[1.0, 0.0, 0.0],
sym=1,
con=1,
mag=5.0,
)