| 220 | |
| 221 | template <size_t P = N> |
| 222 | typename std::enable_if<P == 2 && N == P, T>::type distanceTo(VectorType const& l, bool infinite = false) const { |
| 223 | auto t = lineProjection(l); |
| 224 | if (!infinite) |
| 225 | t = clamp<T>(t, 0, 1); |
| 226 | return vmag(l - eval(t)); |
| 227 | } |
| 228 | |
| 229 | template <size_t P = N> |
| 230 | typename std::enable_if<P == 2 && N == P, void>::type rotate( |