Class MaskImage

All Implemented Interfaces:
RenderedImage, Disposable

final class MaskImage extends SourceAlignedImage
Mask of missing values. This is the implementation of "org.apache.sis.Mask" property value.
Since:
1.1
Version:
1.3
See Also:
  • Field Details

    • converter

      private final org.opengis.referencing.operation.MathTransform converter
      Convert integer values to floating point values, or null if none. This is needed since we use Float.isNaN(float) for identifying values to mask.
  • Constructor Details

    • MaskImage

      MaskImage(ResampledImage image)
      Creates a new instance for the given image.
  • Method Details

    • getProperty

      public Object getProperty(String key)
      Gets a property from this image.
      Specified by:
      getProperty in interface RenderedImage
      Overrides:
      getProperty in class PlanarImage
      Parameters:
      key - the name of the property to get.
      Returns:
      the property value, or Image.UndefinedProperty if none.
    • getPropertyNames

      public String[] getPropertyNames()
      Returns the names of all recognized properties.
      Specified by:
      getPropertyNames in interface RenderedImage
      Overrides:
      getPropertyNames in class PlanarImage
      Returns:
      names of all recognized properties, or null if none.
    • computeTile

      protected Raster computeTile(int tileX, int tileY, WritableRaster tile) throws org.opengis.referencing.operation.TransformException
      Invoked when a tile need to be computed or updated.
      Specified by:
      computeTile in class ComputedImage
      Parameters:
      tileX - the column index of the tile to compute.
      tileY - the row index of the tile to compute.
      tile - if the tile already exists but needs to be updated, the tile to update. Otherwise null.
      Returns:
      computed tile for the given indices.
      Throws:
      org.opengis.referencing.operation.TransformException - if an error occurred while computing pixel coordinates.
    • hashCode

      public int hashCode()
      Returns a hash code value for this image.
      Overrides:
      hashCode in class SourceAlignedImage
    • equals

      public boolean equals(Object object)
      Compares the given object with this image for equality.
      Overrides:
      equals in class SourceAlignedImage