smooth module

Package for dealing with smoothing functions for the AmpObject mesh Copyright: Joshua Steer 2020, Joshua.Steer@soton.ac.uk

class smoothMixin

Bases: object

hc_smooth(n=1, beta=0.6, brim=True)

Function to apply a Humphrey’s Classes smooth to the mesh. Note, this assumes that alpha=0 (ie the original point through the iteration has no effect). If beta=1, then this effectively acts as the Laplacian smooth

Parameters:
  • n (int, default 1) – number of iterations of smoothing
  • beta (float, default 0.6) – scalar between [0, 1] which dictates influence of distance from adjacent to original point. If beta=1, then this effectively acts as the Laplacian smooth
  • brim (bool, default True) – If true, then this will not smooth the vertices on the brim
lp_smooth(n=1, brim=True)

Function to apply a Laplacian smooth to the mesh. This method replaces each vertex with the mean of its connected neighbours

Parameters:n (int, default 1) – number of iterations of smoothing
smoothValues(n=1)

Function to apply a simple Laplacian smooth to the values array. Identical to the vertex smoothing except it applies the smoothing to the values

Parameters:n (int, default 1) – number of iterations of smoothing