2D « Graphics Desktop « Java Articles

Home
Java Articles
1.Build Deploy
2.Class
3.Core Library
4.Data Types
5.Database JDBC
6.Design
7.Development
8.File Input Output
9.Graphics Desktop
10.J2EE Enterprise
11.J2ME Wireless
12.JVM
13.Language
14.Library Product
15.Network
16.Security
17.SOA Web Services
18.Test
19.Web Development
20.XML
Java Articles » Graphics Desktop » 2D 

1. Learning Java 2D, Part 1    java.sun.com

Java 2D, however, defines coordinates in units (72 units to an inch), and rendering occurs in a hypothetical plane called the user space.

2. 2D animation with image-based paths    ibm.com

In two-dimensional (2D) animation it is often necessary to move an object or objects around the 2D area in predetermined patterns, sometimes called control paths. This type of animation requires that you solve two problems:

3. Introduction to Java 2D    ibm.com

Discover the power and capabilities of the Java? 2D library with Java expert Mitch Goldstein. Mitch takes you step by step through the advantages of advanced drawing, text layout, and image manipulation that Java 2D brings to GUI programming.

4. Java 2D imaging for the Standard Widget Toolkit    ibm.com

SWT (Standard Widget Toolkit) is the widget toolkit that is used on the Eclipse platform. It can also be used as a serious alternative to Swing/AWT to build any kind of Java GUI application. With the increasing popularity of the Eclipse platform over the last two years, SWT has come into the spotlight, and recently it has begun to replace Swing/AWT in some applications. SWT's popularity springs from the fact that it is a cross-platform toolkit that makes use of native widgets and has a similar level of functionality to Swing and other modern toolkits. With SWT, you never have to choose between portability, functionality, and performance.

5. Creating Java2D composites for rollover effects    ibm.com

The RolloverIcon instance is wrapping the original icon we want to paint with the graphics effect shown in Figure 1. To do this we can make use of the composite property on the Graphics2D object. The composite property is typed to the interface java.awt.Composite and all primitive drawing on the graphics surface done by the Graphics2D object is directed through its composite. A number of pre-existing composite classes exist such as one for creating an XOR effect. The XORComposite is the class sun.java2d.loops.XORComposite and its constructor takes an argument of the color for the drawing being rendered to be XOR'd against. Each color is made up of a red, green, and blue value, and if color is XOR'd against black ( which is r,g,b of 0,0,0 ) then it is effectively inverted. To see this, the paint method could be written as follows:

6. Finding text boundaries in Java    ibm.com

These problems are the motivation behind the BreakIterator framework in the Java class libraries. They are also cases of the general problem of text-boundary analysis, or the breaking down of a large body of text into its constituent elements according to some set of criteria. The Java BreakIterator class was written by Taligent, a subsidiary of IBM, now part of IBM's Center for Java Technology. We recently finished a completely new and updated version of the framework that will be made available on IBM's Alphaworks Web site. This paper examines the internals of both frameworks and explores some of the issues that come up when designing a framework for text-boundary analysis.

7. Understanding the 2D Discrete Cosine Transform in Java    developer.com

What this means for me is that I don't need to develop a new DCT program to handle the 2D case. Rather, I can perform all the necessary DCT transforms that I need using the static one-dimensional forward DCT method named transform belonging to the class named ForwardDCT01. I developed and explained that class in the earlier lesson entitled Understanding the Discrete Cosine Transform in Java.

8. Understanding Transforms in Java 2D    developer.com

The first lesson in this series was titled "Back to Basics in the Java 3D API." The previous lesson was titled "Combining Rotation and Translation in Java 3d."; This lesson is titled "Understanding Transforms in Java 2D."

9. Using the Java 2D LookupOp Filter Class to Scramble and Unscramble Images    developer.com

In this lesson, I will show you how to use the LookupOp image-filtering class from the Java 2D API, along with the Random class from the java.util package to write a pair of easy-to-use programs to scramble and unscramble images in a reasonably secure fashion.

10. Java 2D Graphics, The Point2D Class    developer.com

This lesson is primarily concerned with the use of the java.awt.geom.Point2D class. It also illustrates the use of nested top-level classes in the Java 2D Graphics API. This is a concept that was explained in an earlier tutorial lesson. If you aren’t familiar with this concept, you should review the earlier tutorial that explains it.

11. 2D Fourier Transforms using Java    developer.com

This is the first part of a two-part lesson. In this lesson, I will teach you how to perform two-dimensional (2D) Fourier transforms using Java. I will

12. Using the Java 2D BandCombineOp Filter Class to Process Images    developer.com

The purpose of this program is to illustrate the use of the BandCombineOp image-filtering class of the Java 2D API. (See general comments in the class named ImgMod038 that I explained in the earlier lesson entitled "Using the Java 2D LookupOp Filter Class to Process Images" (see References). Those comments apply to this program also.)

13. Java 2D Graphics, Solid Color Fill    developer.com

In his book entitled Java 2D Graphics, Jonathan Knudsen provides a sample program that produces a radial color gradient. This is a good example program to take a look at if you need to define your own class that implements the Paint interface.

14. Using the Java 2D LookupOp Filter Class to Process Images    developer.com

Listing 5 signals the end of the processImg method as well as the end of the program named ImgMod38. Hopefully, this simple program has taught you the essentials of using the framework program named ImgMod05, along with the LookupOp image filtering class of the Java 2D API for the filtering of images.

15. 2D Fourier Transforms using Java, Part 2    developer.com

This is the second part of a two-part lesson. The first part published earlier was entitled 2D Fourier transforms using Java. In this lesson, I will teach you how to perform two-dimensional (2D) Fourier transforms using Java. I will

16. Java 2D Graphics, The Graphics2D Class    developer.com

So there you have it. An introduction to the use of the Graphics2D class along with a number of associated other aspects of the Java 2D Graphics API.

17. Java 2D Graphics, The Composite Interface and Transparency    developer.com

There are at least two different ways to achieve transparency in Java 2D. One way is to use new constructors for the Color class that allow you to create solid colors with a specified degree of transparency. I will discuss that approach in a subsequent lesson.

18. Using the Java 2D AffineTransformOp Filter Class to Process Images    developer.com

In the previous lesson entitled Using the Java 2D LookupOp Filter Class to Process Images, I taught you how to write programs that use the LookupOp image-filtering class of the Java 2D API for a variety of image-processing purposes.

19. Java 2D Graphics, The Color Constructors and Transparency    developer.com

There are at least two different ways to achieve transparency in Java 2D. One approach is to use new constructors for the Color class that allow you to create solid colors with a specified degree of transparency. I will discuss that approach in this lesson.

20. Understanding the 2D Discrete Cosine Transform in Java, Part 2    developer.com

2440 Understanding the Lempel-Ziv Data Compression Algorithm in Java 2442 Understanding the Huffman Data Compression Algorithm in Java 2444 Understanding the Discrete Cosine Transform in Java 2446 Understanding the 2D Discrete Cosine Transform in Java, Part 1 1468 Plotting Engineering and Scientific Data using Java 1478 Fun with Java, How and Why Spectral Analysis Works 1482 Spectrum Analysis using Java, Sampling Frequency, Folding Frequency, and the FFT Algorithm 1483 Spectrum Analysis using Java, Frequency Resolution versus Data Length 1484 Spectrum Analysis using Java, Complex Spectrum and Phase Angle 1485 Spectrum Analysis using Java, Forward and Inverse Transforms, Filtering in the Frequency Domain 1486 Fun with Java, Understanding the Fast Fourier Transform (FFT) Algorithm 1489 Plotting 3D Surfaces using Java 1490 2D Fourier Transforms using Java 1491 2D Fourier Transforms using Java, Part 2

21. An introduction to the Java 2D API    developer.com

Below are examples of the new java2d API in use, each one building on the ones previous. After studying the code and this accompanying text, you should have a basic understanding of how to use the new Graphics2D class, an understanding of GeometricPaths and Strokes and a detailed knowledge of the AffineTransform class. We also introduce ancillary classes such as Point2D when necessary. With a solid understanding of such classes, you will be able to master the rest of the java2d API. Your applets will then be able to draw sophisticated two-dimensional pictures rivaling what's available through languages such as Postscript.

22. Using the Java 2D ConvolveOp Filter Class to Process Images    developer.com

However, if you don't have the time to do that, you should take a look at the earlier lesson titled Using the Java 2D LookupOp Filter Class to Process Images (see Resources), in which I summarized the behavior of the framework program named ImgMod05.

23. Java 2D Graphics, Texture Fill    developer.com

At construction time, the texture is anchored to the upper left corner of a Rectangle2D that is specified in user space. Texture is computed for locations in the device space by conceptually replicating the specified Rectangle2D infinitely in all directions in user space and mapping the BufferedImage to each replicated Rectangle2D.

24. Using the Java 2D ColorConvertOp and RescaleOp Filter Classes to Process Images    developer.com

However, if you don't have the time to do that, you should take a look at the earlier lesson titled "Using the Java 2D LookupOp Filter Class to Process Images" (see Resources), in which I summarized the behavior of the framework program named ImgMod05.

25. Java 2D Graphics, The Composite Interface, GradientPaint, and Transparency    developer.com

There are at least two different ways to achieve transparency in Java 2D. One approach is to use new constructors for the Color class that allow you to create solid colors with a specified degree of transparency. I will discuss that approach in a subsequent lesson.

26. Java 2D Graphics, The Stroke Interface    developer.com

I also explained that without understanding the behavior of other classes and interfaces such as Shape, AffineTransform, GraphicsConfiguration, PathIterator, and Stroke, it is not possible to fully understand the inner workings of the Graphics2D class.

27. Java 2D Graphics, Gradient Color Fill    developer.com

The GradientPaint class can be used to fill a Shape with a color gradient. The gradient progresses from one specified color at one point in user space to a different specified color at a different point in user space.

28. Java 2D Graphics, The Shape Interface, Part 2    developer.com

This is what Jonathan Knudsen has to say on the subject in his excellent book entitled Java 2D Graphics, from O’Reilly.

29. Java 2D Graphics, Simple Affine Transforms    developer.com

The name of the sample program is Affine01.java. This program illustrates the use of convenience method of the Graphics2D class that make it very easy to apply transforms of the following types:

30. Java 2D Graphics, The Shape Interface, Part 1    developer.com

Java 2D provides a number of classes in the java.awt.geom package that implement the Shape interface, such as Rectangle2D.Double and Ellipse2D.Double. I have illustrated the use of some of these classes in previous lessons, and undoubtedly will continue to illustrate them in subsequent lessons. This lesson illustrates the use of the Line2D.Double, Rectangle2D.Double and Ellipse2D.Double classes.

java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.