MeshLib C# Docs
Loading...
Searching...
No Matches

Box given by its min- and max- corners Generated from class MR.Box2d. This is the by-value version of the struct. More...

Inheritance diagram for MR.Box2d:

Public Member Functions

 Box2d (Box2d _other)
 Generated copy constructor.
unsafe Box2d ()
 create invalid box by default
unsafe Box2d (in MR.Vector2d min, in MR.Vector2d max)
 Generated from constructor MR.Box2d.Box2d.
unsafe Box2d (MR.Const_NoInit _1)
 Generated from constructor MR.Box2d.Box2d.
unsafe ref MR.Vector2d index (int e)
 Generated from method MR::Box2d::operator[].
readonly unsafe bool valid ()
 true if the box contains at least one point Generated from method MR.Box2d.valid.
readonly unsafe MR.Vector2d center ()
 computes center of the box Generated from method MR.Box2d.center.
readonly unsafe MR.Vector2d corner (in MR.Vector2b c)
 returns the corner of this box as specified by given bool-vector: 0 element in (c) means take min's coordinate, 1 element in (c) means take max's coordinate Generated from method MR.Box2d.corner.
readonly unsafe MR.Vector2d size ()
 computes size of the box in all dimensions Generated from method MR.Box2d.size.
readonly unsafe double diagonal ()
 computes length from min to max Generated from method MR.Box2d.diagonal.
readonly unsafe double volume ()
 computes the volume of this box Generated from method MR.Box2d.volume.
unsafe void include (in MR.Vector2d pt)
 minimally increases the box to include given point Generated from method MR.Box2d.include.
unsafe void include (in MR.Box2d b)
 minimally increases the box to include another box Generated from method MR.Box2d.include.
readonly unsafe bool contains (in MR.Vector2d pt)
 checks whether given point is inside (including the surface) of this box Generated from method MR.Box2d.contains.
readonly unsafe bool contains (in MR.Box2d otherbox)
 checks whether given box is fully inside (the surfaces may touch) of this box Generated from method MR.Box2d.contains.
readonly unsafe MR.Vector2d getBoxClosestPointTo (in MR.Vector2d pt)
 returns closest point in the box to given point Generated from method MR.Box2d.getBoxClosestPointTo.
readonly unsafe bool intersects (in MR.Box2d b)
 checks whether this box intersects or touches given box Generated from method MR.Box2d.intersects.
readonly unsafe MR.Box2d intersection (in MR.Box2d b)
 computes intersection between this and other box Generated from method MR.Box2d.intersection.
unsafe ref MR.Box2d intersect (in MR.Box2d b)
 Generated from method MR.Box2d.intersect.
readonly unsafe double getDistanceSq (in MR.Box2d b)
 returns squared distance between this box and given one; returns zero if the boxes touch or intersect Generated from method MR.Box2d.getDistanceSq.
readonly unsafe double getDistanceSq (in MR.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 Generated from method MR.Box2d.getDistanceSq.
readonly unsafe MR.Vector2d getProjection (in MR.Vector2d pt)
 returns the closest point on the box to the given point for points outside the box this is equivalent to getBoxClosestPointTo Generated from method MR.Box2d.getProjection.
readonly unsafe MR.Box2d expanded (in MR.Vector2d expansion)
 decreases min and increased max on given value Generated from method MR.Box2d.expanded.
readonly unsafe MR.Box2d insignificantlyExpanded ()
 decreases min and increases max to their closest representable value Generated from method MR.Box2d.insignificantlyExpanded.
bool Equals (MR.Box2d a)
override bool Equals (object? other)

Static Public Member Functions

static implicit operator Box2d (ConstBox_Box2d other)
 Copy contents from a wrapper class to this struct.
static unsafe MR.Box2d fromMinAndSize (in MR.Vector2d min, in MR.Vector2d size)
 Generated from method MR.Box2d.fromMinAndSize.
static unsafe MR.Vector2b getMinBoxCorner (in MR.Vector2d n)
 considering all planes with given normal and arbitrary shift: dot(n,x) = d finds the box's corner for which d is minimal Generated from method MR.Box2d.getMinBoxCorner.
static unsafe MR.Vector2b getMaxBoxCorner (in MR.Vector2d n)
 considering all planes with given normal and arbitrary shift: dot(n,x) = d finds the box's corner for which d is maximal Generated from method MR.Box2d.getMaxBoxCorner.
static unsafe bool operator== (MR.Box2d _this, MR.Box2d a)
 Generated from method MR::Box2d::operator==.
static unsafe bool operator!= (MR.Box2d _this, MR.Box2d a)
static unsafe MR.Box2d __MR_Box2d_Construct_1 (MR.NoInit._Underlying *_1)
static unsafe MR.Box2d __MR_Box2d_Construct_2 (MR.Vector2d *min, MR.Vector2d *max)
static MR.Box2d __MR_Box2d_DefaultConstruct ()
static unsafe MR.Vector2d __MR_Box2d_center (MR.Box2d *_this)
static unsafe byte __MR_Box2d_contains_MR_Box2d (MR.Box2d *_this, MR.Box2d *otherbox)
static unsafe byte __MR_Box2d_contains_MR_Vector2d (MR.Box2d *_this, MR.Vector2d *pt)
static unsafe MR.Vector2d __MR_Box2d_corner (MR.Box2d *_this, MR.Vector2b *c)
static unsafe double __MR_Box2d_diagonal (MR.Box2d *_this)
static unsafe MR.Box2d __MR_Box2d_expanded (MR.Box2d *_this, MR.Vector2d *expansion)
static unsafe MR.Box2d __MR_Box2d_fromMinAndSize (MR.Vector2d *min, MR.Vector2d *size)
static unsafe MR.Vector2d __MR_Box2d_getBoxClosestPointTo (MR.Box2d *_this, MR.Vector2d *pt)
static unsafe double __MR_Box2d_getDistanceSq_MR_Box2d (MR.Box2d *_this, MR.Box2d *b)
static unsafe double __MR_Box2d_getDistanceSq_MR_Vector2d (MR.Box2d *_this, MR.Vector2d *pt)
static unsafe MR.Vector2b __MR_Box2d_getMaxBoxCorner (MR.Vector2d *n)
static unsafe MR.Vector2b __MR_Box2d_getMinBoxCorner (MR.Vector2d *n)
static unsafe MR.Vector2d __MR_Box2d_getProjection (MR.Box2d *_this, MR.Vector2d *pt)
static unsafe void __MR_Box2d_include_MR_Box2d (MR.Box2d *_this, MR.Box2d *b)
static unsafe void __MR_Box2d_include_MR_Vector2d (MR.Box2d *_this, MR.Vector2d *pt)
static unsafe MR.Vector2d * __MR_Box2d_index (MR.Box2d *_this, int e)
static unsafe MR.Vector2d * __MR_Box2d_index_mut (MR.Box2d *_this, int e)
static unsafe MR.Box2d __MR_Box2d_insignificantlyExpanded (MR.Box2d *_this)
static unsafe MR.Box2d * __MR_Box2d_intersect (MR.Box2d *_this, MR.Box2d *b)
static unsafe MR.Box2d __MR_Box2d_intersection (MR.Box2d *_this, MR.Box2d *b)
static unsafe byte __MR_Box2d_intersects (MR.Box2d *_this, MR.Box2d *b)
static unsafe MR.Vector2d __MR_Box2d_size (MR.Box2d *_this)
static unsafe byte __MR_Box2d_valid (MR.Box2d *_this)
static unsafe double __MR_Box2d_volume (MR.Box2d *_this)
static unsafe byte __MR_equal_MR_Box2d (MR.Box2d *_this, MR.Box2d *a)

Public Attributes

MR.Vector2d min
MR.Vector2d max

Properties

readonly unsafe ref readonly MR.Vector2d this[int e] [get]
 min/max access by 0/1 index Generated from method MR::Box2d::operator[].

Detailed Description

Box given by its min- and max- corners Generated from class MR.Box2d. This is the by-value version of the struct.

Constructor & Destructor Documentation

◆ Box2d() [1/4]

MR.Box2d.Box2d ( Box2d _other)
inline

Generated copy constructor.

◆ Box2d() [2/4]

unsafe MR.Box2d.Box2d ( )
inline

create invalid box by default

◆ Box2d() [3/4]

unsafe MR.Box2d.Box2d ( in MR.Vector2d min,
in MR.Vector2d max )
inline

Generated from constructor MR.Box2d.Box2d.

◆ Box2d() [4/4]

unsafe MR.Box2d.Box2d ( MR.Const_NoInit _1)
inline

Generated from constructor MR.Box2d.Box2d.

Member Function Documentation

◆ __MR_Box2d_center()

unsafe MR.Vector2d MR.Box2d.__MR_Box2d_center ( MR.Box2d * _this)
static

◆ __MR_Box2d_Construct_1()

unsafe MR.Box2d MR.Box2d.__MR_Box2d_Construct_1 ( MR.NoInit._Underlying * _1)
static

◆ __MR_Box2d_Construct_2()

unsafe MR.Box2d MR.Box2d.__MR_Box2d_Construct_2 ( MR.Vector2d * min,
MR.Vector2d * max )
static

◆ __MR_Box2d_contains_MR_Box2d()

unsafe byte MR.Box2d.__MR_Box2d_contains_MR_Box2d ( MR.Box2d * _this,
MR.Box2d * otherbox )
static

◆ __MR_Box2d_contains_MR_Vector2d()

unsafe byte MR.Box2d.__MR_Box2d_contains_MR_Vector2d ( MR.Box2d * _this,
MR.Vector2d * pt )
static

◆ __MR_Box2d_corner()

unsafe MR.Vector2d MR.Box2d.__MR_Box2d_corner ( MR.Box2d * _this,
MR.Vector2b * c )
static

◆ __MR_Box2d_DefaultConstruct()

MR.Box2d MR.Box2d.__MR_Box2d_DefaultConstruct ( )
static

◆ __MR_Box2d_diagonal()

unsafe double MR.Box2d.__MR_Box2d_diagonal ( MR.Box2d * _this)
static

◆ __MR_Box2d_expanded()

unsafe MR.Box2d MR.Box2d.__MR_Box2d_expanded ( MR.Box2d * _this,
MR.Vector2d * expansion )
static

◆ __MR_Box2d_fromMinAndSize()

unsafe MR.Box2d MR.Box2d.__MR_Box2d_fromMinAndSize ( MR.Vector2d * min,
MR.Vector2d * size )
static

◆ __MR_Box2d_getBoxClosestPointTo()

unsafe MR.Vector2d MR.Box2d.__MR_Box2d_getBoxClosestPointTo ( MR.Box2d * _this,
MR.Vector2d * pt )
static

◆ __MR_Box2d_getDistanceSq_MR_Box2d()

unsafe double MR.Box2d.__MR_Box2d_getDistanceSq_MR_Box2d ( MR.Box2d * _this,
MR.Box2d * b )
static

◆ __MR_Box2d_getDistanceSq_MR_Vector2d()

unsafe double MR.Box2d.__MR_Box2d_getDistanceSq_MR_Vector2d ( MR.Box2d * _this,
MR.Vector2d * pt )
static

◆ __MR_Box2d_getMaxBoxCorner()

unsafe MR.Vector2b MR.Box2d.__MR_Box2d_getMaxBoxCorner ( MR.Vector2d * n)
static

◆ __MR_Box2d_getMinBoxCorner()

unsafe MR.Vector2b MR.Box2d.__MR_Box2d_getMinBoxCorner ( MR.Vector2d * n)
static

◆ __MR_Box2d_getProjection()

unsafe MR.Vector2d MR.Box2d.__MR_Box2d_getProjection ( MR.Box2d * _this,
MR.Vector2d * pt )
static

◆ __MR_Box2d_include_MR_Box2d()

unsafe void MR.Box2d.__MR_Box2d_include_MR_Box2d ( MR.Box2d * _this,
MR.Box2d * b )
static

◆ __MR_Box2d_include_MR_Vector2d()

unsafe void MR.Box2d.__MR_Box2d_include_MR_Vector2d ( MR.Box2d * _this,
MR.Vector2d * pt )
static

◆ __MR_Box2d_index()

unsafe MR.Vector2d * MR.Box2d.__MR_Box2d_index ( MR.Box2d * _this,
int e )
static

◆ __MR_Box2d_index_mut()

unsafe MR.Vector2d * MR.Box2d.__MR_Box2d_index_mut ( MR.Box2d * _this,
int e )
static

◆ __MR_Box2d_insignificantlyExpanded()

unsafe MR.Box2d MR.Box2d.__MR_Box2d_insignificantlyExpanded ( MR.Box2d * _this)
static

◆ __MR_Box2d_intersect()

unsafe MR.Box2d * MR.Box2d.__MR_Box2d_intersect ( MR.Box2d * _this,
MR.Box2d * b )
static

◆ __MR_Box2d_intersection()

unsafe MR.Box2d MR.Box2d.__MR_Box2d_intersection ( MR.Box2d * _this,
MR.Box2d * b )
static

◆ __MR_Box2d_intersects()

unsafe byte MR.Box2d.__MR_Box2d_intersects ( MR.Box2d * _this,
MR.Box2d * b )
static

◆ __MR_Box2d_size()

unsafe MR.Vector2d MR.Box2d.__MR_Box2d_size ( MR.Box2d * _this)
static

◆ __MR_Box2d_valid()

unsafe byte MR.Box2d.__MR_Box2d_valid ( MR.Box2d * _this)
static

◆ __MR_Box2d_volume()

unsafe double MR.Box2d.__MR_Box2d_volume ( MR.Box2d * _this)
static

◆ __MR_equal_MR_Box2d()

unsafe byte MR.Box2d.__MR_equal_MR_Box2d ( MR.Box2d * _this,
MR.Box2d * a )
static

◆ center()

readonly unsafe MR.Vector2d MR.Box2d.center ( )
inline

computes center of the box Generated from method MR.Box2d.center.

◆ contains() [1/2]

readonly unsafe bool MR.Box2d.contains ( in MR.Box2d otherbox)
inline

checks whether given box is fully inside (the surfaces may touch) of this box Generated from method MR.Box2d.contains.

◆ contains() [2/2]

readonly unsafe bool MR.Box2d.contains ( in MR.Vector2d pt)
inline

checks whether given point is inside (including the surface) of this box Generated from method MR.Box2d.contains.

◆ corner()

readonly unsafe MR.Vector2d MR.Box2d.corner ( in MR.Vector2b c)
inline

returns the corner of this box as specified by given bool-vector: 0 element in (c) means take min's coordinate, 1 element in (c) means take max's coordinate Generated from method MR.Box2d.corner.

◆ diagonal()

readonly unsafe double MR.Box2d.diagonal ( )
inline

computes length from min to max Generated from method MR.Box2d.diagonal.

◆ Equals() [1/2]

bool MR.Box2d.Equals ( MR.Box2d a)
inline

◆ Equals() [2/2]

override bool MR.Box2d.Equals ( object? other)
inline

◆ expanded()

readonly unsafe MR.Box2d MR.Box2d.expanded ( in MR.Vector2d expansion)
inline

decreases min and increased max on given value Generated from method MR.Box2d.expanded.

◆ fromMinAndSize()

unsafe MR.Box2d MR.Box2d.fromMinAndSize ( in MR.Vector2d min,
in MR.Vector2d size )
inlinestatic

Generated from method MR.Box2d.fromMinAndSize.

◆ getBoxClosestPointTo()

readonly unsafe MR.Vector2d MR.Box2d.getBoxClosestPointTo ( in MR.Vector2d pt)
inline

returns closest point in the box to given point Generated from method MR.Box2d.getBoxClosestPointTo.

◆ getDistanceSq() [1/2]

readonly unsafe double MR.Box2d.getDistanceSq ( in MR.Box2d b)
inline

returns squared distance between this box and given one; returns zero if the boxes touch or intersect Generated from method MR.Box2d.getDistanceSq.

◆ getDistanceSq() [2/2]

readonly unsafe double MR.Box2d.getDistanceSq ( in MR.Vector2d pt)
inline

returns squared distance between this box and given point; returns zero if the point is inside or on the boundary of the box Generated from method MR.Box2d.getDistanceSq.

◆ getMaxBoxCorner()

unsafe MR.Vector2b MR.Box2d.getMaxBoxCorner ( in MR.Vector2d n)
inlinestatic

considering all planes with given normal and arbitrary shift: dot(n,x) = d finds the box's corner for which d is maximal Generated from method MR.Box2d.getMaxBoxCorner.

◆ getMinBoxCorner()

unsafe MR.Vector2b MR.Box2d.getMinBoxCorner ( in MR.Vector2d n)
inlinestatic

considering all planes with given normal and arbitrary shift: dot(n,x) = d finds the box's corner for which d is minimal Generated from method MR.Box2d.getMinBoxCorner.

◆ getProjection()

readonly unsafe MR.Vector2d MR.Box2d.getProjection ( in MR.Vector2d pt)
inline

returns the closest point on the box to the given point for points outside the box this is equivalent to getBoxClosestPointTo Generated from method MR.Box2d.getProjection.

◆ include() [1/2]

unsafe void MR.Box2d.include ( in MR.Box2d b)
inline

minimally increases the box to include another box Generated from method MR.Box2d.include.

◆ include() [2/2]

unsafe void MR.Box2d.include ( in MR.Vector2d pt)
inline

minimally increases the box to include given point Generated from method MR.Box2d.include.

◆ index()

unsafe ref MR.Vector2d MR.Box2d.index ( int e)
inline

Generated from method MR::Box2d::operator[].

◆ insignificantlyExpanded()

readonly unsafe MR.Box2d MR.Box2d.insignificantlyExpanded ( )
inline

decreases min and increases max to their closest representable value Generated from method MR.Box2d.insignificantlyExpanded.

◆ intersect()

unsafe ref MR.Box2d MR.Box2d.intersect ( in MR.Box2d b)
inline

Generated from method MR.Box2d.intersect.

◆ intersection()

readonly unsafe MR.Box2d MR.Box2d.intersection ( in MR.Box2d b)
inline

computes intersection between this and other box Generated from method MR.Box2d.intersection.

◆ intersects()

readonly unsafe bool MR.Box2d.intersects ( in MR.Box2d b)
inline

checks whether this box intersects or touches given box Generated from method MR.Box2d.intersects.

◆ operator Box2d()

implicit MR.Box2d.operator Box2d ( ConstBox_Box2d other)
static

Copy contents from a wrapper class to this struct.

◆ operator!=()

unsafe bool MR.Box2d.operator!= ( MR.Box2d _this,
MR.Box2d a )
inlinestatic

◆ operator==()

unsafe bool MR.Box2d.operator== ( MR.Box2d _this,
MR.Box2d a )
inlinestatic

Generated from method MR::Box2d::operator==.

◆ size()

readonly unsafe MR.Vector2d MR.Box2d.size ( )
inline

computes size of the box in all dimensions Generated from method MR.Box2d.size.

◆ valid()

readonly unsafe bool MR.Box2d.valid ( )
inline

true if the box contains at least one point Generated from method MR.Box2d.valid.

◆ volume()

readonly unsafe double MR.Box2d.volume ( )
inline

computes the volume of this box Generated from method MR.Box2d.volume.

Member Data Documentation

◆ max

MR.Vector2d MR.Box2d.max

◆ min

MR.Vector2d MR.Box2d.min

Property Documentation

◆ this[int e]

readonly unsafe ref readonly MR.Vector2d MR.Box2d.this[int e]
get

min/max access by 0/1 index Generated from method MR::Box2d::operator[].


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