BornAgain
1.19.0
Simulate and fit neutron and x-ray scattering at grazing incidence
|
Basic class for all shapes in 2D. More...
Public Member Functions | |
IShape2D (const char *name) | |
virtual IShape2D * | clone () const =0 |
virtual bool | contains (const Bin1D &binx, const Bin1D &biny) const =0 |
Returns true if area defined by two bins is inside or on border of polygon (more precisely, if mid point of two bins satisfy this condition). More... | |
virtual bool | contains (double x, double y) const =0 |
Returns true if point with given coordinates is inside or on border of the shape. More... | |
virtual void | transferToCPP () |
Used for Python overriding of clone (see swig/tweaks.py) More... | |
Protected Member Functions | |
virtual void | print (std::ostream &ostr) const |
Private Attributes | |
const char *const | m_name |
Friends | |
std::ostream & | operator<< (std::ostream &ostr, const IShape2D &shape) |
Basic class for all shapes in 2D.
Definition at line 27 of file IShape2D.h.
|
inline |
Definition at line 29 of file IShape2D.h.
|
pure virtual |
Implements ICloneable.
Implemented in Rectangle, Polygon, HorizontalLine, VerticalLine, Line, InfinitePlane, and Ellipse.
Referenced by DetectorMask::addMask().
Returns true if area defined by two bins is inside or on border of polygon (more precisely, if mid point of two bins satisfy this condition).
Implemented in Rectangle, Polygon, HorizontalLine, VerticalLine, Line, Ellipse, and InfinitePlane.
|
pure virtual |
Returns true if point with given coordinates is inside or on border of the shape.
Implemented in InfinitePlane, Rectangle, Polygon, HorizontalLine, VerticalLine, Line, and Ellipse.
Referenced by DetectorMask::process_masks().
|
inlineprotectedvirtual |
|
inlinevirtualinherited |
Used for Python overriding of clone (see swig/tweaks.py)
Definition at line 34 of file ICloneable.h.
|
friend |
Definition at line 39 of file IShape2D.h.
|
private |
Definition at line 49 of file IShape2D.h.
Referenced by print().