public class MotionBlur extends Effect
Example:
MotionBlur motionBlur = new MotionBlur();
motionBlur.setRadius(30);
motionBlur.setAngle(-15.0);
Text text = new Text();
text.setX(20.0);
text.setY(100.0);
text.setText("Motion!");
text.setFill(Color.web("0x3b596d"));
text.setFont(Font.font(null, FontWeight.BOLD, 60));
text.setEffect(motionBlur);
The code above produces the following:
| Constructor and Description |
|---|
MotionBlur()
Creates a new instance of MotionBlur with default parameters.
|
MotionBlur(double angle,
double radius)
Creates a new instance of MotionBlur with the specified angle and radius.
|
| Modifier and Type | Method and Description |
|---|---|
DoubleProperty |
angleProperty() |
double |
getAngle() |
Effect |
getInput() |
double |
getRadius() |
Effect |
impl_copy()
Deprecated.
This is an internal API that is not intended for use and will be removed in the next version
|
BaseBounds |
impl_getBounds(BaseBounds bounds,
BaseTransform tx,
Node node,
BoundsAccessor boundsAccessor)
Deprecated.
This is an internal API that is not intended for use and will be removed in the next version
|
ObjectProperty<Effect> |
inputProperty() |
DoubleProperty |
radiusProperty() |
void |
setAngle(double value) |
void |
setInput(Effect value) |
void |
setRadius(double value) |
impl_effectDirtyProperty, impl_getImpl, impl_isEffectDirty, impl_syncpublic MotionBlur()
public MotionBlur(double angle,
double radius)
angle - the angle of the motion effect, in degreesradius - the radius of the blur kernelpublic final void setInput(Effect value)
public final Effect getInput()
public final ObjectProperty<Effect> inputProperty()
public final void setRadius(double value)
public final double getRadius()
public final DoubleProperty radiusProperty()
public final void setAngle(double value)
public final double getAngle()
public final DoubleProperty angleProperty()
@Deprecated public BaseBounds impl_getBounds(BaseBounds bounds, BaseTransform tx, Node node, BoundsAccessor boundsAccessor)
Effectimpl_getBounds in class Effect@Deprecated public Effect impl_copy()
Copyright © 2025. All rights reserved.