[DEV] Add cross product at vector2D
This commit is contained in:
parent
23e618a9ef
commit
5b94358126
@ -216,6 +216,14 @@ namespace etk {
|
||||
--(*this);
|
||||
return result;
|
||||
}
|
||||
/**
|
||||
* @brief Return the cross product
|
||||
* @param v The other vector in the cross product
|
||||
*/
|
||||
btScalar cross(const Vector2D<T>& _v) const {
|
||||
return m_floats[0] * _v.m_floats[1]
|
||||
- m_floats[1] * _v.m_floats[0];
|
||||
}
|
||||
/**
|
||||
* @brief Return the dot product
|
||||
* @param v The other vector in the dot product
|
||||
|
Loading…
x
Reference in New Issue
Block a user