Graphics Context

A large part of the process of writing graphics and imaging applications in Java comes down to specifying the desired graphics context for rendering. The graphics context refers to a set of attributes that specify the properties for the output rendering. These properties can be as simple as the color used for filling a shape or can be more complex, such as setting the antialiasing for drawing lines. Throughout the next several chapters, pay close attention and make a mental note when changes to the graphics context are made. Most changes to the graphics context are accomplished with methods that begin with set, for example, setPaint() or setColor().

Get Java™ Media APIs: Cross-Platform Imaging, Media, and Visualization 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.