Model.morphhypermorph#

Model.morphhypermorph(collectionhand, xi, yi, zi, xx, yy, zz, sys, sym, con)#

Creates shapes with xyz perturbations for handles on the collection.

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

  • xi (int) –

    0 - Do not create x perturbation

    1 - Create x perturbation

  • yi (int) –

    0 - Do not create y perturbation

    1 - Create y perturbation

  • zi (int) –

    0 - Do not create z perturbation

    1 - Create z perturbation

  • xx (double) – x perturbation magnitude.

  • yy (double) – y perturbation magnitude.

  • zz (double) – z perturbation magnitude.

  • sys (int) – System to create perturbations in (default = global)

  • sym (int) –

    0 - Do not use symmetry

    1 - Use symmetry

  • con (int) –

    0 - Do not use constraints

    1 - Use constraints

Example#

Create a shape for each handle on the collection for each specified direction at the given magnitudes for the specified system. If symmetry is used, all handles linked to marked handles 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.morphhypermorph(
collectionhand=hm.CollectionByInteractiveSelection(model, ent.Handle),
xi=0,
yi=0,
zi=1,
xx=1.0,
yy=1.0,
zz=5.0,
sys=3,
sym=1,
con=1,
)