LibreCAD
|
#include <geoarea.h>
Public Member Functions | |
Area (const Coordinate &coordA, const Coordinate &coordB) | |
Area () | |
Area (const Coordinate &coord, double width, double height) | |
Area given at a coordinate with a given width and height. More... | |
Area & | operator= (const Area &other) |
const Coordinate | minP () const |
const Coordinate | maxP () const |
double | width () const |
width Returns the width of this area More... | |
double | height () const |
height Returns the height of this area More... | |
bool | inArea (const Coordinate &point, double tolerance=0.) const |
Test of a specific point lies within area. More... | |
bool | inArea (const Area &area) const |
inArea test if this object's fits fully in area More... | |
bool | overlaps (const Area &otherArea) const |
overlaps returns true if any overlap is happening between the two area's, even if otherArea fits within this area More... | |
short | numCornersInside (const Area &otherArea) const |
numCornersInside count the number of corners this object has in otherArea More... | |
Area | merge (const Area &other) const |
merge two area's and expand if required to largest containing area More... | |
Area | merge (const Coordinate &other) const |
merge two area's and expand if required to largest containing area More... | |
Area | intersection (const Area &other, double tolerance=0.) const |
merge two area's and expand if required to largest containing area More... | |
Vector | top () const |
top vector of this area More... | |
Vector | left () const |
left vector for this area More... | |
Vector | bottom () const |
bottom vector of this area More... | |
Area | increaseBy (double increaseBy) const |
bool | operator== (const Area &ar) const |
checks for the equality of Area More... | |
Vector | right () const |
right vector of this area More... | |
virtual void | accept (GeoEntityVisitor &v) const override |
![]() | |
virtual | ~Base ()=default |
![]() | |
virtual | ~Visitable ()=default |
Private Attributes | |
Coordinate | _minP |
Coordinate | _maxP |
Friends | |
std::ostream & | operator<< (std::ostream &os, const Area &area) |
|
inlineexplicit |
Create a new Area. The coordinates coordA and coordB will be ordered so that minP will always be < maxP The coordinates are not allowed to describe a volume
CoordA | First coordinate of a area |
CoordB | Second coordinate of a area |
|
inlineexplicit |
Area given at a coordinate with a given width and height.
coordA | |
width | |
height |
Definition at line 43 of file geoarea.h.
|
inlineoverridevirtual |
|
inline |
|
inline |
|
inline |
Test of a specific point lies within area.
point | Point to test against |
|
inline |
|
inline |
merge two area's and expand if required to largest containing area
other | |
tolerance,tolerance | to detect zero size intersection |
|
inline |
|
inline |
Return the highest corner
merge two area's and expand if required to largest containing area
other |
|
inline |
|
inline |
Return the smallest corner (closest to (0,0,0) )
|
inline |
|
inline |
|
inline |
overlaps returns true if any overlap is happening between the two area's, even if otherArea fits within this area
other |
|
inline |
|
inline |
|
inline |
|
friend |
|
private |
|
private |