OPAL (Object Oriented Parallel Accelerator Library)  2021.1.99
OPAL
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
ElementBase::BoundingBox Struct Reference

#include <ElementBase.h>

Collaboration diagram for ElementBase::BoundingBox:
Collaboration graph
[legend]

Public Member Functions

void getCombinedBoundingBox (const BoundingBox &other)
 
bool isInside (const Vector_t &) const
 
void print (std::ostream &) const
 
boost::optional< Vector_tgetPointOfIntersection (const Vector_t &position, const Vector_t &direction) const
 

Static Public Member Functions

static BoundingBox getBoundingBox (const std::vector< Vector_t > &points)
 

Public Attributes

Vector_t lowerLeftCorner
 
Vector_t upperRightCorner
 

Detailed Description

Definition at line 341 of file ElementBase.h.

Member Function Documentation

◆ getBoundingBox()

ElementBase::BoundingBox ElementBase::BoundingBox::getBoundingBox ( const std::vector< Vector_t > &  points)
static

◆ getCombinedBoundingBox()

void ElementBase::BoundingBox::getCombinedBoundingBox ( const BoundingBox other)
inline

Definition at line 347 of file ElementBase.h.

References lowerLeftCorner, max(), min(), and upperRightCorner.

Referenced by OrbitThreader::computeBoundingBox(), and OrbitThreader::updateBoundingBoxWithCurrentPosition().

Here is the call graph for this function:

◆ getPointOfIntersection()

boost::optional< Vector_t > ElementBase::BoundingBox::getPointOfIntersection ( const Vector_t position,
const Vector_t direction 
) const

Computes the intersection point between a bounding box and the ray which has the direction 'direction' and starts at the position 'position'. If the position is inside the box then the algorithm should find an inter- section point.

Parameters
positionthe position where the ray starts
directionthe direction of the ray

Definition at line 357 of file ElementBase.cpp.

References abs(), Physics::e, and euclidean_norm().

Referenced by OrbitThreader::computeDriftLengthToBoundingBox().

Here is the call graph for this function:

◆ isInside()

bool ElementBase::BoundingBox::isInside ( const Vector_t position) const

Definition at line 342 of file ElementBase.cpp.

◆ print()

void ElementBase::BoundingBox::print ( std::ostream &  out) const

Definition at line 427 of file ElementBase.cpp.

References endl().

Here is the call graph for this function:

Member Data Documentation

◆ lowerLeftCorner

Vector_t ElementBase::BoundingBox::lowerLeftCorner

◆ upperRightCorner

Vector_t ElementBase::BoundingBox::upperRightCorner

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