Exemplo n.º 1
0
		public BoundingBox Union(BoundingBox box)
		{
			return new BoundingBox(
				new Float3(Math.Min(min.X, box.Min.X), Math.Min(min.Y, box.Min.Y), Math.Min(min.Z, box.Min.Z)), 
				new Float3(Math.Max(max.X, box.Max.X), Math.Max(max.Y, box.Max.Y), Math.Max(max.Z, box.Max.Z))
				);

		}
Exemplo n.º 2
0
		public void Reset(BoundingBox box)
		{
			if (!box.IsEmpty)
			{
				var sceneSize = Math.Min(1024*1024,box.Size());
				this.TargetDistance = sceneSize;
				this.Camera.LookAt(box.Max.ToVector() * 1.5f, box.Center.ToVector());
				this.Camera.ZFar = sceneSize * 4f;
				this.Camera.ZNear = sceneSize * 0.001f;
			}

		}
Exemplo n.º 3
0
		public bool Equals(BoundingBox other)
		{
			return this.min.Equals(other.min) && this.max.Equals(other.max);
		}
Exemplo n.º 4
0
		public void Reset(BoundingBox box)
		{
			
		}