# Uses of Class
javafx.scene.image.WritableImage

Packages that use WritableImage
Package
Description
javafx.embed.swing
Provides the set of classes to use JavaFX inside Swing applications.
javafx.scene
Provides the core set of base classes for the JavaFX Scene Graph API.
javafx.scene.robot
Provides API for simulating user interaction such as typing keys on the keyboard and using the mouse.

## Uses of WritableImage in javafx.embed.swing

Methods in javafx.embed.swing that return WritableImage
Modifier and Type
Method
Description
`static WritableImage`
SwingFXUtils.`toFXImage(BufferedImage bimg, WritableImage wimg)`
Snapshots the specified `BufferedImage` and stores a copy of its pixels into a JavaFX `Image` object, creating a new object if needed.
Methods in javafx.embed.swing with parameters of type WritableImage
Modifier and Type
Method
Description
`static WritableImage`
SwingFXUtils.`toFXImage(BufferedImage bimg, WritableImage wimg)`
Snapshots the specified `BufferedImage` and stores a copy of its pixels into a JavaFX `Image` object, creating a new object if needed.

## Uses of WritableImage in javafx.scene

Methods in javafx.scene that return WritableImage
Modifier and Type
Method
Description
`WritableImage`
SnapshotResult.`getImage()`
Gets the image generated by the snapshot operation.
`WritableImage`
Node.`snapshot(SnapshotParameters params, WritableImage image)`
Takes a snapshot of this node and returns the rendered image when it is ready.
`WritableImage`
Scene.`snapshot(WritableImage image)`
Takes a snapshot of this scene and returns the rendered image when it is ready.
Methods in javafx.scene with parameters of type WritableImage
Modifier and Type
Method
Description
`WritableImage`
Node.`snapshot(SnapshotParameters params, WritableImage image)`
Takes a snapshot of this node and returns the rendered image when it is ready.
`void`
Node.`snapshot(Callback<SnapshotResult,Void> callback, SnapshotParameters params, WritableImage image)`
Takes a snapshot of this node at the next frame and calls the specified callback method when the image is ready.
`WritableImage`
Scene.`snapshot(WritableImage image)`
Takes a snapshot of this scene and returns the rendered image when it is ready.
`void`
Scene.`snapshot(Callback<SnapshotResult,Void> callback, WritableImage image)`
Takes a snapshot of this scene at the next frame and calls the specified callback method when the image is ready.

## Uses of WritableImage in javafx.scene.robot

Methods in javafx.scene.robot that return WritableImage
Modifier and Type
Method
Description
`WritableImage`
Robot.`getScreenCapture(WritableImage image, double x, double y, double width, double height)`
Returns a `WritableImage` containing the specified rectangular area relative to the primary screen.
`WritableImage`
Robot.`getScreenCapture(WritableImage image, double x, double y, double width, double height, boolean scaleToFit)`
Returns a `WritableImage` containing the specified rectangular area relative to the primary screen.
`WritableImage`
Robot.`getScreenCapture(WritableImage image, Rectangle2D region)`
Returns a `WritableImage` containing the specified rectangular area relative to the primary screen.
`WritableImage`
Robot.`getScreenCapture(WritableImage image, Rectangle2D region, boolean scaleToFit)`
Returns a `WritableImage` containing the specified rectangular area relative to the primary screen.
Methods in javafx.scene.robot with parameters of type WritableImage
Modifier and Type
Method
Description
`WritableImage`
Robot.`getScreenCapture(WritableImage image, double x, double y, double width, double height)`
Returns a `WritableImage` containing the specified rectangular area relative to the primary screen.
`WritableImage`
Robot.`getScreenCapture(WritableImage image, double x, double y, double width, double height, boolean scaleToFit)`
Returns a `WritableImage` containing the specified rectangular area relative to the primary screen.
`WritableImage`
Robot.`getScreenCapture(WritableImage image, Rectangle2D region)`
Returns a `WritableImage` containing the specified rectangular area relative to the primary screen.
`WritableImage`
Robot.`getScreenCapture(WritableImage image, Rectangle2D region, boolean scaleToFit)`
Returns a `WritableImage` containing the specified rectangular area relative to the primary screen.