Class FromChannelOrMask

All Implemented Interfaces:
Provider<Stack>, ProviderAsStack

public class FromChannelOrMask extends StackProvider
Creates a Stack from a Channel or Mask (reusing the voxel buffers).
Author:
Owen Feehan
  • Constructor Details

    • FromChannelOrMask

      public FromChannelOrMask(ChannelProvider channel)
      Creates a new instance with a specified channel provider.
      Parameters:
      channel - the ChannelProvider to use.
    • FromChannelOrMask

      public FromChannelOrMask()
  • Method Details

    • checkMisconfigured

      public void checkMisconfigured(BeanInstanceMap defaultInstances) throws BeanMisconfiguredException
      Description copied from class: AnchorBean
      Checks that a bean's properties conform to expectations.
      Overrides:
      checkMisconfigured in class AnchorBean<StackProvider>
      Parameters:
      defaultInstances - all available default instances if the DefaultInstance annotation is used
      Throws:
      BeanMisconfiguredException - if the bean has not been configured properly as XML
    • get

      public Stack get() throws ProvisionFailedException
      Description copied from interface: Provider
      Gets or creates an object of type T.
      Returns:
      the object returned by the provider.
      Throws:
      ProvisionFailedException - if the object cannot be returned.
    • getChannel

      public ChannelProvider getChannel()
      A channel that is provided to the stack. Either this or mask must be set.
    • setChannel

      public void setChannel(ChannelProvider channel)
      A channel that is provided to the stack. Either this or mask must be set.
    • getMask

      public Provider<Mask> getMask()
      A mask that is provided to the stack. Either this or channel must be set.
    • setMask

      public void setMask(Provider<Mask> mask)
      A mask that is provided to the stack. Either this or channel must be set.
    • isRgb

      public boolean isRgb()
      If true, the output contains three channels (the input and two duplicates) instead of one.
    • setRgb

      public void setRgb(boolean rgb)
      If true, the output contains three channels (the input and two duplicates) instead of one.