CHAPTER 24

image

Understanding the Image API

In this chapter, you will learn:

  • What the Image API is
  • How to load an image
  • How to view an image in an ImageView node
  • How to perform image operations such as reading/writing pixels, creating an image from scratch, and saving the image to the file system
  • How to take the snapshot of nodes and scenes

What Is the Image API?

JavaFX provides the Image API that lets you load and display images, and read/write raw image pixels. A class diagram for the classes in the image API is shown in Figure 24-1. All classes are in the javafx.scene.image package. The API lets you

  • Load an image in memory
  • Display an image as a ...

Get Learn JavaFX 8: Building User Experience and Interfaces with Java 8 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.