Package jhd.FloodFill

Class FloodFill

java.lang.Object
jhd.FloodFill.Offsets
jhd.FloodFill.FloodFill

public class FloodFill
extends Offsets
Class for simulation of non-wetting imbibition into random porous media with both resolved and unresolved porosity
Author:
John H Dunsmuir
  • Constructor Details

    • FloodFill

      public FloodFill()
      Constructor for FloodFill
  • Method Details

    • grayFloodFill3D

      public int grayFloodFill3D​(java.lang.Object[] oImageArr, int imgWidth, int imgHeight, int imgDepth, int neighbors, double floodMin, double floodMax, double fillVal, java.util.List<Offsets.PointDesc> seeds)
      Flood fill 3D image voxel values between floodMin and floodMax with a fillVal
      Parameters:
      oImageArr - An Object[] as returned by ImageJ ImagePlus imp.getStack().getImageArray(); double, float, long, int, short, and byte image data types are supported
      imgWidth - The image width in pixels
      imgHeight - The image height in pixels
      imgDepth - The image depth (slices) in pixels
      neighbors - The connectedness face(6), face and edge(18), face, edge and corners(26)
      floodMin - Flood connected voxels values>floodMin
      floodMax - Flood connected voxels values<floodMax
      fillVal - Set flooded voxels to this value
      seeds - An array of one or more seed points to begin the flood use jhd.DistanceMaps.libJ8.Offsets.PointDesc;
      Returns:
      The number of voxels flooded.
    • characterize

      public FloodFill.PorosityReport characterize​(java.lang.Object[] oImageArr, int width, int height, int depth, double pixWidth, double pixHeight, double pixDepth)
      Parameters:
      oImageArr - An Object[] as returned by ImageJ ImagePlus imp.getStack().getImageArray(); (must be float data where unresolved porosity 0<phi<1 and resolved porosity phi=1)
      width - int The image width in pixels
      height - int The image height in pixels
      depth - int The image depth in pixels
      pixWidth - float The width of the pixel in user units;
      pixHeight - float The height of the pixel in user units;
      pixDepth - float The depth of the pixel in user units;
      Returns:
      A PorosityReport data structure.
    • phiMapToHybridMap

      public double phiMapToHybridMap​(java.lang.Object[] oImageArr, int width, int height, int depth, double pixWidth, double pixHeight, double pixDepth)
      Converts a porosity image 0<phi<1 to a hybrid porosity image with unresolved porosity 0<phi<1 and resolved porosity 1<phi<floodMax
      Parameters:
      oImageArr - An Object[] as returned by ImageJ ImagePlus imp.getStack().getImageArray(); (must be float data where unresolved porosity 0<phi<1 and resolved porosity phi=1)
      width - int The image width in pixels
      height - int The image height in pixels
      depth - int The image depth in pixels
      pixWidth - float The width of the pixel in user units;
      pixHeight - float The height of the pixel in user units;
      pixDepth - float The depth of the pixel in user units;
      Returns:
      The longest floodable pore radius, -1 if error occurs.