Exemplo n.º 1
0
        public void UpdateScreenSize(MyViewport currentScreenViewport)
        {
            Viewport = currentScreenViewport;

            PreviousPosition = Vector3D.Zero;
            BoundingFrustum  = new BoundingFrustumD(MatrixD.Identity);

            AspectRatio = Viewport.Width / Viewport.Height;
        }
Exemplo n.º 2
0
        public void UpdateScreenSize(MyViewport currentScreenViewport)
        {
            Viewport = currentScreenViewport; 

            PreviousPosition = Vector3D.Zero;
            BoundingFrustum = new BoundingFrustumD(MatrixD.Identity);

            AspectRatio = Viewport.Width / Viewport.Height;
        }
 // Returns true if this box intersects the given frustum.
 public bool Intersects(BoundingFrustumD frustum)
 {
     return(Contains(frustum) != ContainmentType.Disjoint);
 }
 // Determine whether the given frustum contains, intersects, or is disjoint from
 // the given oriented box.
 public static ContainmentType Contains(BoundingFrustumD frustum, ref MyOrientedBoundingBoxD obox)
 {
     return(frustum.Contains(obox.ConvertToFrustum()));
 }