This is a basic class to encode 3D integer coordinates. More...
#include <BeoSub/BeeBrain/Point3D.H>
Public Member Functions | |
Point3D () | |
The default constructor initializes the coordinates to (0,0). | |
Point3D (const int xx, const int yy, const int zz) | |
Initialize the Point2D<int> from horizontal & vertical coordinates. | |
Point3D & | operator+= (const Point3D &p) |
+= operator | |
Point3D & | operator-= (const Point3D &p) |
-= operator | |
Point3D & | operator*= (const Point3D &p) |
*= operator | |
Point3D & | operator/= (const Point3D &p) |
/= operator | |
Point3D | operator+ (const Point3D &p) const |
+ operator | |
Point3D | operator- (const Point3D &p) const |
| |
Point3D | operator* (const Point3D &p) const |
* operator | |
Point3D | operator/ (const Point3D &p) const |
/ operator | |
Point3D & | operator+= (const int val) |
+= operator | |
Point3D & | operator-= (const int val) |
-= operator | |
Point3D & | operator*= (const int val) |
*= operator | |
Point3D & | operator/= (const int val) |
/= operator | |
Point3D | operator+ (const int val) const |
+ operator | |
Point3D | operator- (const int val) const |
| |
Point3D | operator* (const int val) const |
* operator | |
Point3D | operator/ (const int val) const |
/ operator | |
bool | isValidX () const |
test whether x is positive | |
bool | isValidY () const |
test whether y is positive | |
bool | isValidZ () const |
test whether z is positive | |
float | squdist (const Point3D &p) const |
the square euclidean distance from p | |
float | distance (const Point3D &p) const |
the euclidean distance from p | |
Point3D () | |
The default constructor initializes the coordinates to (0,0). | |
Point3D (const T xx, const T yy, const T zz) | |
Initialize the Point3D from horizontal & vertical coordinates. | |
Point3D (const Image< T > &mat) | |
Initialize the Point3D from an image. | |
template<class U > | |
Point3D (const Point3D< U > &a) | |
Explicit conversion from type T to another type U. | |
Point3D< T > & | operator+= (const Point3D< T > &p) |
+= operator | |
Point3D< T > & | operator-= (const Point3D< T > &p) |
-= operator | |
Point3D< T > & | operator*= (const Point3D< T > &p) |
*= operator | |
Point3D< T > & | operator/= (const Point3D< T > &p) |
/= operator | |
template<class U > | |
Point3D< typename promote_trait< T, U >::TP > | operator+ (const Point3D< U > &p) const |
+ operator | |
template<class U > | |
Point3D< typename promote_trait< T, U >::TP > | operator- (const Point3D< U > &p) const |
| |
template<class U > | |
Point3D< typename promote_trait< T, U >::TP > | operator* (const Point3D< U > &p) const |
* operator | |
template<class U > | |
Point3D< typename promote_trait< T, U >::TP > | operator/ (const Point3D< U > &p) const |
/ operator | |
Point3D< T > & | operator+= (const T val) |
+= operator | |
Point3D< T > & | operator-= (const T val) |
-= operator | |
Point3D< T > & | operator*= (const T val) |
*= operator | |
Point3D< T > & | operator/= (const T val) |
/= operator | |
template<class U > | |
Point3D< typename promote_trait< T, U >::TP > | operator+ (const U val) const |
+ operator | |
template<class U > | |
Point3D< typename promote_trait< T, U >::TP > | operator- (const U val) const |
| |
template<class U > | |
Point3D< typename promote_trait< T, U >::TP > | operator* (const U val) const |
* operator | |
template<class U > | |
Point3D< typename promote_trait< T, U >::TP > | operator/ (const U val) const |
/ operator | |
bool | isValid () const |
test whether x and y and z are all positive | |
promote_trait< T, float >::TP | squdist (const Point3D< T > &p) const |
the square of the euclidean distance | |
promote_trait< T, float >::TP | distance (const Point3D< T > &p) const |
the euclidean distance from p | |
promote_trait< T, float >::TP | magnitude () const |
the magnitude | |
Image< T > | getImage () |
Get an image representation used for matrix operations [x,y,z]. | |
Point3D () | |
The default constructor initializes the coordinates to (0,0). | |
Point3D (const int xx, const int yy, const int zz) | |
Initialize the Point2D<int> from horizontal & vertical coordinates. | |
Point3D & | operator+= (const Point3D &p) |
+= operator | |
Point3D & | operator-= (const Point3D &p) |
-= operator | |
Point3D & | operator*= (const Point3D &p) |
*= operator | |
Point3D & | operator/= (const Point3D &p) |
/= operator | |
Point3D | operator+ (const Point3D &p) const |
+ operator | |
Point3D | operator- (const Point3D &p) const |
| |
Point3D | operator* (const Point3D &p) const |
* operator | |
Point3D | operator/ (const Point3D &p) const |
/ operator | |
Point3D & | operator+= (const int val) |
+= operator | |
Point3D & | operator-= (const int val) |
-= operator | |
Point3D & | operator*= (const int val) |
*= operator | |
Point3D & | operator/= (const int val) |
/= operator | |
Point3D | operator+ (const int val) const |
+ operator | |
Point3D | operator- (const int val) const |
| |
Point3D | operator* (const int val) const |
* operator | |
Point3D | operator/ (const int val) const |
/ operator | |
bool | isValidX () const |
test whether x is positive | |
bool | isValidY () const |
test whether y is positive | |
bool | isValidZ () const |
test whether z is positive | |
float | squdist (const Point3D &p) const |
the square euclidean distance from p | |
float | distance (const Point3D &p) const |
the euclidean distance from p | |
Point3D (float xval, float yval, float zval) | |
Public Attributes | |
int | x |
3D coordinates | |
int | y |
int | z |
T | x |
3D coordinates | |
T | y |
T | z |
double | x |
double | y |
double | z |
float | x |
float | y |
float | z |
This is a basic class to encode 3D integer coordinates.
This is a basic class to encode 3D coordinates.
This is a completely public class whose goal is just to provide a shorthand notation for 3D integer coordinates. All methods are inlined, so there is no .C file, just a .H file.
This is a completely public class whose goal is just to provide a shorthand notation for 3D coordinates.
Definition at line 50 of file Point3D.H.
The default constructor initializes the coordinates to (0,0).
Definition at line 133 of file Point3D.H.
References Point3D< T >::x.
Referenced by Point3D< T >::operator*(), Point3D< T >::operator+(), Point3D< T >::operator-(), and Point3D< T >::operator/().
Initialize the Point2D<int> from horizontal & vertical coordinates.
Definition at line 137 of file Point3D.H.
References Point3D< T >::x.
The default constructor initializes the coordinates to (0,0).
Initialize the Point3D from horizontal & vertical coordinates.
Definition at line 180 of file Point3D.H.
References Point3D< T >::x.
Initialize the Point3D from an image.
Definition at line 185 of file Point3D.H.
References ASSERT, Image< T >::size(), and Point3D< T >::x.
The default constructor initializes the coordinates to (0,0).
Initialize the Point2D<int> from horizontal & vertical coordinates.
the euclidean distance from p
promote_trait<T,float>::TP Point3D< T >::distance | ( | const Point3D< T > & | p | ) | const [inline] |
the euclidean distance from p
the euclidean distance from p
Definition at line 232 of file Point3D.H.
References sqrt(), and Point3D< T >::squdist().
Get an image representation used for matrix operations [x,y,z].
Definition at line 343 of file Point3D.H.
References NO_INIT, and Point3D< T >::x.
bool Point3D< T >::isValid | ( | ) | const [inline] |
test whether x and y and z are all positive
Definition at line 316 of file Point3D.H.
References Point3D< T >::x.
bool Point3D< T >::isValidX | ( | ) | const [inline] |
test whether x is positive
bool Point3D< T >::isValidX | ( | ) | const [inline] |
bool Point3D< T >::isValidY | ( | ) | const [inline] |
test whether y is positive
bool Point3D< T >::isValidY | ( | ) | const [inline] |
bool Point3D< T >::isValidZ | ( | ) | const [inline] |
test whether z is positive
bool Point3D< T >::isValidZ | ( | ) | const [inline] |
promote_trait< T, float >::TP Point3D< T >::magnitude | ( | ) | const [inline] |
* operator
Point3D< typename promote_trait< T, U >::TP > Point3D< T >::operator* | ( | const U | val | ) | const [inline] |
Point3D< typename promote_trait< T, U >::TP > Point3D< T >::operator* | ( | const Point3D< U > & | p | ) | const [inline] |
* operator
Definition at line 197 of file Point3D.H.
References Point3D< T >::Point3D(), and Point3D< T >::x.
* operator
Definition at line 165 of file Point3D.H.
References Point3D< T >::Point3D(), and Point3D< T >::x.
*= operator
+ operator
Point3D< typename promote_trait< T, U >::TP > Point3D< T >::operator+ | ( | const U | val | ) | const [inline] |
Point3D< typename promote_trait< T, U >::TP > Point3D< T >::operator+ | ( | const Point3D< U > & | p | ) | const [inline] |
+ operator
Definition at line 189 of file Point3D.H.
References Point3D< T >::Point3D(), and Point3D< T >::x.
+ operator
Definition at line 157 of file Point3D.H.
References Point3D< T >::Point3D(), and Point3D< T >::x.
+= operator
Point3D< typename promote_trait< T, U >::TP > Point3D< T >::operator- | ( | const U | val | ) | const [inline] |
Point3D< typename promote_trait< T, U >::TP > Point3D< T >::operator- | ( | const Point3D< U > & | p | ) | const [inline] |
Definition at line 193 of file Point3D.H.
References Point3D< T >::Point3D(), and Point3D< T >::x.
Definition at line 161 of file Point3D.H.
References Point3D< T >::Point3D(), and Point3D< T >::x.
-= operator
/ operator
Point3D< typename promote_trait< T, U >::TP > Point3D< T >::operator/ | ( | const U | val | ) | const [inline] |
Point3D< typename promote_trait< T, U >::TP > Point3D< T >::operator/ | ( | const Point3D< U > & | p | ) | const [inline] |
/ operator
Definition at line 201 of file Point3D.H.
References Point3D< T >::Point3D(), and Point3D< T >::x.
/ operator
Definition at line 169 of file Point3D.H.
References Point3D< T >::Point3D(), and Point3D< T >::x.
/= operator
the square euclidean distance from p
promote_trait<T,float>::TP Point3D< T >::squdist | ( | const Point3D< T > & | p | ) | const [inline] |
the square of the euclidean distance
the square euclidean distance from p
Definition at line 225 of file Point3D.H.
References Point3D< T >::x.
Referenced by Point3D< T >::distance().
3D coordinates
Definition at line 111 of file Point3D.H.
Referenced by convertFromString(), convertToString(), ViewPort3D::drawCappedCylinder(), ViewPort3D::drawCone(), ViewPort3D::drawCylinder(), ViewPort3D::drawExtrudedContour(), ViewPort3D::drawSphere(), Scorbot::getEFPos(), Scorbot::getIKArmPos(), Point3D< T >::getImage(), HeliPose::getIMUBias(), ViewPort3D::getPosition(), WiiMote::getSensorData(), HeliPose::HeliPose(), ViewPort3D::initFrame(), Camera::inverseProjection(), Point3D< T >::isValid(), Point3D< T >::isValidX(), Point3D< T >::magnitude(), operator!=(), Point3D< T >::operator*(), Point3D< T >::operator*=(), Point3D< T >::operator+(), Point3D< T >::operator+=(), Point3D< T >::operator-(), Point3D< T >::operator-=(), Point3D< T >::operator/(), Point3D< T >::operator/=(), operator==(), operator>(), Point3D< T >::Point3D(), Camera::project(), segmentImageMerge2::SIMstereoMatch(), Point3D< T >::squdist(), and segmentImageMerge::StereoMatch().