Overview of Unity Mathematics types and functions
masterUnity Mathematics is a C# math library designed with a shader-like syntax (similar to HLSL or SIMD) to facilitate high-performance math operations. It is optimized for use with the Burst compiler to compile C# into efficient native code.
Supported Vector and Matrix Types:
floatN(e.g.,float2,float3,float4)quaternionfloat3x3float4x4
Supported Elementary Functions:
- Basic:
min,max,fabs, etc. - Trigonometric/Geometric:
sin,cos,sqrt,normalize,dot,cross, etc.