Luna::dot

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

Computes the dot product of two vectors.

This function performs the following operations:

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

Parameters

  • in v1

    The first vector.

  • in v2

    The second vector.

Return value

Returns the dot product of two vectors.