Luna::dot

f32 dot(const Float3 &v1, const Float3 &v2)

Computes the dot product of two vectors.

This function performs the following operations:

return v1.x * v2.x + v1.y * v2.y + v1.z * v2.z;

Parameters

  • in v1

    The first vector.

  • in v2

    The second vector.

Return value

Returns the dot product of two vectors.