Created
November 18, 2012 15:54
-
-
Save phdoerfler/4105954 to your computer and use it in GitHub Desktop.
Saves a snapshot of the entire scene in JavaFX
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BufferedImage img = SwingFXUtils.fromFXImage(stage.getScene().snapshot(null), null); | |
ImageIO.write(img, "png", new File("snapshot.png")); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment