Package com.ardor3d.math.functions
Class ArchimedeanSpiralFunction3D
java.lang.Object
com.ardor3d.math.functions.ArchimedeanSpiralFunction3D
- All Implemented Interfaces:
Function3D
An implementation of an Archimedean spiral which supports any number of spiral arms and optional turbulence.
- See Also:
-
Constructor Summary
ConstructorDescriptionArchimedeanSpiralFunction3D
(int numArms, boolean useDefaultTurbulence) Create the function for the specified number of arms, and optionally use the default turbulence.ArchimedeanSpiralFunction3D
(int numArms, Function3D turbulenceFunction) Create the function for the specified number of arms, with the specified turbulence. -
Method Summary
Modifier and TypeMethodDescriptiondouble
eval
(double x, double y, double z) Evaluate the function.
-
Constructor Details
-
ArchimedeanSpiralFunction3D
public ArchimedeanSpiralFunction3D(int numArms, boolean useDefaultTurbulence) Create the function for the specified number of arms, and optionally use the default turbulence.- Parameters:
numArms
- The number of arms of the spiral (1 or more).useDefaultTurbulence
- True if the default turbulence should be used; false for no turbulence.
-
ArchimedeanSpiralFunction3D
Create the function for the specified number of arms, with the specified turbulence.- Parameters:
numArms
- The number of arms of the spiral (1 or more).turbulenceFunction
- The turbulence function to use (can be null).
-
-
Method Details
-
eval
public double eval(double x, double y, double z) Evaluate the function.- Specified by:
eval
in interfaceFunction3D
- Parameters:
x
- the abscissay
- the ordinatez
- the applicate- Returns:
- A result which is generally, but not always, in the -1 to 1 range.
-