public interface Brush
Modifier and Type | Method and Description |
---|---|
Brush |
clone()
Create a deep copy of the brush.
|
BrushShape |
getBrushShape()
Get the shape of the brush.
|
int |
getEffectiveRadius()
Get the "radius" of the bounding box of the brush.
|
float |
getFullStrength(int dx,
int dy)
Get the maximum brush strength at a specific point on the brush, in other
words the strength if the level was set to 1.0f.
|
float |
getLevel()
Get the current level of the brush.
|
java.lang.String |
getName()
Get the name of the brush.
|
int |
getRadius()
Get the current radius of the brush.
|
float |
getStrength(int dx,
int dy)
Get the brush strength at a specific point on the brush.
|
void |
setLevel(float level)
Set the level of the brush.
|
void |
setRadius(int radius)
Set the radius of the brush.
|
java.lang.String getName()
float getStrength(int dx, int dy)
dx
- The X coordinate relative to the center of the brush.dy
- The Y coordinate relative to the center of the brush.float getFullStrength(int dx, int dy)
setLevel(1.0f); getStrength(dx, dy)
, but possibly more
efficient and without actually changing the value of the
level
property.dx
- The X coordinate relative to the center of the brush.dy
- The Y coordinate relative to the center of the brush.int getRadius()
void setRadius(int radius)
radius
- The new radius of the brush in pixels.int getEffectiveRadius()
getRadius()
, but it could be larger for, for
instance, a rotated square brush.float getLevel()
void setLevel(float level)
level
- The new level of the brush, from 0.0f (no effect) to 1.0f
(maximum effect) (inclusive).BrushShape getBrushShape()
Brush clone()