| Constructor and Description |
|---|
Sphere()
Constructor.
|
Sphere(double radius)
Constructor.
|
Sphere(double radius,
int numSlices,
int numStacks)
Constructor.
|
Sphere(LengthParameter size) |
Sphere(LengthParameter size,
int numSlices,
int numStacks) |
Sphere(Vector3d center,
double radius,
int numSlices,
int numStacks)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
Vector3d |
getCenter()
Gets the center.
|
int |
getNumSlices()
Gets the num slices.
|
int |
getNumStacks()
Gets the num stacks.
|
PropertyStorage |
getProperties()
Returns the property storage of this primitive.
|
double |
getRadius()
Gets the radius.
|
Sphere |
setCenter(Vector3d center)
Sets the center.
|
Sphere |
setNumSlices(int numSlices)
Sets the num slices.
|
Sphere |
setNumStacks(int numStacks)
Sets the num stacks.
|
Sphere |
setRadius(double radius)
Sets the radius.
|
java.util.List<Polygon> |
toPolygons()
Returns the polygons that define this primitive.
|
public Sphere()
public Sphere(double radius)
radius - sphare radiuspublic Sphere(LengthParameter size)
public Sphere(LengthParameter size, int numSlices, int numStacks)
public Sphere(double radius,
int numSlices,
int numStacks)
radius - sphare radiusnumSlices - number of slicesnumStacks - number of stackspublic Sphere(Vector3d center, double radius, int numSlices, int numStacks)
center - center of the sphereradius - sphere radiusnumSlices - number of slicesnumStacks - number of stackspublic java.util.List<Polygon> toPolygons()
PrimitiveCSG object.toPolygons in class Primitivepublic Vector3d getCenter()
public Sphere setCenter(Vector3d center)
center - the center to setpublic double getRadius()
public Sphere setRadius(double radius)
radius - the radius to setpublic int getNumSlices()
public Sphere setNumSlices(int numSlices)
numSlices - the numSlices to setpublic int getNumStacks()
public Sphere setNumStacks(int numStacks)
numStacks - the numStacks to setpublic PropertyStorage getProperties()
PrimitivegetProperties in class Primitive