Mantid
Loading...
Searching...
No Matches
Classes | Public Types | Public Member Functions | Private Attributes | List of all members
Mantid::Geometry::detail::ShapeInfo Class Reference

#include <ShapeInfo.h>

Classes

struct  ConeGeometry
 
struct  CuboidGeometry
 
struct  CylinderGeometry
 
struct  HexahedronGeometry
 
struct  HollowCylinderGeometry
 
struct  SphereGeometry
 

Public Types

enum class  GeometryShape {
  NOSHAPE = 0 , CUBOID , HEXAHEDRON , SPHERE ,
  CYLINDER , CONE , HOLLOWCYLINDER
}
 

Public Member Functions

ConeGeometry coneGeometry () const
 
CuboidGeometry cuboidGeometry () const
 
CylinderGeometry cylinderGeometry () const
 
void getObjectGeometry (GeometryShape &shape, std::vector< Kernel::V3D > &points, double &innerRadius, double &radius, double &height) const
 
double height () const
 
HexahedronGeometry hexahedronGeometry () const
 
HollowCylinderGeometry hollowCylinderGeometry () const
 
double innerRadius () const
 
bool operator== (const ShapeInfo &other)
 
const std::vector< Kernel::V3D > & points () const
 
double radius () const
 
void setCone (const Kernel::V3D &center, const Kernel::V3D &symmetryAxis, double radius, double height)
 sets the geometry handler for a cone More...
 
void setCuboid (const Kernel::V3D &, const Kernel::V3D &, const Kernel::V3D &, const Kernel::V3D &)
 sets the geometry handler for a cuboid More...
 
void setCylinder (const Kernel::V3D &centerBottomBase, const Kernel::V3D &symmetryAxis, double radius, double height)
 sets the geometry handler for a cylinder More...
 
void setHexahedron (const Kernel::V3D &, const Kernel::V3D &, const Kernel::V3D &, const Kernel::V3D &, const Kernel::V3D &, const Kernel::V3D &, const Kernel::V3D &, const Kernel::V3D &)
 sets the geometry handler for a hexahedron More...
 
void setHollowCylinder (const Kernel::V3D &centreBottomBase, const Kernel::V3D &symmetryAxis, double innerRadius, double outerRadius, double height)
 sets the geometry handler for a hollow cylinder More...
 
void setSphere (const Kernel::V3D &center, double radius)
 sets the geometry handler for a sphere More...
 
GeometryShape shape () const
 
 ShapeInfo ()
 
 ShapeInfo (const ShapeInfo &)=default
 
SphereGeometry sphereGeometry () const
 

Private Attributes

double m_height
 height for cone, cylinder and hollow cylinder; More...
 
double m_innerRadius
 Inner radius for hollow cylinder. More...
 
std::vector< Kernel::V3Dm_points
 
double m_radius
 Radius for the sphere, cone and cylinder; Also outer radius for hollow cylinder;. More...
 
GeometryShape m_shape
 

Detailed Description

Definition at line 26 of file ShapeInfo.h.

Member Enumeration Documentation

◆ GeometryShape

Enumerator
NOSHAPE 
CUBOID 

CUBOID.

HEXAHEDRON 

HEXAHEDRON.

SPHERE 

SPHERE.

CYLINDER 

CYLINDER.

CONE 

CONE.

HOLLOWCYLINDER 

HOLLOW CYLINDER.

Definition at line 28 of file ShapeInfo.h.

Constructor & Destructor Documentation

◆ ShapeInfo() [1/2]

Mantid::Geometry::detail::ShapeInfo::ShapeInfo ( )

Definition at line 16 of file ShapeInfo.cpp.

◆ ShapeInfo() [2/2]

Mantid::Geometry::detail::ShapeInfo::ShapeInfo ( const ShapeInfo )
default

References std::operator==().

Member Function Documentation

◆ coneGeometry()

ShapeInfo::ConeGeometry Mantid::Geometry::detail::ShapeInfo::coneGeometry ( ) const

Definition at line 63 of file ShapeInfo.cpp.

References CONE, m_height, m_points, m_radius, and m_shape.

◆ cuboidGeometry()

ShapeInfo::CuboidGeometry Mantid::Geometry::detail::ShapeInfo::cuboidGeometry ( ) const

Definition at line 38 of file ShapeInfo.cpp.

References CUBOID, m_points, and m_shape.

Referenced by Mantid::Geometry::RandomPoint::inCuboid().

◆ cylinderGeometry()

ShapeInfo::CylinderGeometry Mantid::Geometry::detail::ShapeInfo::cylinderGeometry ( ) const

◆ getObjectGeometry()

void Mantid::Geometry::detail::ShapeInfo::getObjectGeometry ( ShapeInfo::GeometryShape shape,
std::vector< Kernel::V3D > &  points,
double &  innerRadius,
double &  radius,
double &  height 
) const

◆ height()

double Mantid::Geometry::detail::ShapeInfo::height ( ) const

Definition at line 23 of file ShapeInfo.cpp.

References m_height.

Referenced by getObjectGeometry(), setCone(), setCylinder(), and setHollowCylinder().

◆ hexahedronGeometry()

ShapeInfo::HexahedronGeometry Mantid::Geometry::detail::ShapeInfo::hexahedronGeometry ( ) const

Definition at line 43 of file ShapeInfo.cpp.

References HEXAHEDRON, m_points, and m_shape.

◆ hollowCylinderGeometry()

ShapeInfo::HollowCylinderGeometry Mantid::Geometry::detail::ShapeInfo::hollowCylinderGeometry ( ) const

◆ innerRadius()

double Mantid::Geometry::detail::ShapeInfo::innerRadius ( ) const

Definition at line 25 of file ShapeInfo.cpp.

References m_innerRadius.

Referenced by getObjectGeometry(), and setHollowCylinder().

◆ operator==()

bool Mantid::Geometry::detail::ShapeInfo::operator== ( const ShapeInfo other)

Definition at line 118 of file ShapeInfo.cpp.

References m_height, m_points, m_radius, m_shape, and Mantid::Kernel::Tolerance.

◆ points()

const std::vector< Kernel::V3D > & Mantid::Geometry::detail::ShapeInfo::points ( ) const

Definition at line 19 of file ShapeInfo.cpp.

References m_points.

Referenced by getObjectGeometry().

◆ radius()

double Mantid::Geometry::detail::ShapeInfo::radius ( ) const

Definition at line 21 of file ShapeInfo.cpp.

References m_radius.

Referenced by getObjectGeometry(), setCone(), setCylinder(), and setSphere().

◆ setCone()

void Mantid::Geometry::detail::ShapeInfo::setCone ( const Kernel::V3D center,
const Kernel::V3D symmetryAxis,
double  radius,
double  height 
)

sets the geometry handler for a cone

Definition at line 101 of file ShapeInfo.cpp.

References CONE, height(), m_height, m_innerRadius, m_points, m_radius, m_shape, and radius().

Referenced by Mantid::Geometry::ShapeFactory::createGeometryHandler().

◆ setCuboid()

void Mantid::Geometry::detail::ShapeInfo::setCuboid ( const Kernel::V3D p1,
const Kernel::V3D p2,
const Kernel::V3D p3,
const Kernel::V3D p4 
)

sets the geometry handler for a cuboid

Definition at line 68 of file ShapeInfo.cpp.

References CUBOID, m_height, m_innerRadius, m_points, m_radius, and m_shape.

Referenced by Mantid::Geometry::ShapeFactory::createGeometryHandler().

◆ setCylinder()

void Mantid::Geometry::detail::ShapeInfo::setCylinder ( const Kernel::V3D centerBottomBase,
const Kernel::V3D symmetryAxis,
double  radius,
double  height 
)

sets the geometry handler for a cylinder

Definition at line 93 of file ShapeInfo.cpp.

References centerBottomBase, CYLINDER, height(), m_height, m_innerRadius, m_points, m_radius, m_shape, and radius().

Referenced by Mantid::Geometry::ShapeFactory::createGeometryHandler().

◆ setHexahedron()

void Mantid::Geometry::detail::ShapeInfo::setHexahedron ( const Kernel::V3D p1,
const Kernel::V3D p2,
const Kernel::V3D p3,
const Kernel::V3D p4,
const Kernel::V3D p5,
const Kernel::V3D p6,
const Kernel::V3D p7,
const Kernel::V3D p8 
)

sets the geometry handler for a hexahedron

Definition at line 76 of file ShapeInfo.cpp.

References HEXAHEDRON, m_height, m_innerRadius, m_points, m_radius, and m_shape.

Referenced by Mantid::Geometry::ShapeFactory::createGeometryHandler(), and Mantid::Geometry::ShapeFactory::createHexahedralShape().

◆ setHollowCylinder()

void Mantid::Geometry::detail::ShapeInfo::setHollowCylinder ( const Kernel::V3D centreBottomBase,
const Kernel::V3D symmetryAxis,
double  innerRadius,
double  outerRadius,
double  height 
)

sets the geometry handler for a hollow cylinder

Definition at line 109 of file ShapeInfo.cpp.

References height(), HOLLOWCYLINDER, innerRadius(), m_height, m_innerRadius, m_points, m_radius, and m_shape.

Referenced by Mantid::Geometry::ShapeFactory::createGeometryHandler().

◆ setSphere()

void Mantid::Geometry::detail::ShapeInfo::setSphere ( const Kernel::V3D center,
double  radius 
)

sets the geometry handler for a sphere

Definition at line 85 of file ShapeInfo.cpp.

References m_height, m_innerRadius, m_points, m_radius, m_shape, radius(), and SPHERE.

Referenced by Mantid::Geometry::ShapeFactory::createGeometryHandler(), and Mantid::Geometry::ShapeFactory::createSphere().

◆ shape()

ShapeInfo::GeometryShape Mantid::Geometry::detail::ShapeInfo::shape ( ) const

Definition at line 27 of file ShapeInfo.cpp.

References m_shape.

Referenced by getObjectGeometry(), and Mantid::Geometry::RenderingHelpers::renderShape().

◆ sphereGeometry()

ShapeInfo::SphereGeometry Mantid::Geometry::detail::ShapeInfo::sphereGeometry ( ) const

Definition at line 48 of file ShapeInfo.cpp.

References m_points, m_radius, m_shape, and SPHERE.

Referenced by Mantid::Geometry::RandomPoint::inSphere().

Member Data Documentation

◆ m_height

double Mantid::Geometry::detail::ShapeInfo::m_height
private

◆ m_innerRadius

double Mantid::Geometry::detail::ShapeInfo::m_innerRadius
private

Inner radius for hollow cylinder.

Definition at line 83 of file ShapeInfo.h.

Referenced by getObjectGeometry(), hollowCylinderGeometry(), innerRadius(), setCone(), setCuboid(), setCylinder(), setHexahedron(), setHollowCylinder(), and setSphere().

◆ m_points

std::vector<Kernel::V3D> Mantid::Geometry::detail::ShapeInfo::m_points
private

◆ m_radius

double Mantid::Geometry::detail::ShapeInfo::m_radius
private

Radius for the sphere, cone and cylinder; Also outer radius for hollow cylinder;.

Definition at line 80 of file ShapeInfo.h.

Referenced by coneGeometry(), cylinderGeometry(), getObjectGeometry(), hollowCylinderGeometry(), operator==(), radius(), setCone(), setCuboid(), setCylinder(), setHexahedron(), setHollowCylinder(), setSphere(), and sphereGeometry().

◆ m_shape

GeometryShape Mantid::Geometry::detail::ShapeInfo::m_shape
private

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