Open3D (C++ API)
All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Member Functions | Static Public Member Functions | Data Fields
open3d::geometry::OrientedBoundingBox Class Reference

#include <BoundingVolume.h>

Inheritance diagram for open3d::geometry::OrientedBoundingBox:
open3d::geometry::Geometry3D open3d::geometry::Geometry

Public Member Functions

 OrientedBoundingBox ()
 
 ~OrientedBoundingBox () override
 
OrientedBoundingBoxClear () override
 
bool IsEmpty () const override
 
virtual Eigen::Vector3d GetMinBound () const override
 
virtual Eigen::Vector3d GetMaxBound () const override
 
virtual Eigen::Vector3d GetCenter () const override
 
virtual AxisAlignedBoundingBox GetAxisAlignedBoundingBox () const override
 
virtual OrientedBoundingBox GetOrientedBoundingBox () const override
 
virtual OrientedBoundingBoxTransform (const Eigen::Matrix4d &transformation) override
 
virtual OrientedBoundingBoxTranslate (const Eigen::Vector3d &translation, bool relative=true) override
 
virtual OrientedBoundingBoxScale (const double scale, bool center=true) override
 
virtual OrientedBoundingBoxRotate (const Eigen::Vector3d &rotation, bool center=true, RotationType type=RotationType::XYZ) override
 
double Volume () const
 
std::vector< Eigen::Vector3d > GetBoxPoints () const
 
- Public Member Functions inherited from open3d::geometry::Geometry3D
 ~Geometry3D () override
 
- Public Member Functions inherited from open3d::geometry::Geometry
virtual ~Geometry ()
 
GeometryType GetGeometryType () const
 
int Dimension () const
 

Static Public Member Functions

static OrientedBoundingBox CreateFromAxisAlignedBoundingBox (const AxisAlignedBoundingBox &aabox)
 
static OrientedBoundingBox CreateFromPoints (const std::vector< Eigen::Vector3d > &points)
 

Data Fields

Eigen::Vector3d center_
 
Eigen::Vector3d x_axis_
 
Eigen::Vector3d y_axis_
 
Eigen::Vector3d z_axis_
 
Eigen::Vector3d color_
 

Additional Inherited Members

- Public Types inherited from open3d::geometry::Geometry3D
enum  RotationType {
  RotationType::XYZ, RotationType::YZX, RotationType::ZXY, RotationType::XZY,
  RotationType::ZYX, RotationType::YXZ, RotationType::AxisAngle
}
 
- Public Types inherited from open3d::geometry::Geometry
enum  GeometryType {
  GeometryType::Unspecified = 0, GeometryType::PointCloud = 1, GeometryType::VoxelGrid = 2, GeometryType::Octree = 3,
  GeometryType::LineSet = 4, GeometryType::TriangleMesh = 5, GeometryType::HalfEdgeTriangleMesh = 6, GeometryType::Image = 7,
  GeometryType::RGBDImage = 8, GeometryType::TetraMesh = 9, GeometryType::OrientedBoundingBox = 10, GeometryType::AxisAlignedBoundingBox = 11
}
 
- Protected Member Functions inherited from open3d::geometry::Geometry3D
 Geometry3D (GeometryType type)
 
Eigen::Vector3d ComputeMinBound (const std::vector< Eigen::Vector3d > &points) const
 
Eigen::Vector3d ComputeMaxBound (const std::vector< Eigen::Vector3d > &points) const
 
Eigen::Vector3d ComputeCenter (const std::vector< Eigen::Vector3d > &points) const
 
void ResizeAndPaintUniformColor (std::vector< Eigen::Vector3d > &colors, const size_t size, const Eigen::Vector3d &color) const
 
void TransformPoints (const Eigen::Matrix4d &transformation, std::vector< Eigen::Vector3d > &points) const
 
void TransformNormals (const Eigen::Matrix4d &transformation, std::vector< Eigen::Vector3d > &normals) const
 
void TranslatePoints (const Eigen::Vector3d &translation, std::vector< Eigen::Vector3d > &points, bool relative) const
 
void ScalePoints (const double scale, std::vector< Eigen::Vector3d > &points, bool center) const
 
void RotatePoints (const Eigen::Vector3d &rotation, std::vector< Eigen::Vector3d > &points, bool center, RotationType type) const
 
void RotateNormals (const Eigen::Vector3d &rotation, std::vector< Eigen::Vector3d > &normals, bool center, RotationType type) const
 
Eigen::Matrix3d GetRotationMatrix (const Eigen::Vector3d &rotation, RotationType type=RotationType::XYZ) const
 
- Protected Member Functions inherited from open3d::geometry::Geometry
 Geometry (GeometryType type, int dimension)
 

Constructor & Destructor Documentation

◆ OrientedBoundingBox()

open3d::geometry::OrientedBoundingBox::OrientedBoundingBox ( )
inline

◆ ~OrientedBoundingBox()

open3d::geometry::OrientedBoundingBox::~OrientedBoundingBox ( )
inlineoverride

Member Function Documentation

◆ Clear()

OrientedBoundingBox & open3d::geometry::OrientedBoundingBox::Clear ( )
overridevirtual

◆ CreateFromAxisAlignedBoundingBox()

OrientedBoundingBox open3d::geometry::OrientedBoundingBox::CreateFromAxisAlignedBoundingBox ( const AxisAlignedBoundingBox aabox)
static

◆ CreateFromPoints()

OrientedBoundingBox open3d::geometry::OrientedBoundingBox::CreateFromPoints ( const std::vector< Eigen::Vector3d > &  points)
static

Creates an oriented bounding box using a PCA. Note, that this is only an approximation to the minimum oriented bounding box that could be computed for example with O'Rourke's algorithm (cf. http://cs.smith.edu/~jorourke/Papers/MinVolBox.pdf, https://www.geometrictools.com/Documentation/MinimumVolumeBox.pdf)

◆ GetAxisAlignedBoundingBox()

AxisAlignedBoundingBox open3d::geometry::OrientedBoundingBox::GetAxisAlignedBoundingBox ( ) const
overridevirtual

◆ GetBoxPoints()

std::vector< Eigen::Vector3d > open3d::geometry::OrientedBoundingBox::GetBoxPoints ( ) const

◆ GetCenter()

Eigen::Vector3d open3d::geometry::OrientedBoundingBox::GetCenter ( ) const
overridevirtual

◆ GetMaxBound()

Eigen::Vector3d open3d::geometry::OrientedBoundingBox::GetMaxBound ( ) const
overridevirtual

◆ GetMinBound()

Eigen::Vector3d open3d::geometry::OrientedBoundingBox::GetMinBound ( ) const
overridevirtual

◆ GetOrientedBoundingBox()

OrientedBoundingBox open3d::geometry::OrientedBoundingBox::GetOrientedBoundingBox ( ) const
overridevirtual

◆ IsEmpty()

bool open3d::geometry::OrientedBoundingBox::IsEmpty ( ) const
overridevirtual

◆ Rotate()

OrientedBoundingBox & open3d::geometry::OrientedBoundingBox::Rotate ( const Eigen::Vector3d &  rotation,
bool  center = true,
RotationType  type = RotationType::XYZ 
)
overridevirtual

◆ Scale()

OrientedBoundingBox & open3d::geometry::OrientedBoundingBox::Scale ( const double  scale,
bool  center = true 
)
overridevirtual

◆ Transform()

OrientedBoundingBox & open3d::geometry::OrientedBoundingBox::Transform ( const Eigen::Matrix4d &  transformation)
overridevirtual

◆ Translate()

OrientedBoundingBox & open3d::geometry::OrientedBoundingBox::Translate ( const Eigen::Vector3d &  translation,
bool  relative = true 
)
overridevirtual

◆ Volume()

double open3d::geometry::OrientedBoundingBox::Volume ( ) const

Field Documentation

◆ center_

Eigen::Vector3d open3d::geometry::OrientedBoundingBox::center_

◆ color_

Eigen::Vector3d open3d::geometry::OrientedBoundingBox::color_

◆ x_axis_

Eigen::Vector3d open3d::geometry::OrientedBoundingBox::x_axis_

◆ y_axis_

Eigen::Vector3d open3d::geometry::OrientedBoundingBox::y_axis_

◆ z_axis_

Eigen::Vector3d open3d::geometry::OrientedBoundingBox::z_axis_

The documentation for this class was generated from the following files: