Class Watermark

  • Direct Known Subclasses:
    ImageWatermark

    public abstract class Watermark
    extends java.lang.Object
    A Watermark object represents the properties of a watermark effect, namely,
    • position - relative to the underlying source image
    • top, left - y, x coordinates from top-left corner of underlying image
    • orientation - angle of rotation as measured from the x-axis in clockwise direction
    • opacity - transparency of the watermark

    The position can be specified as a Location or using top, left values.
    If specified as a Location, it is transformed to x,y using image height,width values at the time of application of the watermark.
    • Method Detail

      • getPosition

        public Location getPosition()
      • setPosition

        public void setPosition​(Location position)
      • getTop

        public int getTop()
      • setTop

        public void setTop​(int top)
      • getLeft

        public int getLeft()
      • setLeft

        public void setLeft​(int left)
      • getOrientation

        public double getOrientation()
      • setOrientation

        public void setOrientation​(int orientation)
      • getOpacity

        public float getOpacity()
      • setOpacity

        public void setOpacity​(float opacity)
      • setCoords

        public void setCoords​(int imgWidth,
                              int imgHeight,
                              int wmWidth,
                              int wmHeight)
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object