public synchronized void addFrame(final Image image,final long frameDuration){
  totalDuration+=frameDuration;
  frames.add(new AnimFrame(image,totalDuration));
}

public synchronized void addFrame ( final Image image , final long frameDuration ) { totalDuration += frameDuration ; frames . add ( new AnimFrame ( image , totalDuration ) ) ; }
adds an image to the animation with the specified duration ( time to display the image ) .
