MeshLib Python Docs
Loading...
Searching...
No Matches
meshlib.mrmeshpy.Box2d Class Reference

Public Member Functions

bool __eq__ (self, Box2d a)
 
None __init__ (self)
 
None __init__ (self, Vector2d min, Vector2d max)
 
None __init__ (self, Box2d arg0)
 
bool __ne__ (self, Box2d a)
 
Vector2d center (self)
 
bool contains (self, Vector2d pt)
 
float diagonal (self)
 
Box2d expanded (self, Vector2d expansion)
 
Vector2d getBoxClosestPointTo (self, Vector2d pt)
 
float getDistanceSq (self, Box2d b)
 
float getDistanceSq (self, Vector2d pt)
 
None include (self, Vector2d pt)
 
None include (self, Box2d b)
 
Box2d insignificantlyExpanded (self)
 
Box2d intersect (self, Box2d b)
 
Box2d intersection (self, Box2d b)
 
bool intersects (self, Box2d b)
 
Vector2d size (self)
 
bool valid (self)
 
float volume (self)
 

Static Public Member Functions

Box2d fromMinAndSize (Vector2d min, Vector2d size)
 

Static Public Attributes

typing elements = 2
 

Protected Member Functions

Vector2d _Subscript (self, int e)
 
Vector2d _Subscript (self, int e)
 

Detailed Description

Generated from:  MR::Box2d
Aliases:  Box_Vector2_double

Box given by its min- and max- corners

Constructor & Destructor Documentation

◆ __init__() [1/3]

None meshlib.mrmeshpy.Box2d.__init__ ( self)
create invalid box by default

◆ __init__() [2/3]

None meshlib.mrmeshpy.Box2d.__init__ ( self,
Vector2d min,
Vector2d max )

◆ __init__() [3/3]

None meshlib.mrmeshpy.Box2d.__init__ ( self,
Box2d arg0 )
Implicit copy constructor.

Member Function Documentation

◆ __eq__()

bool meshlib.mrmeshpy.Box2d.__eq__ ( self,
Box2d a )

◆ __ne__()

bool meshlib.mrmeshpy.Box2d.__ne__ ( self,
Box2d a )

◆ _Subscript() [1/2]

Vector2d meshlib.mrmeshpy.Box2d._Subscript ( self,
int e )
protected
min/max access by 0/1 index

◆ _Subscript() [2/2]

Vector2d meshlib.mrmeshpy.Box2d._Subscript ( self,
int e )
protected

◆ center()

Vector2d meshlib.mrmeshpy.Box2d.center ( self)
computes center of the box

◆ contains()

bool meshlib.mrmeshpy.Box2d.contains ( self,
Vector2d pt )
checks whether given point is inside (including the surface) of the box

◆ diagonal()

float meshlib.mrmeshpy.Box2d.diagonal ( self)
computes length from min to max

◆ expanded()

Box2d meshlib.mrmeshpy.Box2d.expanded ( self,
Vector2d expansion )
decreases min and increased max on given value

◆ fromMinAndSize()

Box2d meshlib.mrmeshpy.Box2d.fromMinAndSize ( Vector2d min,
Vector2d size )
static

◆ getBoxClosestPointTo()

Vector2d meshlib.mrmeshpy.Box2d.getBoxClosestPointTo ( self,
Vector2d pt )
returns closest point in the box to given point

◆ getDistanceSq() [1/2]

float meshlib.mrmeshpy.Box2d.getDistanceSq ( self,
Box2d b )
returns squared distance between this box and given one;
returns zero if the boxes touch or intersect

◆ getDistanceSq() [2/2]

float meshlib.mrmeshpy.Box2d.getDistanceSq ( self,
Vector2d pt )
returns squared distance between this box and given point;
returns zero if the point is inside or on the boundary of the box

◆ include() [1/2]

None meshlib.mrmeshpy.Box2d.include ( self,
Box2d b )
minimally increases the box to include another box

◆ include() [2/2]

None meshlib.mrmeshpy.Box2d.include ( self,
Vector2d pt )
minimally increases the box to include given point

◆ insignificantlyExpanded()

Box2d meshlib.mrmeshpy.Box2d.insignificantlyExpanded ( self)
decreases min and increases max to their closest representable value

◆ intersect()

Box2d meshlib.mrmeshpy.Box2d.intersect ( self,
Box2d b )

◆ intersection()

Box2d meshlib.mrmeshpy.Box2d.intersection ( self,
Box2d b )
computes intersection between this and other box

◆ intersects()

bool meshlib.mrmeshpy.Box2d.intersects ( self,
Box2d b )
checks whether this box intersects or touches given box

◆ size()

Vector2d meshlib.mrmeshpy.Box2d.size ( self)
computes size of the box in all dimensions

◆ valid()

bool meshlib.mrmeshpy.Box2d.valid ( self)
true if the box contains at least one point

◆ volume()

float meshlib.mrmeshpy.Box2d.volume ( self)
computes the volume of this box

Member Data Documentation

◆ elements

typing meshlib.mrmeshpy.Box2d.elements = 2
static

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