bl7::geometry2::Box Class Reference

#include <Box.h>

Inheritance diagram for bl7::geometry2::Box:
bl7::geometry2::Geometry bl7::geometry2::AABB bl7::geometry2::CollisionBox

List of all members.

Public Member Functions

 Box (void)
virtual ~Box (void)
 Box (const Box &rhs)
Boxoperator= (const Box &rhs)
 Box (const ml7::Vector2 &center, const ml7::Vector2 &half_width)
 Box (const float x1, const float y1, const float x2, const float y2)
Boxfrom_points (const ml7::Vector2 &p, const ml7::Vector2 &q)
Boxfrom_bounds (const float x1, const float y1, const float x2, const float y2)
bool operator== (const Box &rhs) const
bool operator!= (const Box &rhs) const

Public Attributes

ml7::Vector2 center
ml7::Vector2 half_width

Detailed Description

Base class for boxes of any type and purpose: collision geometry, bounding volumes, other primitives.


Constructor & Destructor Documentation

bl7::geometry2::Box::Box ( void   )  [inline]

Default constructor.

virtual bl7::geometry2::Box::~Box ( void   )  [inline, virtual]

Destructor.

bl7::geometry2::Box::Box ( const Box rhs  )  [inline]

Copy constructor.

bl7::geometry2::Box::Box ( const ml7::Vector2 center,
const ml7::Vector2 half_width 
) [inline]

Explicit constructor: box from center point and the half-width vector.

bl7::geometry2::Box::Box ( const float  x1,
const float  y1,
const float  x2,
const float  y2 
) [inline]

Explicit constructor: box from the minimum and the maximum values.


Member Function Documentation

Box & bl7::geometry2::Box::from_bounds ( const float  x1,
const float  y1,
const float  x2,
const float  y2 
)

Creates the box from bounds defining the minimum and the maximum values.

Creates a box from bounds defining the minimum and the maximum values.

Box & bl7::geometry2::Box::from_points ( const ml7::Vector2 p,
const ml7::Vector2 q 
)

Creates the box from points with the minimum and the maximum values.

Creates a box from points with the minimum and the maximum values.

bool bl7::geometry2::Box::operator!= ( const Box rhs  )  const [inline]

Checks whether a given Box and this have not the same center or half-width.

Box& bl7::geometry2::Box::operator= ( const Box rhs  )  [inline]

Copy assignment operator.

Reimplemented from bl7::geometry2::Geometry.

Reimplemented in bl7::geometry2::AABB, and bl7::geometry2::CollisionBox.

bool bl7::geometry2::Box::operator== ( const Box rhs  )  const [inline]

Checks whether a given Box and this have the same center and half-width.


Member Data Documentation

The center point.

The half-width.


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

Generated on Tue Dec 1 13:21:10 2009 for flange77: Cyber E-Razor rockt die Galaxis by  doxygen 1.6.1