import javafx.application.Application; import javafx.scene.Group; import javafx.scene.Scene; import javafx.scene.effect.Glow; import javafx.scene.image.Image; import javafx.scene.image.ImageView; import javafx.stage.Stage; publicclassGlowEffectExampleextendsApplication { @Override publicvoidstart(Stage stage) { //Creating an image Imageimage=newImage("https://www.ljjyy.com/img/logo.png"); //Setting the image view ImageViewimageView=newImageView(image); //setting the fit width of the image view imageView.setFitWidth(200); //Setting the preserve ratio of the image view imageView.setPreserveRatio(true); //Instantiating the Glow class Glowglow=newGlow(); //setting level of the glow effect glow.setLevel(0.9); //Applying bloom effect to text imageView.setEffect(glow); //Creating a Group object Grouproot=newGroup(imageView); //Creating a scene object Scenescene=newScene(root, 600, 300); //Setting title to the Stage stage.setTitle("Sample Application"); //Adding scene to the stage stage.setScene(scene); //Displaying the contents of the stage stage.show(); } publicstaticvoidmain(String args[]){ launch(args); } }