|
ACTS
Experiment-independent tracking
|
The NavigationStream is a container for the navigation candidates that are currentlu processed in a given context. More...
#include <Acts/Navigation/NavigationStream.hpp>
Classes | |
| struct | QueryPoint |
| The query point for the navigation stream. More... | |
Public Member Functions | |
| void | addPortalCandidate (const Portal &portal) |
| Fill one portal into the candidate vector. | |
| void | addSurfaceCandidate (const Surface &surface, const BoundaryTolerance &bTolerance) |
| Fill one surface into the candidate vector. | |
| void | addSurfaceCandidates (std::span< const Surface * > surfaces, const BoundaryTolerance &bTolerance) |
| Fill n surfaces into the candidate vector. | |
| std::span< NavigationTarget > | candidates () |
| Non-const access the candidate vector. | |
| std::span< const NavigationTarget > | candidates () const |
| Const access the candidate vector. | |
| NavigationTarget & | currentCandidate () |
| Non-const access the current candidate. | |
| const NavigationTarget & | currentCandidate () const |
| Const access the current candidate. | |
| const std::optional< std::size_t > & | currentIndex () const |
| Current Index. | |
| bool | initialize (const GeometryContext &gctx, const NavigationStream::QueryPoint &queryPoint, const Logger &logger, double onSurfaceTolerance=s_onSurfaceTolerance, bool candidatesAreUnique=false) |
| Initialize the stream from a query point. | |
| bool | isValid () const |
| Performs the validity check on the navigation current navigation candidate index. | |
| std::size_t | remainingCandidates () const |
| The number of active candidates. | |
| void | reserve (const std::size_t n) |
| Preallocate the memory to store a certain amount of candidates. | |
| void | reset (const bool keepBoundLess=false) |
| Reset the navigation stream by clearing all candidates and resetting the index. | |
| bool | switchToNextCandidate () |
| Switch to next next candidate. | |
| bool | update (const GeometryContext &gctx, const NavigationStream::QueryPoint &queryPoint, const Logger &logger, double onSurfaceTolerance=s_onSurfaceTolerance) |
| Convenience method to update a stream from a new query point, this could be called from navigation delegates that do not require a local state or from the navigator on the target stream. | |
The NavigationStream is a container for the navigation candidates that are currentlu processed in a given context.
The context could be local to a volume, or global to an entire track following.
The current candidates are stored in a vector of candidates, where an index is used to indicate the current active candidate.
| void Acts::NavigationStream::addPortalCandidate | ( | const Portal & | portal | ) |
Fill one portal into the candidate vector.
| portal | the portals that are filled in |
| void Acts::NavigationStream::addSurfaceCandidate | ( | const Surface & | surface, |
| const BoundaryTolerance & | bTolerance ) |
Fill one surface into the candidate vector.
| surface | the surface to be filled |
| bTolerance | the boundary tolerance used for the intersection |
| void Acts::NavigationStream::addSurfaceCandidates | ( | std::span< const Surface * > | surfaces, |
| const BoundaryTolerance & | bTolerance ) |
Fill n surfaces into the candidate vector.
| surfaces | the surfaces that are filled in |
| bTolerance | the boundary tolerance used for the intersection |
| std::span< NavigationTarget > Acts::NavigationStream::candidates | ( | ) |
Non-const access the candidate vector.
| std::span< const NavigationTarget > Acts::NavigationStream::candidates | ( | ) | const |
Const access the candidate vector.
| NavigationTarget & Acts::NavigationStream::currentCandidate | ( | ) |
Non-const access the current candidate.
This will throw and out of bounds exception if the stream is not valid anymore.
| const NavigationTarget & Acts::NavigationStream::currentCandidate | ( | ) | const |
Const access the current candidate.
| const std::optional< std::size_t > & Acts::NavigationStream::currentIndex | ( | ) | const |
Current Index.
| bool Acts::NavigationStream::initialize | ( | const GeometryContext & | gctx, |
| const NavigationStream::QueryPoint & | queryPoint, | ||
| const Logger & | logger, | ||
| double | onSurfaceTolerance = s_onSurfaceTolerance, | ||
| bool | candidatesAreUnique = false ) |
Initialize the stream from a query point.
| gctx | is the geometry context |
| queryPoint | holds current position, direction, etc. |
| logger | is the navigator's logger |
| onSurfaceTolerance | is the tolerance for on-surface intersections |
| candidatesAreUnique | the caller guarantees that no surface was added more than once, so the pre-intersection de-duplication pass can be skipped. Candidates that intersect the same surface twice (multi-intersections) are still handled correctly. |
This method will first de-duplicate the candidates on basis of the surface pointer to make sure that the multi-intersections are handled correctly. This will allow intializeStream() to be called even as a re-initialization and still work correctly with at one time valid candidates.
| bool Acts::NavigationStream::isValid | ( | ) | const |
Performs the validity check on the navigation current navigation candidate index.
| std::size_t Acts::NavigationStream::remainingCandidates | ( | ) | const |
The number of active candidates.
| void Acts::NavigationStream::reserve | ( | const std::size_t | n | ) |
Preallocate the memory to store a certain amount of candidates.
| n | The number of candidates to be stored |
| void Acts::NavigationStream::reset | ( | const bool | keepBoundLess = false | ) |
Reset the navigation stream by clearing all candidates and resetting the index.
This clears the candidates vector and resets the current index to 0.
| keepBoundLess | Flag to toggle whether unreached boundless navigation targets remain in the stream |
| bool Acts::NavigationStream::switchToNextCandidate | ( | ) |
Switch to next next candidate.
| bool Acts::NavigationStream::update | ( | const GeometryContext & | gctx, |
| const NavigationStream::QueryPoint & | queryPoint, | ||
| const Logger & | logger, | ||
| double | onSurfaceTolerance = s_onSurfaceTolerance ) |
Convenience method to update a stream from a new query point, this could be called from navigation delegates that do not require a local state or from the navigator on the target stream.
| gctx | is the geometry context |
| queryPoint | holds current position, direction, etc. |
| logger | is the navigator's logger |
| onSurfaceTolerance | is the tolerance for on-surface intersections |