类 BrushedMetalFilter

  • 所有已实现的接口:
    java.awt.image.BufferedImageOp

    public class BrushedMetalFilter
    extends java.lang.Object
    implements java.awt.image.BufferedImageOp
    A filter which produces an image simulating brushed metal.
    • 构造器概要

      构造器 
      构造器 说明
      BrushedMetalFilter()
      Constructs a BrushedMetalFilter object.
      BrushedMetalFilter​(int color, int radius, float amount, boolean monochrome, float shine)
      Constructs a BrushedMetalFilter object.
    • 方法概要

      所有方法 实例方法 具体方法 
      修饰符和类型 方法 说明
      void blur​(int[] in, int[] out, int width, int radius)  
      java.awt.image.BufferedImage createCompatibleDestImage​(java.awt.image.BufferedImage src, java.awt.image.ColorModel dstCM)  
      java.awt.image.BufferedImage filter​(java.awt.image.BufferedImage src, java.awt.image.BufferedImage dst)  
      float getAmount()
      Get the amount of noise to add.
      java.awt.geom.Rectangle2D getBounds2D​(java.awt.image.BufferedImage src)  
      int getColor()
      Get the color of the metal.
      boolean getMonochrome()
      Get the type of noise to add.
      java.awt.geom.Point2D getPoint2D​(java.awt.geom.Point2D srcPt, java.awt.geom.Point2D dstPt)  
      int getRadius()
      Get the horizontal size of the blur.
      java.awt.RenderingHints getRenderingHints()  
      float getShine()
      Get the amount of shine to add in the range 0..1.
      void setAmount​(float amount)
      Set the amount of noise to add in the range 0..1.
      void setColor​(int color)
      Set the color of the metal.
      void setMonochrome​(boolean monochrome)
      Set the type of noise to add.
      void setRadius​(int radius)
      Set the horizontal size of the blur.
      void setShine​(float shine)
      Set the amount of shine to add to the range 0..1.
      java.lang.String toString()  
      • 从类继承的方法 java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • 构造器详细资料

      • BrushedMetalFilter

        public BrushedMetalFilter()
        Constructs a BrushedMetalFilter object.
      • BrushedMetalFilter

        public BrushedMetalFilter​(int color,
                                  int radius,
                                  float amount,
                                  boolean monochrome,
                                  float shine)
        Constructs a BrushedMetalFilter object.
        参数:
        color - an int specifying the metal color
        radius - an int specifying the blur size
        amount - a float specifying the amount of texture
        monochrome - a boolean -- true for monochrome texture
        shine - a float specifying the shine to add
    • 方法详细资料

      • filter

        public java.awt.image.BufferedImage filter​(java.awt.image.BufferedImage src,
                                                   java.awt.image.BufferedImage dst)
        指定者:
        filter 在接口中 java.awt.image.BufferedImageOp
      • blur

        public void blur​(int[] in,
                         int[] out,
                         int width,
                         int radius)
      • setRadius

        public void setRadius​(int radius)
        Set the horizontal size of the blur.
        参数:
        radius - the radius of the blur in the horizontal direction
        另请参阅:
        getRadius()
      • getRadius

        public int getRadius()
        Get the horizontal size of the blur.
        返回:
        the radius of the blur in the horizontal direction
        另请参阅:
        setRadius(int)
      • setAmount

        public void setAmount​(float amount)
        Set the amount of noise to add in the range 0..1.
        参数:
        amount - the amount of noise
        另请参阅:
        getAmount()
      • getAmount

        public float getAmount()
        Get the amount of noise to add.
        返回:
        the amount of noise
        另请参阅:
        setAmount(float)
      • setShine

        public void setShine​(float shine)
        Set the amount of shine to add to the range 0..1.
        参数:
        shine - the amount of shine
        另请参阅:
        getShine()
      • getShine

        public float getShine()
        Get the amount of shine to add in the range 0..1.
        返回:
        the amount of shine
        另请参阅:
        setShine(float)
      • setColor

        public void setColor​(int color)
        Set the color of the metal.
        参数:
        color - the color in ARGB form
        另请参阅:
        getColor()
      • getColor

        public int getColor()
        Get the color of the metal.
        返回:
        the color in ARGB form
        另请参阅:
        setColor(int)
      • setMonochrome

        public void setMonochrome​(boolean monochrome)
        Set the type of noise to add.
        参数:
        monochrome - true for monochrome noise
        另请参阅:
        getMonochrome()
      • getMonochrome

        public boolean getMonochrome()
        Get the type of noise to add.
        返回:
        true for monochrome noise
        另请参阅:
        setMonochrome(boolean)
      • createCompatibleDestImage

        public java.awt.image.BufferedImage createCompatibleDestImage​(java.awt.image.BufferedImage src,
                                                                      java.awt.image.ColorModel dstCM)
        指定者:
        createCompatibleDestImage 在接口中 java.awt.image.BufferedImageOp
      • getBounds2D

        public java.awt.geom.Rectangle2D getBounds2D​(java.awt.image.BufferedImage src)
        指定者:
        getBounds2D 在接口中 java.awt.image.BufferedImageOp
      • getPoint2D

        public java.awt.geom.Point2D getPoint2D​(java.awt.geom.Point2D srcPt,
                                                java.awt.geom.Point2D dstPt)
        指定者:
        getPoint2D 在接口中 java.awt.image.BufferedImageOp
      • getRenderingHints

        public java.awt.RenderingHints getRenderingHints()
        指定者:
        getRenderingHints 在接口中 java.awt.image.BufferedImageOp
      • toString

        public java.lang.String toString()
        覆盖:
        toString 在类中 java.lang.Object