I drew a motion picture (animation.gif) on my applet by writing "g.drawImage(........)" in the "public void paint(Graphic g)" method. The problem is the applet PANEL always refreshed when the motion picture was playing. Can anybody tell me how to solve this problem? Or How to reduce the side-effect brought by the refreshing. regards, mellihoney [ August 31, 2003: Message edited by: Mellihoney Michael ]
I think by "motion picture" maybe you're talking about an animated GIF? If that's the case, there's not much you can do that I'm aware of. What you could do, instead, is to do the animation explicitly in Java -- i.e, have one GIF for each frame, and paint them one at a time; this way refreshing won't restart the animation. There are several animation examples in the demos/applets directory that comes with the JDK.