Mantid
|
ReferenceFrame : Holds reference frame information from the geometry description file. More...
#include <ReferenceFrame.h>
Public Member Functions | |
Handedness | getHandedness () const |
Gets the handedness. More... | |
bool | isVectorPointingAlongBeam (const Mantid::Kernel::V3D &v) const |
Test whether or not a vector is in the beam direction. More... | |
std::string | origin () const |
Gets the origin. More... | |
PointingAlong | pointingAlongBeam () const |
Gets the beam pointing along direction. More... | |
std::string | pointingAlongBeamAxis () const |
Pointing along beam axis as a string. More... | |
PointingAlong | pointingHorizontal () const |
Gets the pointing horizontal direction, i.e perpendicular to up & along beam. More... | |
std::string | pointingHorizontalAxis () const |
Pointing horizontal to beam as a string. More... | |
PointingAlong | pointingUp () const |
Gets the pointing up direction. More... | |
std::string | pointingUpAxis () const |
Pointing up axis as a string. More... | |
ReferenceFrame () | |
Default constructor. More... | |
ReferenceFrame (PointingAlong up, PointingAlong alongBeam, Handedness handedness, std::string origin) | |
Constructor. More... | |
ReferenceFrame (PointingAlong up, PointingAlong alongBeam, PointingAlong thetaSign, Handedness handedness, std::string origin) | |
Alternative constructor with theta sign axis. More... | |
Mantid::Kernel::V3D | vecPointingAlongBeam () const |
Convert along beam axis into a 3D direction. More... | |
Mantid::Kernel::V3D | vecPointingHorizontal () const |
Convert along horizontal axis into a 3D direction. More... | |
Mantid::Kernel::V3D | vecPointingUp () const |
Convert up axis into a 3D direction. More... | |
Mantid::Kernel::V3D | vecThetaSign () const |
Convert along the axis defining the 2theta sign. More... | |
virtual | ~ReferenceFrame ()=default |
Destructor. More... | |
Private Member Functions | |
ReferenceFrame & | operator= (const ReferenceFrame &) |
Disabled assignment. More... | |
Private Attributes | |
PointingAlong | m_alongBeam |
Beam pointing along axis. More... | |
Handedness | m_handedness |
Handedness. More... | |
std::string | m_origin |
Origin. More... | |
PointingAlong | m_thetaSign |
Axis defining the 2theta sign. More... | |
PointingAlong | m_up |
Pointing up axis. More... | |
Mantid::Kernel::V3D | m_vecPointingAlongBeam |
Vector pointing along the beam. More... | |
Mantid::Kernel::V3D | m_vecPointingUp |
Vector pointing up instrument. More... | |
Mantid::Kernel::V3D | m_vecThetaSign |
Vector denoting the direction defining the 2theta sign. More... | |
ReferenceFrame : Holds reference frame information from the geometry description file.
Definition at line 26 of file ReferenceFrame.h.
Mantid::Geometry::ReferenceFrame::ReferenceFrame | ( | ) |
Mantid::Geometry::ReferenceFrame::ReferenceFrame | ( | PointingAlong | up, |
PointingAlong | alongBeam, | ||
Handedness | handedness, | ||
std::string | origin | ||
) |
Constructor.
Constructor specifying thetaSign=up.
up | :pointing up axis |
alongBeam | : axis pointing along the beam |
handedness | : Handedness |
origin | : origin |
Definition at line 62 of file ReferenceFrame.cpp.
Mantid::Geometry::ReferenceFrame::ReferenceFrame | ( | PointingAlong | up, |
PointingAlong | alongBeam, | ||
PointingAlong | thetaSign, | ||
Handedness | handedness, | ||
std::string | origin | ||
) |
Alternative constructor with theta sign axis.
Constructor specifying all attributes.
up | : pointing up axis |
alongBeam | : axis pointing along the beam |
thetaSign | : axis defining the sign of 2theta |
handedness | : Handedness |
origin | : origin |
Definition at line 73 of file ReferenceFrame.cpp.
References m_alongBeam, m_thetaSign, m_up, m_vecPointingAlongBeam, m_vecPointingUp, and m_vecThetaSign.
|
virtualdefault |
Destructor.
Handedness Mantid::Geometry::ReferenceFrame::getHandedness | ( | ) | const |
Gets the handedness.
Definition at line 143 of file ReferenceFrame.cpp.
References m_handedness.
Referenced by Mantid::DataHandling::SetSample::createFlatPlateHolderXML().
bool Mantid::Geometry::ReferenceFrame::isVectorPointingAlongBeam | ( | const Mantid::Kernel::V3D & | v | ) | const |
Test whether or not a vector is in the beam direction.
Convenience method for checking whether or not a vector is aligned with the along beam vector.
v | vector to be tested against along beam vector |
Definition at line 180 of file ReferenceFrame.cpp.
References m_vecPointingAlongBeam, Mantid::Kernel::normalize(), and Mantid::Kernel::V3D::scalar_prod().
|
private |
Disabled assignment.
std::string Mantid::Geometry::ReferenceFrame::origin | ( | ) | const |
Gets the origin.
Definition at line 148 of file ReferenceFrame.cpp.
References m_origin.
PointingAlong Mantid::Geometry::ReferenceFrame::pointingAlongBeam | ( | ) | const |
Gets the beam pointing along direction.
Definition at line 96 of file ReferenceFrame.cpp.
References m_alongBeam.
Referenced by Mantid::DataHandling::SetSample::createFlatPlateHolderXML(), Mantid::DataHandling::SetSample::createFlatPlateXML(), and export_ReferenceFrame().
std::string Mantid::Geometry::ReferenceFrame::pointingAlongBeamAxis | ( | ) | const |
Pointing along beam axis as a string.
Get the axis label for the pointing along direction.
Definition at line 108 of file ReferenceFrame.cpp.
References m_alongBeam.
Referenced by export_ReferenceFrame().
PointingAlong Mantid::Geometry::ReferenceFrame::pointingHorizontal | ( | ) | const |
Gets the pointing horizontal direction, i.e perpendicular to up & along beam.
Definition at line 121 of file ReferenceFrame.cpp.
References m_alongBeam, m_up, Mantid::Geometry::X, Mantid::Geometry::Y, and Mantid::Geometry::Z.
Referenced by Mantid::DataHandling::SetSample::createFlatPlateHolderXML(), Mantid::DataHandling::SetSample::createFlatPlateXML(), pointingHorizontalAxis(), and vecPointingHorizontal().
std::string Mantid::Geometry::ReferenceFrame::pointingHorizontalAxis | ( | ) | const |
Pointing horizontal to beam as a string.
Get the axis label for the pointing horizontal direction.
Definition at line 115 of file ReferenceFrame.cpp.
References pointingHorizontal().
Referenced by export_ReferenceFrame().
PointingAlong Mantid::Geometry::ReferenceFrame::pointingUp | ( | ) | const |
Gets the pointing up direction.
Definition at line 91 of file ReferenceFrame.cpp.
References m_up.
Referenced by Mantid::DataHandling::SetSample::createCylinderLikeXML(), Mantid::DataHandling::SetSample::createFlatPlateXML(), and export_ReferenceFrame().
std::string Mantid::Geometry::ReferenceFrame::pointingUpAxis | ( | ) | const |
Pointing up axis as a string.
Get the axis label for the pointing up direction.
Definition at line 102 of file ReferenceFrame.cpp.
References m_up.
Referenced by export_ReferenceFrame().
V3D Mantid::Geometry::ReferenceFrame::vecPointingAlongBeam | ( | ) | const |
Convert along beam axis into a 3D direction.
Getter for the along beam vector.
Definition at line 166 of file ReferenceFrame.cpp.
References m_vecPointingAlongBeam.
Referenced by export_ReferenceFrame().
V3D Mantid::Geometry::ReferenceFrame::vecPointingHorizontal | ( | ) | const |
Convert along horizontal axis into a 3D direction.
Calculate the horizontal vector.
Definition at line 172 of file ReferenceFrame.cpp.
References pointingHorizontal().
V3D Mantid::Geometry::ReferenceFrame::vecPointingUp | ( | ) | const |
Convert up axis into a 3D direction.
Getter for the up instrument direction.
Definition at line 154 of file ReferenceFrame.cpp.
References m_vecPointingUp.
Referenced by export_ReferenceFrame().
V3D Mantid::Geometry::ReferenceFrame::vecThetaSign | ( | ) | const |
Convert along the axis defining the 2theta sign.
Getter for the direction defining the theta sign.
Definition at line 160 of file ReferenceFrame.cpp.
References m_vecThetaSign.
|
private |
Beam pointing along axis.
Definition at line 71 of file ReferenceFrame.h.
Referenced by pointingAlongBeam(), pointingAlongBeamAxis(), pointingHorizontal(), and ReferenceFrame().
|
private |
|
private |
|
private |
Axis defining the 2theta sign.
Definition at line 73 of file ReferenceFrame.h.
Referenced by ReferenceFrame().
|
private |
Pointing up axis.
Definition at line 69 of file ReferenceFrame.h.
Referenced by pointingHorizontal(), pointingUp(), pointingUpAxis(), and ReferenceFrame().
|
private |
Vector pointing along the beam.
Definition at line 79 of file ReferenceFrame.h.
Referenced by isVectorPointingAlongBeam(), ReferenceFrame(), and vecPointingAlongBeam().
|
private |
Vector pointing up instrument.
Definition at line 81 of file ReferenceFrame.h.
Referenced by ReferenceFrame(), and vecPointingUp().
|
private |
Vector denoting the direction defining the 2theta sign.
Definition at line 83 of file ReferenceFrame.h.
Referenced by ReferenceFrame(), and vecThetaSign().