Class FloodFill

java.lang.Object
com.example.brickpaint.FloodFill
All Implemented Interfaces:
Callable<javafx.scene.image.WritableImage>

public class FloodFill extends Object implements Callable<javafx.scene.image.WritableImage>
Handles running a threaded flood fill algorithm
Author:
matde
  • Constructor Summary

    Constructors
    Constructor
    Description
    FloodFill(javafx.scene.image.WritableImage imageIn, int x2, int y2, javafx.scene.paint.Color replace, javafx.scene.paint.Color newColor, double Sense)
    Defualt constructor
  • Method Summary

    Modifier and Type
    Method
    Description
    javafx.scene.image.WritableImage
    Threaded flood fill algorithm

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • FloodFill

      public FloodFill(javafx.scene.image.WritableImage imageIn, int x2, int y2, javafx.scene.paint.Color replace, javafx.scene.paint.Color newColor, double Sense)
      Defualt constructor
      Parameters:
      imageIn - the image to preform the flood fill on
      x2 - start x-cord
      y2 - start y-cord
      replace - color to replace
      newColor - color to draw with
      Sense - the sensitivity for determining the border
  • Method Details

    • call

      public javafx.scene.image.WritableImage call()
      Threaded flood fill algorithm
      Specified by:
      call in interface Callable<javafx.scene.image.WritableImage>
      Returns:
      WritableImage with the flood fill operation applied to it