Browse Source

Math: cross-link dot product and cross product docs.

pull/650/head
Vladimír Vondruš 2 years ago
parent
commit
60631459d9
  1. 5
      src/Magnum/Math/Vector.h
  2. 3
      src/Magnum/Math/Vector3.h

5
src/Magnum/Math/Vector.h

@ -111,7 +111,10 @@ the same general direction, `1` when two *normalized* vectors are parallel,
* *normalized* vectors are antiparallel. @f[
\boldsymbol a \cdot \boldsymbol b = \sum_{i=0}^{n-1} \boldsymbol a_i \boldsymbol b_i
@f]
@see @ref Vector::dot() const, @ref Vector::operator-(), @ref Vector2::perpendicular()
@see @ref Vector::dot() const, @ref Vector::operator-(),
@ref Vector2::perpendicular(),
@ref cross(const Vector3<T>&, const Vector3<T>&),
@ref cross(const Vector2<T>&, const Vector2<T>&)
*/
template<std::size_t size, class T> inline T dot(const Vector<size, T>& a, const Vector<size, T>& b) {
T out{};

3
src/Magnum/Math/Vector3.h

@ -54,7 +54,8 @@ gives the direction of its normal, and
is its area. Length of a cross product is also related to a distance of a point
and a line, see @ref Distance::linePoint(const Vector3<T>&, const Vector3<T>&, const Vector3<T>&)
for more information.
@see @ref cross(const Vector2<T>&, const Vector2<T>&), @ref planeEquation()
@see @ref cross(const Vector2<T>&, const Vector2<T>&), @ref planeEquation(),
@ref dot(const Vector<size, T>&, const Vector<size, T>&)
*/
template<class T> inline Vector3<T> cross(const Vector3<T>& a, const Vector3<T>& b) {
return {

Loading…
Cancel
Save