All Classes Namespaces Files Functions Variables Typedefs Pages
Classes | Namespaces | Functions
Vector2D.h File Reference

Contains the Vector2D class; a two-dimensional vector class and related vector operations. More...

#include <iostream>
#include <math.h>

Go to the source code of this file.

Classes

class  TTC::Vector2D
 A two-dimensional vector class. More...
 

Namespaces

 TTC
 The namespace of the library. To make sure that all functions in the library are not conflicting with any other function the library uses it's own namespace. One always needs to use this namespace to access the functions inside this library.
 

Functions

std::ostream & TTC::operator<< (std::ostream &os, const Vector2D &v)
 Writes a vector to an output stream. More...
 
Vector2D TTC::normalize (const Vector2D &v)
 Normalization of a vector. More...
 
float TTC::dot (const Vector2D &v1, const Vector2D &v2)
 The dot product between two vectors. More...
 
float TTC::det (const Vector2D &v1, const Vector2D &v2)
 The cross product between two vectors. More...
 
Vector2D TTC::operator* (const float a, const Vector2D &v)
 Scalar multiplication (left operator) More...
 
void TTC::clamp (Vector2D &v, float maxValue)
 Caps the magnitude of a vector to a maximum value. More...
 

Detailed Description

Contains the Vector2D class; a two-dimensional vector class and related vector operations.