Class StretchedImageFilter

  • All Implemented Interfaces:
    java.awt.image.ImageConsumer, java.lang.Cloneable

    public class StretchedImageFilter
    extends java.awt.image.ImageFilter
    An ImageFilter that produces stretched faces.
    • Field Summary

      • Fields inherited from class java.awt.image.ImageFilter

        consumer
      • Fields inherited from interface java.awt.image.ImageConsumer

        COMPLETESCANLINES, IMAGEABORTED, IMAGEERROR, RANDOMPIXELORDER, SINGLEFRAME, SINGLEFRAMEDONE, SINGLEPASS, STATICIMAGEDONE, TOPDOWNLEFTRIGHT
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      static boolean coordsInTile​(long stretch, int x, int y)
      Checks whether the specified coordinates are inside a (possibly stretched) isometric tile.
      void imageComplete​(int status)  
      void setDimensions​(int width, int height)  
      void setHints​(int hints)  
      void setPixels​(int x, int y, int w, int h, @NotNull java.awt.image.ColorModel model, @org.jetbrains.annotations.NotNull int @NotNull [] pixels, int off, int scansize)  
      void setPixels​(int x, int y, int w, int h, @NotNull java.awt.image.ColorModel model, byte @NotNull [] pixels, int off, int scansize)  
      void setStretchedFactor​(long stretchFactor)
      Set the stretch factor for this instance.
      • Methods inherited from class java.awt.image.ImageFilter

        clone, getFilterInstance, resendTopDownLeftRight, setColorModel, setProperties
      • Methods inherited from class java.lang.Object

        equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • StretchedImageFilter

        public StretchedImageFilter()
    • Method Detail

      • setStretchedFactor

        public void setStretchedFactor​(long stretchFactor)
        Set the stretch factor for this instance.
        Parameters:
        stretchFactor - the stretch factor
      • setDimensions

        public void setDimensions​(int width,
                                  int height)
        Specified by:
        setDimensions in interface java.awt.image.ImageConsumer
        Overrides:
        setDimensions in class java.awt.image.ImageFilter
      • setHints

        public void setHints​(int hints)
        Specified by:
        setHints in interface java.awt.image.ImageConsumer
        Overrides:
        setHints in class java.awt.image.ImageFilter
      • setPixels

        public void setPixels​(int x,
                              int y,
                              int w,
                              int h,
                              @NotNull
                              @NotNull java.awt.image.ColorModel model,
                              byte @NotNull [] pixels,
                              int off,
                              int scansize)
        Specified by:
        setPixels in interface java.awt.image.ImageConsumer
        Overrides:
        setPixels in class java.awt.image.ImageFilter
      • setPixels

        public void setPixels​(int x,
                              int y,
                              int w,
                              int h,
                              @NotNull
                              @NotNull java.awt.image.ColorModel model,
                              @NotNull
                              @org.jetbrains.annotations.NotNull int @NotNull [] pixels,
                              int off,
                              int scansize)
        Specified by:
        setPixels in interface java.awt.image.ImageConsumer
        Overrides:
        setPixels in class java.awt.image.ImageFilter
      • coordsInTile

        public static boolean coordsInTile​(long stretch,
                                           int x,
                                           int y)
        Checks whether the specified coordinates are inside a (possibly stretched) isometric tile.
        Parameters:
        stretch - stretch factor
        x - x coordinate
        y - y coordinate
        Returns:
        whether the coordinates are inside an isometric tile.
      • imageComplete

        public void imageComplete​(int status)
        Specified by:
        imageComplete in interface java.awt.image.ImageConsumer
        Overrides:
        imageComplete in class java.awt.image.ImageFilter