public Matrix3 setToRotation (IVector3 from, IVector3 to) {
        float angle = from.angle(to);
        return (angle < 0.0001f) ?
            setToIdentity() : setToRotation(angle, from.cross(to).normalizeLocal());
    }
public Matrix3 setToRotation ( IVector3 from , IVector3 to ) { float angle = from . angle ( to ) ; return ( angle < 0.0001f ) ? setToIdentity ( ) : setToRotation ( angle , from . cross ( to ) . normalizeLocal ( ) ) ; }
Sets this to a rotation matrix that rotates one vector onto another.

@return a reference to this matrix, for chaining.