java.lang.Object
io.github.jwharm.cairobindings.Proxy
org.freedesktop.cairo.Pattern
org.freedesktop.cairo.Gradient
org.freedesktop.cairo.RadialGradient
-
Constructor Summary
ConstructorDescriptionRadialGradient
(MemorySegment address) Constructor used internally to instantiate a java RadialPattern object for a nativecairo_pattern_t
instance -
Method Summary
Modifier and TypeMethodDescriptionstatic RadialGradient
create
(double cx0, double cy0, double radius0, double cx1, double cy1, double radius1) Creates a new radial gradient cairo_pattern_t between the two circles defined by (cx0, cy0, radius0) and (cx1, cy1, radius1).Circle[]
Gets the gradient endpoint circles for a radial gradient, each specified as a center coordinate and a radius.Methods inherited from class org.freedesktop.cairo.Gradient
addColorStopRGB, addColorStopRGBA, getColorStopCount, getColorStopRGBA
Methods inherited from class org.freedesktop.cairo.Pattern
destroy, getDither, getExtend, getFilter, getMatrix, getPatternType, getType, getUserData, setDither, setExtend, setFilter, setMatrix, setUserData, status
-
Constructor Details
-
RadialGradient
Constructor used internally to instantiate a java RadialPattern object for a nativecairo_pattern_t
instance- Parameters:
address
- the memory address of the nativecairo_pattern_t
instance
-
-
Method Details
-
create
public static RadialGradient create(double cx0, double cy0, double radius0, double cx1, double cy1, double radius1) Creates a new radial gradient cairo_pattern_t between the two circles defined by (cx0, cy0, radius0) and (cx1, cy1, radius1). Before using the gradient pattern, a number of color stops should be defined using cairo_pattern_add_color_stop_rgb() or cairo_pattern_add_color_stop_rgba().Note: The coordinates here are in pattern space. For a new pattern, pattern space is identical to user space, but the relationship between the spaces can be changed with cairo_pattern_set_matrix().
- Parameters:
cx0
- x coordinate for the center of the start circlecy0
- y coordinate for the center of the start circleradius0
- radius of the start circlecx1
- x coordinate for the center of the end circlecy1
- y coordinate for the center of the end circleradius1
- radius of the end circle- Returns:
- the newly created
RadialGradient
- Since:
- 1.0
-
getRadialCircles
-