Module omix.api
Package omix.lang

Class RadialGradient

java.lang.Object
omix.lang.Gradient
omix.lang.RadialGradient
All Implemented Interfaces:
Serializable, Brush, Paint

public final class RadialGradient
extends Gradient
This class represents radial gradients. Radial gradients interpolate colors between a focal point and end points on a circle surrounding it. Outside the end points the gradient is either padded, reflected or repeated depending on the currently set spread method.

Gradient

Author:
Dr. Peter Droste, Omix Visualization
See Also:
Serialized Form
  • Constructor Details

  • Method Details

    • getCenterX

      public double getCenterX()
      Returns:
      the x coordinate of the center point
    • setCenterX

      public void setCenterX​(double centerX)
      changes the x coordinate of the center point
      Parameters:
      centerX - x coordinate of the gradient center
    • setCenter

      public void setCenter​(double centerX, double centerY)
      changes the coordinates of the center point
      Parameters:
      centerX - x coordinate of the gradient center
      centerY - y coordinate of the gradient center
    • getCenterY

      public double getCenterY()
      Returns:
      the y coordinate of the center point
    • setCenterY

      public void setCenterY​(double centerY)
      changes the y coordinate of the center point
      Parameters:
      centerY - y coordinate of the gradient center
    • getFocalPointX

      public double getFocalPointX()
      Returns:
      the x coordinate of the focal point
    • setFocalPointX

      public void setFocalPointX​(double focalPointX)
      changes the x coordinate of the focal point
      Parameters:
      focalPointX - x coordinate of the focal point
    • getFocalPointY

      public double getFocalPointY()
      Returns:
      the y coordinate of the focal point
    • setFocalPointY

      public void setFocalPointY​(double focalPointY)
      changes the y coordinate of the focal point
      Parameters:
      focalPointY - y coordinate of the focal point
    • setFocalPoint

      public void setFocalPoint​(double focalPointX, double focalPointY)
      changes the coordinates of the focal point
      Parameters:
      focalPointX - x coordinate of the focal point
      focalPointY - y coordinate of the focal point
    • getRadius

      public double getRadius()
      Returns:
      the radius of this radial gradient.
    • setRadius

      public void setRadius​(double radius)
      changes the radius of this radial gradient
      Parameters:
      radius - radius of this radial gradient
    • clone

      public RadialGradient clone()
      Specified by:
      clone in interface Brush
      Specified by:
      clone in interface Paint
      Specified by:
      clone in class Gradient
      Returns:
      A clone of the brush object.
      See Also:
      Gradient.clone()
    • hashCode

      public int hashCode()
      Specified by:
      hashCode in interface Brush
      Specified by:
      hashCode in interface Paint
      Overrides:
      hashCode in class Gradient
    • equals

      public boolean equals​(Object obj)
      Specified by:
      equals in interface Brush
      Specified by:
      equals in interface Paint
      Overrides:
      equals in class Gradient