How to draw a gif animation in java? [duplicate]
问题 This question already has answers here : Show an animated BG in Swing (3 answers) .gif image doesn't moves on adding it to the JTabbed pane (1 answer) Closed 5 years ago . I have some gif animated images (see sample image below) and when I draw them with the graphics object, I am getting only the first image, I know I can do this with JLabel (from other stackoverflow answers) but I want to do that with the graphics object, can anyone please tell me an easy way how to draw the whole animation?