/// <summary> /// Updates the view and projection matrices with current camera data. /// </summary> public void UpdateMatrices() { projectionMatrix = GetProjectionMatrix(); viewMatrix = GetViewMatrix(); ViewProjectionMatrix = viewMatrix * projectionMatrix; invRotationMatrix = Matrix3.CreateRotationX(-RotationX) * Matrix3.CreateRotationY(-RotationY); CameraFrustum.UpdateCamera(this); }
/// <summary> /// Checks if a bounding node is within the camera fustrum. /// </summary> public bool InFustrum(BoundingNode boundingNode) { return(CameraFrustum.CheckIntersection(this, boundingNode)); }