Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ Transform() [2/2]

void Microsoft.Xna.Framework.BoundingSphere.Transform ( ref Matrix matrix,
out BoundingSphere result )
inline

Definition at line 525 of file BoundingSphere.cs.

526 {
527 result.Center = Vector3.Transform(Center, matrix);
528 float val = matrix.M11 * matrix.M11 + matrix.M12 * matrix.M12 + matrix.M13 * matrix.M13;
529 float val2 = matrix.M21 * matrix.M21 + matrix.M22 * matrix.M22 + matrix.M23 * matrix.M23;
530 float val3 = matrix.M31 * matrix.M31 + matrix.M32 * matrix.M32 + matrix.M33 * matrix.M33;
531 float num = Math.Max(val, Math.Max(val2, val3));
532 result.Radius = Radius * (float)Math.Sqrt(num);
533 }
static double Sqrt(double d)
static byte Max(byte val1, byte val2)
Definition Math.cs:738

References Microsoft.Xna.Framework.BoundingSphere.Center, System.Math.Max(), Microsoft.Xna.Framework.BoundingSphere.Radius, System.Math.Sqrt(), and Microsoft.Xna.Framework.Vector3.Transform().