The algorithm proceeds as follows: 1) Initializes filter. 2) If bounds have not been set, obtains bounds from data_in . 3) Calculates range of the bounds . 4) Calculates the aspect ratio of the data_out from the bounds and dimensions . 5) Calculates the origin of the data_out . 6) Allocates the scalars for the data_out . 7) Initializes the scalars to an absolute maximum distance. The absolute maximum is calcualted from the bounds and fractional maximum distance. 8) For each triangle, calculates the distance from the triangle face, edge or vertex to each point in the structured point set that is within the specified distance threshold.
data_out is a data set that will contain distances to the triangles. If a data set is not specified, one will be created.
maximum_distance is a threshold on the distance to the triangles. It is also used to control the extent of the sampling volume around each triangle. NOTE: the
object's speed is VERY sensitive to the threshold. The threshold is specified as a fraction of the implicit modeller's bounds.
bounds contains the x, y, z min's and max's of the data set. If not specified, the bounds of the input display data will be used.
dimensions specifies the dimensions in x, y, and z of the output data set.
initialize! sets up the class for a series of append:'s Must be eventually followed by a done!.
append:display_data appends the distances to the display data to the current data set. A series of append:'s must be preceeded by an initialize!.
done! terminates a sequence of append:'s.
/* Create a display data */ sphere_modeller new: asphere;
/* An implicit modeller */ implicit_modeller new: animplicit dimensions=(20,20,20) data_in=asphere maximum_distance= .1 ;
/* Extract an iso surface */ data_iso_surface new: aniso data_in= animplicit values=.05 ;
/* We need a modeller */ display_all new: ada data_in= aniso ;
/* An actor */ actor new: atri modeller=ada;
/* And finally a renderer */ renderer new: aren actors=atri;
/* Show it off */ aren render!;