Interface MutablePixels

All Known Implementing Classes:
FxMutablePixels

public interface MutablePixels
Author:
Dennis Cosgrove (http://www.cse.wustl.edu/~cosgroved/)
  • Method Summary

    Modifier and Type Method Description
    javafx.scene.paint.Color getColor​(int x, int y)
    Gets the Color of the pixel at the given coordinates.
    int getHeight()  
    int getWidth()  
    boolean isInBounds​(int x, int y)
    Checks to see whether this image contains a pixel at the given coordinates.
    void setColor​(int x, int y, javafx.scene.paint.Color color)
    Sets the pixel at the given coordinates to a replacement color.
  • Method Details

    • getWidth

      int getWidth()
    • getHeight

      int getHeight()
    • isInBounds

      boolean isInBounds​(int x, int y)
      Checks to see whether this image contains a pixel at the given coordinates.
      Parameters:
      x - The x-coordinate of the desired pixel.
      y - The y-coordinate of the desired pixel.
      Returns:
      true if the given pixel coordinates are within the bounds of the image, otherwise false.
    • getColor

      javafx.scene.paint.Color getColor​(int x, int y)
      Gets the Color of the pixel at the given coordinates.
      Parameters:
      x - The x-coordinate of the desired pixel.
      y - The y-coordinate of the desired pixel.
      Returns:
      The color of the image at the given pixel.
    • setColor

      void setColor​(int x, int y, javafx.scene.paint.Color color)
      Sets the pixel at the given coordinates to a replacement color.
      Parameters:
      x - The x-coordinate of the desired pixel.
      y - The y-coordinate of the desired pixel.
      color - The new color for the pixel.