Beispiel #1
0
 /// <summary>
 /// Split this node along its X axis (Y is split).
 /// </summary>
 /// <param name="splitLocation">Local Y coordinate of the split point</param>
 public void SplitVertically(uint splitLocation)
 {
     Left = new BSPTree2DNode(X, Y, Width, splitLocation);
     Right = new BSPTree2DNode(X, Y + splitLocation, Width, Height - splitLocation);
 }
Beispiel #2
0
 /// <summary>
 /// Split this node along its Y axis (X is split).
 /// </summary>
 /// <param name="splitLocation">Local X coordinate of the split point</param>
 public void SplitHorizontally(uint splitLocation)
 {
     Left = new BSPTree2DNode(X, Y, splitLocation, Height);
     Right = new BSPTree2DNode(X + splitLocation, Y, Width - splitLocation, Height);
 }