MinMax2D
Canonical path: NemAll_Python_Geometry.MinMax2D
Representation class for 2D MinMax box.
Deflate
overloaded
Deflate minmax box
Parameters:
-
x
(float
) –Deflate in X axis
-
y
(float
) –Deflate in Y axis
Deflate in x,y axis concurrently
Parameters:
-
size
(float
) –Deflate in x and y axis concurrently
Get
GetSizeX
Get the size of the box in the X direction
Returns:
-
float
–delta X value
GetSizeY
Get the size of the box in the Y direction
Returns:
-
float
–delta Y value
Inflate
overloaded
Inflate minmax box
Parameters:
-
x
(float
) –Inflate in X axis
-
y
(float
) –Inflate in Y axis
Inflate in x,y axis concurrently
Parameters:
-
size
(float
) –Inflate in x and y axis concurrently
IsContaining
overloaded
IsContaining(box: MinMax2D) -> bool
Is box inside this box
Parameters:
-
box
(MinMax2D
) –Potentially contained box
Returns:
-
bool
–true, if is inside, otherwise false
IsContaining(point: Point2D) -> bool
Is point inside this box
Parameters:
-
point
(Point2D
) –point in world coordinate system
Returns:
-
bool
–true, if is inside, otherwise false
Overlaps
Overlaps(box: MinMax2D) -> bool
Does box overlap this box
Parameters:
-
box
(MinMax2D
) –Box
Returns:
-
bool
–true, if boxes overlap, otherwise false
Set
ToPolygon2D
__add__
__eq__
__eq__(min_max: MinMax2D) -> bool
Comparison of min max values.
Be careful, this method work without tolerance!
Parameters:
-
min_max
(MinMax2D
) –min max to be compared.
Returns:
-
bool
–True when min max values are equal, otherwise false.
__getitem__
__getitem__(index: int) -> Point2D
Get the corners of MinMax.
This method is checked and throwing Geometry::Exception when index is out of range.
Parameters:
-
index
(int
) –Corner index (0-left bottom, 1-right bottom, 2-right top, 3-left top)
Returns:
-
Point2D
–corner as Point2D in world coordinate system.
__iadd__
overloaded
__iadd__(box: BoundingBox2D) -> MinMax2D
Expand MinMax2D box.
Expands the MinMax2D box by the bounding box given in parameter box
Parameters:
-
box
(BoundingBox2D
) –Bounding box to be added
Returns:
-
MinMax2D
–minmax box.