class Cuboid : public feasst::Shape

A cuboid is given by a center point and side lengths in each dimension. Not fully implemented. Implement as the intersection of 3 perpendicular slabs

Public Functions

Cuboid(const Position &side_lengths, const Position &center)

Construct given side lengths and center.

Cuboid(const Position &side_lengths)

Same as above, but the center is assumed to be the origin (in 3D).

Cuboid(const double cubic_side_length)

Same as above, but all the side lengths are the same (cube, in 3D).

double nearest_distance(const Position &point) const

Return the distance from the point to the nearest point on the surface. The distance is negative if the point is inside of the shape and positive if it is outside.

double surface_area() const

Return the surface area (if implemented).

double volume() const

Return the volume (if implemented).