EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Acts::GenericCuboidVolumeBounds Class Reference

#include <acts/blob/sPHENIX/Core/include/Acts/Geometry/GenericCuboidVolumeBounds.hpp>

+ Inheritance diagram for Acts::GenericCuboidVolumeBounds:
+ Collaboration diagram for Acts::GenericCuboidVolumeBounds:

Public Member Functions

 GenericCuboidVolumeBounds ()=delete
 
 GenericCuboidVolumeBounds (const std::array< Acts::Vector3D, 8 > &vertices) noexcept(false)
 
 GenericCuboidVolumeBounds (const std::array< double, eSize > &values) noexcept(false)
 
 ~GenericCuboidVolumeBounds () override=default
 
VolumeBounds::BoundsType type () const final
 
std::vector< double > values () const final
 
bool inside (const Vector3D &gpos, double tol=0.) const override
 
OrientedSurfaces orientedSurfaces (const Transform3D &transform=Transform3D::Identity()) const override
 
Volume::BoundingBox boundingBox (const Transform3D *trf=nullptr, const Vector3D &envelope={0, 0, 0}, const Volume *entity=nullptr) const final
 
std::ostream & toStream (std::ostream &sl) const override
 
void draw (IVisualization3D &helper, const Transform3D &transform=Transform3D::Identity()) const
 
- Public Member Functions inherited from Acts::VolumeBounds
 VolumeBounds ()=default
 
virtual ~VolumeBounds ()=default
 
virtual Vector3D binningOffset (BinningValue bValue) const
 Binning offset - overloaded for some R-binning types.
 
virtual double binningBorder (BinningValue bValue) const
 

Static Public Attributes

static constexpr size_t eSize = 24
 

Private Member Functions

void construct () noexcept(false)
 

Private Attributes

std::array< Vector3D, 8 > m_vertices
 
std::array< Vector3D, 6 > m_normals
 

Additional Inherited Members

- Public Types inherited from Acts::VolumeBounds
enum  BoundsType : int {
  eCone = 0, eCuboid = 1, eCutoutCylinder = 2, eCylinder = 3,
  eGenericCuboid = 4, eTrapezoid = 5, eOther = 6
}
 

Detailed Description

Definition at line 24 of file GenericCuboidVolumeBounds.hpp.

View newest version in sPHENIX GitHub at line 24 of file GenericCuboidVolumeBounds.hpp

Constructor & Destructor Documentation

Acts::GenericCuboidVolumeBounds::GenericCuboidVolumeBounds ( )
delete
Acts::GenericCuboidVolumeBounds::GenericCuboidVolumeBounds ( const std::array< Acts::Vector3D, 8 > &  vertices)
noexcept

Constructor from a set of vertices

Parameters
verticesThe set of input vertices

The ordering is considered to be:

  • the first 4 vertices are the "top" face
  • the second 4 vertices are the "bottom" face
  • both faces are given in counter clock wise order

Definition at line 22 of file GenericCuboidVolumeBounds.cpp.

View newest version in sPHENIX GitHub at line 22 of file GenericCuboidVolumeBounds.cpp

Acts::GenericCuboidVolumeBounds::GenericCuboidVolumeBounds ( const std::array< double, eSize > &  values)
noexcept

Constructor from a fixed size array

Parameters
valuesThe input values
Acts::GenericCuboidVolumeBounds::~GenericCuboidVolumeBounds ( )
overridedefault

Member Function Documentation

Acts::Volume::BoundingBox Acts::GenericCuboidVolumeBounds::boundingBox ( const Transform3D trf = nullptr,
const Vector3D envelope = {0, 0, 0},
const Volume entity = nullptr 
) const
finalvirtual

Construct bounding box for this shape

Parameters
trfOptional transform
envelopeOptional envelope to add / subtract from min/max
entityEntity to associate this bounding box with
Returns
Constructed bounding box

Implements Acts::VolumeBounds.

Definition at line 188 of file GenericCuboidVolumeBounds.cpp.

View newest version in sPHENIX GitHub at line 188 of file GenericCuboidVolumeBounds.cpp

References Acts::Test::transform, and vtx().

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void Acts::GenericCuboidVolumeBounds::construct ( )
privatenoexcept

Private helper method to contruct the Volume bounds to be called by the constructors, from the ordered input vertices

Definition at line 131 of file GenericCuboidVolumeBounds.cpp.

View newest version in sPHENIX GitHub at line 131 of file GenericCuboidVolumeBounds.cpp

References kdfinder::abs(), c, d, and Acts::UnitConstants::e.

+ Here is the call graph for this function:

void Acts::GenericCuboidVolumeBounds::draw ( IVisualization3D helper,
const Transform3D transform = Transform3D::Identity() 
) const

Draw this shape using a visualization helper

Parameters
helperThe visualizatin helper
transformOptional transformation matrix

Definition at line 210 of file GenericCuboidVolumeBounds.cpp.

View newest version in sPHENIX GitHub at line 210 of file GenericCuboidVolumeBounds.cpp

References c, d, and Acts::IVisualization3D::face().

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool Acts::GenericCuboidVolumeBounds::inside ( const Vector3D gpos,
double  tol = 0. 
) const
overridevirtual

Checking if position given in volume frame is inside

Parameters
gposis the global position to be checked
tolis the tolerance applied for the inside check
Returns
boolean indicating if the position is inside

Implements Acts::VolumeBounds.

Definition at line 39 of file GenericCuboidVolumeBounds.cpp.

View newest version in sPHENIX GitHub at line 39 of file GenericCuboidVolumeBounds.cpp

References kdfinder::abs(), m_normals, and m_vertices.

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Acts::OrientedSurfaces Acts::GenericCuboidVolumeBounds::orientedSurfaces ( const Transform3D transform = Transform3D::Identity()) const
overridevirtual

Oriented surfaces, i.e. the decomposed boundary surfaces and the according navigation direction into the volume given the normal vector on the surface

Parameters
transformis the 3D transform to be applied to the boundary surfaces to position them in 3D space

It will throw an exception if the orientation prescription is not adequate

Returns
a vector of surfaces bounding this volume

Implements Acts::VolumeBounds.

Definition at line 58 of file GenericCuboidVolumeBounds.cpp.

View newest version in sPHENIX GitHub at line 58 of file GenericCuboidVolumeBounds.cpp

References Acts::backward, c, d, and Acts::forward.

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE().

+ Here is the caller graph for this function:

std::ostream & Acts::GenericCuboidVolumeBounds::toStream ( std::ostream &  sl) const
overridevirtual
Parameters
slis the output stream to be written into

Implements Acts::VolumeBounds.

Definition at line 119 of file GenericCuboidVolumeBounds.cpp.

View newest version in sPHENIX GitHub at line 119 of file GenericCuboidVolumeBounds.cpp

VolumeBounds::BoundsType Acts::GenericCuboidVolumeBounds::type ( ) const
inlinefinalvirtual

Return the bounds type - for persistency optimization

Returns
is a BoundsType enum

Implements Acts::VolumeBounds.

Definition at line 49 of file GenericCuboidVolumeBounds.hpp.

View newest version in sPHENIX GitHub at line 49 of file GenericCuboidVolumeBounds.hpp

References Acts::VolumeBounds::eGenericCuboid.

std::vector< double > Acts::GenericCuboidVolumeBounds::values ( ) const
finalvirtual

Return the bound values as dynamically sized vector

Returns
this returns a copy of the internal values

Implements Acts::VolumeBounds.

Definition at line 177 of file GenericCuboidVolumeBounds.cpp.

View newest version in sPHENIX GitHub at line 177 of file GenericCuboidVolumeBounds.cpp

Member Data Documentation

constexpr size_t Acts::GenericCuboidVolumeBounds::eSize = 24
static

Definition at line 26 of file GenericCuboidVolumeBounds.hpp.

View newest version in sPHENIX GitHub at line 26 of file GenericCuboidVolumeBounds.hpp

std::array<Vector3D, 6> Acts::GenericCuboidVolumeBounds::m_normals
private

Definition at line 100 of file GenericCuboidVolumeBounds.hpp.

View newest version in sPHENIX GitHub at line 100 of file GenericCuboidVolumeBounds.hpp

Referenced by inside().

std::array<Vector3D, 8> Acts::GenericCuboidVolumeBounds::m_vertices
private

Definition at line 99 of file GenericCuboidVolumeBounds.hpp.

View newest version in sPHENIX GitHub at line 99 of file GenericCuboidVolumeBounds.hpp

Referenced by inside().


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