xmscore  1.0
pt.h File Reference
#include <iosfwd>
#include <stdexcept>
#include <xmscore/points/ptsfwd.h>

Go to the source code of this file.

Classes

class  xms::Pt2< T >
 2D Point template class More...
 
class  xms::Pt3< T >
 3d point template class More...
 
class  xms::Pt4< T >
 4D point template class More...
 

Functions

template<class T >
Pt3< T > xms::operator* (int a, const Pt3< T > &pt)
 
template<class T >
Pt3< T > xms::operator* (float a, const Pt3< T > &pt)
 
template<class T >
Pt3< T > xms::operator* (double a, const Pt3< T > &pt)
 
template<class _From , class _To >
_To & xms::Pt3Convert (const _From &a_from, _To &a_to)
 Convert from one Pt3 to another. More...
 
template<typename T , typename charT , typename traits >
std::basic_ostream< charT, traits > & xms::operator<< (std::basic_ostream< charT, traits > &strm, const Pt2< T > &a_pt)
 operator<< More...
 
template<typename T , typename charT , typename traits >
std::basic_istream< charT, traits > & xms::operator>> (std::basic_istream< charT, traits > &strm, Pt2< T > &a_pt)
 operator>> More...
 
template<typename T , typename charT , typename traits >
std::basic_ostream< charT, traits > & xms::operator<< (std::basic_ostream< charT, traits > &strm, const Pt3< T > &a_pt)
 operator<< More...
 
template<typename T , typename charT , typename traits >
std::basic_istream< charT, traits > & xms::operator>> (std::basic_istream< charT, traits > &strm, Pt3< T > &a_pt)
 operator>> More...
 
template<typename T , typename charT , typename traits >
std::basic_ostream< charT, traits > & xms::operator<< (std::basic_ostream< charT, traits > &strm, const Pt4< T > &a_pt)
 operator<< More...
 
template<typename T , typename charT , typename traits >
std::basic_istream< charT, traits > & xms::operator>> (std::basic_istream< charT, traits > &strm, Pt4< T > &a_pt)
 operator>> More...
 

Detailed Description

Definition in file pt.h.

Function Documentation

◆ operator*() [1/3]

template<class T >
Pt3<T> xms::operator* ( int  a,
const Pt3< T > &  pt 
)
inline

Multiply Pt3 by int.

Parameters
aMultiplier.
ptPoint
Returns
Point

Definition at line 1547 of file pt.h.

◆ operator*() [2/3]

template<class T >
Pt3<T> xms::operator* ( float  a,
const Pt3< T > &  pt 
)
inline

Multiply Pt3 by float.

Parameters
aMultiplier.
ptPoint
Returns
Point

Definition at line 1557 of file pt.h.

◆ operator*() [3/3]

template<class T >
Pt3<T> xms::operator* ( double  a,
const Pt3< T > &  pt 
)
inline

Multiply Pt3 by double.

Parameters
aMultiplier.
ptPoint
Returns
Point

Definition at line 1567 of file pt.h.

◆ operator<<() [1/3]

template<typename T , typename charT , typename traits >
std::basic_ostream<charT, traits>& xms::operator<< ( std::basic_ostream< charT, traits > &  strm,
const Pt2< T > &  a_pt 
)
inline

operator<<

Parameters
strmthe stream.
a_ptThe point
Returns
stream

Definition at line 2387 of file pt.h.

References xms::Pt2< T >::x.

◆ operator<<() [2/3]

template<typename T , typename charT , typename traits >
std::basic_ostream<charT, traits>& xms::operator<< ( std::basic_ostream< charT, traits > &  strm,
const Pt3< T > &  a_pt 
)
inline

operator<<

Parameters
strmthe stream.
a_ptThe point
Returns
stream

Definition at line 2450 of file pt.h.

References xms::Pt3< T >::x.

◆ operator<<() [3/3]

template<typename T , typename charT , typename traits >
std::basic_ostream<charT, traits>& xms::operator<< ( std::basic_ostream< charT, traits > &  strm,
const Pt4< T > &  a_pt 
)
inline

operator<<

Parameters
strmthe stream.
a_ptThe point
Returns
stream

Definition at line 2523 of file pt.h.

References xms::Pt4< T >::x.

◆ operator>>() [1/3]

template<typename T , typename charT , typename traits >
std::basic_istream<charT, traits>& xms::operator>> ( std::basic_istream< charT, traits > &  strm,
Pt2< T > &  a_pt 
)
inline

operator>>

Parameters
strmthe stream.
a_ptThe point
Returns
stream

Definition at line 2412 of file pt.h.

References xms::operator>>(), xms::Pt2< T >::x, and xms::Pt2< T >::y.

Referenced by xms::operator>>().

◆ operator>>() [2/3]

template<typename T , typename charT , typename traits >
std::basic_istream<charT, traits>& xms::operator>> ( std::basic_istream< charT, traits > &  strm,
Pt3< T > &  a_pt 
)
inline

operator>>

Parameters
strmthe stream.
a_ptThe point
Returns
stream

Definition at line 2475 of file pt.h.

References xms::operator>>(), xms::Pt2< T >::x, and xms::Pt2< T >::y.

◆ operator>>() [3/3]

template<typename T , typename charT , typename traits >
std::basic_istream<charT, traits>& xms::operator>> ( std::basic_istream< charT, traits > &  strm,
Pt4< T > &  a_pt 
)
inline

operator>>

Parameters
strmthe stream.
a_ptThe point
Returns
stream

Definition at line 2548 of file pt.h.

References xms::operator>>(), xms::Pt2< T >::x, and xms::Pt2< T >::y.

◆ Pt3Convert()

template<class _From , class _To >
_To& xms::Pt3Convert ( const _From &  a_from,
_To &  a_to 
)

Convert from one Pt3 to another.

Parameters
a_fromConverting from this.
a_toConverting to this.
Returns
Point

Definition at line 2360 of file pt.h.

References xms::Pt3Convert().

Referenced by xms::Pt3Convert().