Added missing operator for Vector3 * Matrix4
This commit is contained in:
parent
2989ea1c3a
commit
b14845a749
1 changed files with 13 additions and 0 deletions
|
@ -1585,6 +1585,19 @@ namespace OpenTK
|
|||
return result;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Transform a Vector by the given Matrix.
|
||||
/// </summary>
|
||||
/// <param name="vec">The vector to transform</param>
|
||||
/// <param name="mat">The desired transformation</param>
|
||||
/// <returns></returns>
|
||||
public static Vector3 operator *(Vector3 vec, Matrix4 mat)
|
||||
{
|
||||
Vector3 result;
|
||||
Vector3.Transform(ref vec, ref mat, out result);
|
||||
return result;
|
||||
}
|
||||
|
||||
/// <summary>Transform a Vector by the given Matrix using right-handed notation</summary>
|
||||
/// <param name="vec">The vector to transform</param>
|
||||
/// <param name="mat">The desired transformation</param>
|
||||
|
|
Loading…
Reference in a new issue