georegression.struct.shapes
Class Box3D_F64
- java.lang.Object
-
- georegression.struct.shapes.Box3D_F64
-
- All Implemented Interfaces:
- java.io.Serializable
public class Box3D_F64 extends java.lang.Object implements java.io.SerializableAn axis aligned box in 3D that is specified by two points, p0 and p1, the lower and upper extents of the box. Point p0 is less or equal to point p1, 0.x ≤ p1.x, p0.y ≤ p1.y, p0.z ≤ p1.z.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field and Description Point3D_F64p0The lower point/extent.Point3D_F64p1The upper point/extent
-
Constructor Summary
Constructors Constructor and Description Box3D_F64()Box3D_F64(Box3D_F64 orig)Box3D_F64(double x0, double y0, double z0, double x1, double y1, double z1)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description doublearea()The box's area.Point3D_F64center(Point3D_F64 storage)Computes and return the center of the cube.doublegetLengthX()Length of the box along the x-axisdoublegetLengthY()Length of the box along the y-axisdoublegetLengthZ()Length of the box along the z-axisPoint3D_F64getP0()Returns the lower point/extendPoint3D_F64getP1()Returns the upper point/extendvoidset(Box3D_F64 orig)voidset(double x0, double y0, double z0, double x1, double y1, double z1)voidsetP0(Point3D_F64 p0)voidsetP1(Point3D_F64 p1)java.lang.StringtoString()
-
-
-
Field Detail
-
p0
public Point3D_F64 p0
The lower point/extent.
-
p1
public Point3D_F64 p1
The upper point/extent
-
-
Constructor Detail
-
Box3D_F64
public Box3D_F64(double x0, double y0, double z0, double x1, double y1, double z1)
-
Box3D_F64
public Box3D_F64(Box3D_F64 orig)
-
Box3D_F64
public Box3D_F64()
-
-
Method Detail
-
set
public void set(Box3D_F64 orig)
-
set
public void set(double x0, double y0, double z0, double x1, double y1, double z1)
-
area
public double area()
The box's area. area = lengthX*lengthY*lengthZ- Returns:
- area
-
getLengthX
public double getLengthX()
Length of the box along the x-axis- Returns:
- length
-
getLengthY
public double getLengthY()
Length of the box along the y-axis- Returns:
- length
-
getLengthZ
public double getLengthZ()
Length of the box along the z-axis- Returns:
- length
-
getP0
public Point3D_F64 getP0()
Returns the lower point/extend
-
setP1
public void setP1(Point3D_F64 p1)
-
getP1
public Point3D_F64 getP1()
Returns the upper point/extend
-
setP0
public void setP0(Point3D_F64 p0)
-
center
public Point3D_F64 center(Point3D_F64 storage)
Computes and return the center of the cube.- Parameters:
storage- Optional storage for the center. If null a new instance will be created and returned.- Returns:
- The cube's center point
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-
DataMelt 3.0 © DataMelt by jWork.ORG