public class RadialGradient extends Shader
Shader.TileMode
native_instance, native_shader
Constructor and Description |
---|
RadialGradient(float x,
float y,
float radius,
int[] colors,
float[] positions,
Shader.TileMode tile)
Create a shader that draws a radial gradient given the center and radius.
|
RadialGradient(float x,
float y,
float radius,
int color0,
int color1,
Shader.TileMode tile)
Create a shader that draws a radial gradient given the center and radius.
|
public RadialGradient(float x, float y, float radius, int[] colors, float[] positions, Shader.TileMode tile)
x
- The x-coordinate of the center of the radiusy
- The y-coordinate of the center of the radiusradius
- Must be positive. The radius of the circle for this gradientcolors
- The colors to be distributed between the center and edge of the circlepositions
- May be NULL. The relative position of
each corresponding color in the colors array. If this is NULL,
the the colors are distributed evenly between the center and edge of the circle.tile
- The Shader tiling modepublic RadialGradient(float x, float y, float radius, int color0, int color1, Shader.TileMode tile)
x
- The x-coordinate of the center of the radiusy
- The y-coordinate of the center of the radiusradius
- Must be positive. The radius of the circle for this gradientcolor0
- The color at the center of the circle.color1
- The color at the edge of the circle.tile
- The Shader tiling mode