Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## toxi.geom
Class AxisAlignedCylinder

    java.lang.Object
      toxi.geom.AxisAlignedCylinder

All Implemented Interfaces:
  Shape3D

Direct Known Subclasses:
  XAxisCylinder, YAxisCylinder, ZAxisCylinder

    public abstract class AxisAlignedCylinder

extends java.lang.Object
implements Shape3D

Method Summary
`abstract boolean` | `containsPoint(ReadonlyVec3D p)` Checks if the given point is inside the cylinder.
`float` | `getLength()`
`abstract Vec3D.Axis` | `getMajorAxis()`
`Vec3D` | `getPosition()` Returns the cylinder's position (centroid).
`float` | `getRadius()`
`void` | `setLength(float length)`
`void` | `setPosition(Vec3D pos)`
`void` | `setRadius(float radius)`
`Mesh3D` | `toMesh()` Builds a TriangleMesh representation of the cylinder at a default resolution 30 degrees.
`Mesh3D` | `toMesh(int steps, float thetaOffset)` Builds a TriangleMesh representation of the cylinder using the given number of steps and start angle offset.
`Mesh3D` | `toMesh(Mesh3D mesh, int steps, float thetaOffset)`

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Method Detail

### containsPoint

    public abstract boolean containsPoint(ReadonlyVec3D p)

  Checks if the given point is inside the cylinder.

  Specified by:
    `containsPoint` in interface `Shape3D`
  Parameters:
    `p` -
  Returns:
    true, if inside

### getLength

    public float getLength()

  Returns:
    the length

### getMajorAxis

    public abstract Vec3D.Axis getMajorAxis()

  Returns:
    the cylinder's orientation axis

### getPosition

    public Vec3D getPosition()

  Returns the cylinder's position (centroid).

  Returns:
    the pos

### getRadius

    public float getRadius()

  Returns:
    the cylinder radius

### setLength

    public void setLength(float length)

  Parameters:
    `length` - the length to set

### setPosition

    public void setPosition(Vec3D pos)

  Parameters:
    `pos` - the pos to set

### setRadius

    public void setRadius(float radius)

  Parameters:
    `radius` -

### toMesh

    public Mesh3D toMesh()

  Builds a TriangleMesh representation of the cylinder at a default resolution 30 degrees.

  Returns:
    mesh instance

### toMesh

    public Mesh3D toMesh(int steps,
                         float thetaOffset)

  Builds a TriangleMesh representation of the cylinder using the given number of steps and start angle offset.

  Parameters:
    `steps` -
    `thetaOffset` -
  Returns:
    mesh

### toMesh

    public Mesh3D toMesh(Mesh3D mesh,
                         int steps,
                         float thetaOffset)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD