geom::vec2< V > Class Template Reference

Gfx::vec2 is a 2-D vector class for representing 2-D points or distances. More...

#include <Image/vec2.h>

Collaboration diagram for geom::vec2< V >:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 vec2 (V x, V y)
template<class U >
 vec2 (const vec2< U > &other)
template<class U >
vec2operator= (const vec2< U > &other)
V & x ()
V & y ()
const V & x () const
const V & y () const
vec2 abs () const
void set (V x, V y)
bool operator== (const vec2< V > &b)
double length () const
void set_length (double len)
void set_polar_rad (double r, double theta)
double theta_deg () const
double theta_rad () const
void set_theta_deg (double degrees)
void rotate_deg (double degrees)
double angle_to (const vec2< V > &b) const
 Result in radians.
double distance_to (const vec2< V > &b) const
template<class U >
void scale_by (const U &factor)
vec2 operator* (const V &factor) const
vec2 operator/ (const V &factor) const
template<class U >
vec2operator*= (const U &factor)
template<class U >
vec2operator/= (const U &factor)
vec2 operator+ (const vec2< V > &rhs) const
vec2 operator- (const vec2< V > &rhs) const
template<class U >
vec2 operator* (const vec2< U > &rhs) const
template<class U >
vec2 operator/ (const vec2< U > &rhs) const
template<class U >
vec2operator+= (const vec2< U > &rhs)
template<class U >
vec2operator-= (const vec2< U > &rhs)
template<class U >
vec2operator*= (const vec2< U > &factor)
template<class U >
vec2operator/= (const vec2< U > &factor)
void debug_dump () const throw ()

Static Public Member Functions

static vec2 zeros ()
static vec2 ones ()

Detailed Description

template<class V>
class geom::vec2< V >

Gfx::vec2 is a 2-D vector class for representing 2-D points or distances.

Definition at line 49 of file vec2.h.


Member Function Documentation

template<class V>
double geom::vec2< V >::angle_to ( const vec2< V > &  b  )  const [inline]

Result in radians.

Definition at line 147 of file vec2.h.


The documentation for this class was generated from the following file:
Generated on Sun May 8 08:44:26 2011 for iLab Neuromorphic Vision Toolkit by  doxygen 1.6.3