include/box2d/b2_math.h
float Normalize()
	{
		float length = Length();
		if (length < b2_epsilon)
		{
			return 0.0f;
		}
		float invLength = 1.0f / length;
		x *= invLength;
		y *= invLength;

		return length;
	}
/// Convert this vector into a unit vector. Returns the length.
Convert this vector into a unit vector. Returns the length.
Convert this vector into a unit vector . Returns the length .
float Normalize()
	{
		float length = Length();
		if (length < b2_epsilon)
		{
			return 0.0f;
		}
		float invLength = 1.0f / length;
		x *= invLength;
		y *= invLength;
		return length;
	}
float Normalize ( ) { float length = Length ( ) ; if ( length < b2_epsilon ) { return 0.0f ; } float invLength = 1.0f / length ; x *= invLength ; y *= invLength ; return length ; }
Convert this vector into a unit vector.
Convert this vector into a unit vector .