Model.smoothelements#

Model.smoothelements(faceindex, smoothmethod, iterations)#

In the automeshing module, applies the specified smoothing operator to the mesh (if any) found on the face for the given number of times.

Parameters:
  • faceindex (unsigned int) – The index of the face into the particular surface under consideration.

  • smoothmethod (int) –

    The smoothing method to use. Valid values are:

    0 - autodecide

    1 - size corrected

    2 - shape corrected

  • iterations (int) – The number of times to apply the element smoothing operator.

Example#

Smoothen the elements of the mesh of the first face of the surface twenty - five times , use whichever algorithm the automeshing module determines is proper#
import hm
import hm.entities as ent

model = hm.Model()

model.smoothelements(faceindex=1, smoothmethod=0, iterations=25)