hyades.level.Level.TransformBoundingSphere C# (CSharp) Method

TransformBoundingSphere() private static method

private static TransformBoundingSphere ( BoundingSphere sphere, Matrix transform ) : BoundingSphere
sphere BoundingSphere
transform Matrix
return BoundingSphere
        private static BoundingSphere TransformBoundingSphere(BoundingSphere sphere, Matrix transform)
        {
            BoundingSphere transformedSphere;
            Vector3 scale3 = new Vector3(sphere.Radius, sphere.Radius, sphere.Radius);
            scale3 = Vector3.TransformNormal(scale3, transform);
            transformedSphere.Radius = Math.Max(scale3.X, Math.Max(scale3.Y, scale3.Z));
            transformedSphere.Center = Vector3.Transform(sphere.Center, transform);

            return transformedSphere;
        }