DistanceSqr


Return square distance between objects.

template<class TYPE>
TYPE DistanceSqr(const TVec1<TYPE> &a, const TVec1<TYPE> &b); // Return square distance between points.
template<class TYPE>
TYPE DistanceSqr(const TVec2<TYPE> &a, const TVec2<TYPE> &b); // Return square distance between points.
template<class TYPE>
TYPE DistanceSqr(const TVec3<TYPE> &a, const TVec3<TYPE> &b); // Return square distance between points.
template<class TYPE>
TYPE DistanceSqr(const TVec4<TYPE> &a, const TVec4<TYPE> &b); // Return square distance between points.
template<class TYPE, size_t SIZE, size_t ...Dimensions>
TYPE DistanceSqr(const TTensor<TYPE, SIZE, Dimensions...> &a, const TTensor<TYPE, SIZE, Dimensions...> &b); // Return square distance from other tensor
Namespace: ntl
Include: NTL/Core/Vec1.h (For TVec1 arguments)
NTL/Core/Vec2.h (For TVec2 arguments)
NTL/Core/Vec3.h (For TVec3 arguments)
NTL/Core/Vec4.h (For TVec4 arguments)
NTL/Core/Tensor.h (For TTensor arguments)