Itasca C++ Interface
Loading...
Searching...
No Matches
AVector2Util Namespace Reference

2D Angular vector class. More...

Detailed Description

2D Angular vector class.

This specialized version of a vector class is intended to store "angular" values, values that are a scalar in 2D (z component only) and a full vector in 3D.

The intention is to make it easier to write code that is the same in 2D and 3D without wasting computation time and storage.

Also, hopefully they will interact "properly" with standard Vector2<> types.

For instance, the cross and dot product operators '&' and '|' should return the correct types, as if they were full 3D vector objects.

A Vector2<T> crossed with an AVector2<T> will return a Vector2<T>.

A Vector2<T> dotted with an AVector2<T> will return 0.0.