MCPcopy Create free account
hub / github.com/NVIDIAGameWorks/Falcor / reflect

Function reflect

Source/Falcor/Utils/Math/VectorMath.h:1738–1741  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1736/// reflect
1737template<typename T, int N>
1738[[nodiscard]] constexpr vector<T, N> reflect(const vector<T, N>& v, const vector<T, N>& n)
1739{
1740 return v - T(2) * dot(v, n) * n;
1741}
1742
1743/// Convert vector to string.
1744template<typename T, int N>

Callers 1

Calls 2

dotFunction · 0.70
TFunction · 0.50

Tested by

no test coverage detected