74
JavaFX BoxBlur Effect
JavaFX allows us to make the nodes blur by using the JavaFX blur effects. In general, the blur makes the image unclear. JavaFX provides the class javafx.scene.effect.BoxBlur which needs to be instantiated in order to apply the blur effect to the nodes. The Box filter is used in the case of BoxBlur effect in JavaFX.
Properties
The properties of the class along with the setter methods are described in the following table.
Property | Description | Setter Methods |
---|---|---|
height | This is a double type property. It represents the height of the blur effect. | setHeight(double value) |
width | This is a double type property. It represents the width of the blur effect. | setWidth(double value) |
input | This property is of Effect type. This represents the input for the effect. | setInput(Effect value) |
iterations | It represents the number of repetitions of the blur effect. This is of integer type. | setIterations(int value) |
Constructors
The class contains two constructors
- public BoxBlur() : Creates the new instance with the default value of properties.
- public BoxBlur(Double width, Double height, int iterations) : creates the new instance with the specified values.
Example:
Next TopicJavaFX GaussianBlur Effect