Matrix4d.withLookAtUp

Apply a transformation to this matrix to ensure that the local Y axis (as obtained by {@link #positiveY(ref Vector3d)}) will be coplanar to the plane spanned by the local Z axis (as obtained by {@link #positiveZ(ref Vector3d)}) and the given vector <code>up</code>. <p> This effectively ensures that the resulting matrix will be equal to the one obtained from {@link #setLookAt(ref Vector3d, Vector3d, Vector3d)} called with the current local origin of this matrix (as obtained by {@link #originAffine(ref Vector3d)}), the sum of this position and the negated local Z axis as well as the given vector <code>up</code>. <p> This method must only be called on {@link #isAffine()} matrices.

@param up the up vector @return this

Meta