Java Swing support for animations
Suppose you have to create a simple 2D animation, like the drawing of a graph where the nodes can change their position. I was wondering how it would be different to create something like this using Java Swing or a bitmap based framework, where you can only draw points and lines
I mean: does Swing 开发者_如何学Gooffer more than simply drawing on a canvas? If it does, can you list the main instruments Swing offers to create animations that are not simple drawing primitives?
You should check Java2D
There is also a demo page available
Swing is a GUI framework in which the Java 2D API can be used to create arbitrarily complex animations; the links from @stacker are exemplary. As concrete examples, I always liked the animation in this particle simulation and this dynamical system.
精彩评论