All Implemented Interfaces:
Provider<ObjectCollection>

public class SplitIntoSquares extends ObjectCollectionProviderUnary
Splits objects into sub-objects by cutting by an orthogonal square lattice (like a chessboard).

Only splits in x and y dimensions; the z-dimension is unaffected.

The cuts are mostly squares, but sometimes cuts are rectangles in the leftover space, which are never larger in any dimension than squareSize

An optional minimim number of on voxels is applied to any object (after it has been cut) to exist in the created collection.

Author:
Owen Feehan
  • Constructor Details

    • SplitIntoSquares

      public SplitIntoSquares()
  • Method Details

    • createFromObjects

      public ObjectCollection createFromObjects(ObjectCollection objectCollection)
      Description copied from class: ObjectCollectionProviderUnary
      Creates a ObjectCollection given the entity provided by the delegate.
      Specified by:
      createFromObjects in class ObjectCollectionProviderUnary
      Parameters:
      objectCollection - the entity provided by the delegate.
      Returns:
      the created ObjectCollection that is returned by the provider.
    • getSquareSize

      public int getSquareSize()
    • setSquareSize

      public void setSquareSize(int squareSize)
    • getMinNumberVoxels

      public int getMinNumberVoxels()
      Only includes squares that have at least this number of voxels.
    • setMinNumberVoxels

      public void setMinNumberVoxels(int minNumberVoxels)
      Only includes squares that have at least this number of voxels.