lib/Vector4.cpp
Vector4 Vector4::reflect(const Vector4 &ref_ax) const {
  Matrix4 m, id;
  Vector4 ax = ref_ax;

  id.id();
  ax.normalize();

  m = (2.0*(m.outer(ax,ax))-id);
  return (m*(*this));
}
/*!
  Returns the mirror vector according to the given axe \a ref_ax.
  The reference axe needs not to be normalized, since this is done
  automatically.
*/
Returns the mirror vector according to the given axe \a ref_ax.
The reference axe needs not to be normalized, since this is done
automatically.
Returns the mirror vector according to the given axe \ a ref_ax . The reference axe needs not to be normalized since this is done automatically .
Vector4 Vector4::reflect(const Vector4 &ref_ax) const {
  Matrix4 m, id;
  Vector4 ax = ref_ax;
  id.id();
  ax.normalize();
  m = (2.0*(m.outer(ax,ax))-id);
  return (m*(*this));
}
Vector4 Vector4 :: reflect ( const Vector4 & ref_ax ) const { Matrix4 m , id ; Vector4 ax = ref_ax ; id . id ( ) ; ax . normalize ( ) ; m = ( 2.0 * ( m . outer ( ax , ax ) ) - id ) ; return ( m * ( * this ) ) ; }
Returns the mirror vector according to the given axe \a ref_ax.
Returns the mirror vector according to the given axe \ a ref_ax .