NEST main@caf0ae8
 
Loading...
Searching...
No Matches
nest::Mask< D > Class Template Referenceabstract

Abstract base class for masks with given dimension. More...

#include <mask.h>

Inheritance diagram for nest::Mask< D >:
[legend]
Collaboration diagram for nest::Mask< D >:
[legend]

Public Member Functions

 ~Mask () override
 
virtual bool inside (const Position< D > &) const =0
 
bool inside (const std::vector< double > &pt) const override
 
virtual bool inside (const Box< D > &) const =0
 
virtual bool outside (const Box< D > &b) const
 
virtual Box< D > get_bbox () const =0
 The whole mask is inside (i.e., false everywhere outside) the bounding box.
 
virtual Mask * clone () const =0
 Clone method.
 
AbstractMask * intersect_mask (const AbstractMask &other) const override
 Create the intersection of this mask with another.
 
AbstractMask * union_mask (const AbstractMask &other) const override
 Create the union of this mask with another.
 
AbstractMask * minus_mask (const AbstractMask &other) const override
 Create the difference of this mask and another.
 
virtual bool inside (const std::vector< double > &) const=0
 
- Public Member Functions inherited from nest::AbstractMask
virtual ~AbstractMask ()
 
virtual Dictionary get_dict () const
 

Detailed Description

template<int D>
class nest::Mask< D >

Abstract base class for masks with given dimension.

Constructor & Destructor Documentation

◆ ~Mask()

template<int D>
nest::Mask< D >::~Mask ( )
inlineoverride

Member Function Documentation

◆ clone()

template<int D>
virtual Mask * nest::Mask< D >::clone ( ) const
pure virtual

◆ get_bbox()

template<int D>
virtual Box< D > nest::Mask< D >::get_bbox ( ) const
pure virtual

The whole mask is inside (i.e., false everywhere outside) the bounding box.

Returns
bounding box

Implemented in nest::AllMask< D >, nest::IntersectionMask< D >, nest::UnionMask< D >, nest::DifferenceMask< D >, nest::ConverseMask< D >, nest::AnchoredMask< D >, nest::BoxMask< D >, nest::BallMask< D >, and nest::EllipseMask< D >.

◆ inside() [1/4]

template<int D>
virtual bool nest::Mask< D >::inside ( const Box< D > &  ) const
pure virtual
Returns
true if the whole box is inside the mask.
Note
a return value of false is not a guarantee that the whole box is not inside the mask.

Implemented in nest::AllMask< D >, nest::BallMask< D >, nest::EllipseMask< D >, nest::IntersectionMask< D >, nest::UnionMask< D >, nest::DifferenceMask< D >, nest::ConverseMask< D >, nest::AnchoredMask< D >, and nest::BoxMask< D >.

◆ inside() [2/4]

template<int D>
virtual bool nest::Mask< D >::inside ( const Position< D > &  ) const
pure virtual

◆ inside() [3/4]

template<int D>
virtual bool nest::AbstractMask::inside ( const std::vector< double > &  ) const
virtual
Returns
true if point is inside mask.

Implements nest::AbstractMask.

◆ inside() [4/4]

template<int D>
bool nest::Mask< D >::inside ( const std::vector< double > &  pt) const
overridevirtual
Returns
true if point is inside mask.

Implements nest::AbstractMask.

References nest::inside().

Here is the call graph for this function:

◆ intersect_mask()

template<int D>
AbstractMask * nest::Mask< D >::intersect_mask ( const AbstractMask< D > &  other) const
overridevirtual

Create the intersection of this mask with another.

Masks must have the same dimension

Returns
a new dynamically allocated mask.

Implements nest::AbstractMask.

◆ minus_mask()

template<int D>
AbstractMask * nest::Mask< D >::minus_mask ( const AbstractMask< D > &  other) const
overridevirtual

Create the difference of this mask and another.

Masks must have the same dimension.

Returns
a new dynamically allocated mask.

Implements nest::AbstractMask.

◆ outside()

template<int D>
bool nest::Mask< D >::outside ( const Box< D > &  b) const
virtual
Returns
true if the whole box is outside the mask.
Note
a return value of false is not a guarantee that the whole box is not outside the mask.

Reimplemented in nest::AllMask< D >, nest::IntersectionMask< D >, nest::UnionMask< D >, nest::DifferenceMask< D >, nest::ConverseMask< D >, nest::AnchoredMask< D >, nest::BoxMask< D >, nest::BallMask< D >, and nest::EllipseMask< D >.

References nest::Box< D >::lower_left, and nest::Box< D >::upper_right.

◆ union_mask()

template<int D>
AbstractMask * nest::Mask< D >::union_mask ( const AbstractMask< D > &  other) const
overridevirtual

Create the union of this mask with another.

Masks must have the same dimension.

Returns
a new dynamically allocated mask.

Implements nest::AbstractMask.


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