This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Swing / AWT / SWT and the fly likes Converting to an Animated GIF or something similar Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Converting to an Animated GIF or something similar" Watch "Converting to an Animated GIF or something similar" New topic
Author

Converting to an Animated GIF or something similar

Yohan Weerasinghe
Ranch Hand

Joined: Oct 07, 2010
Posts: 499

Hi, please have a look at the following code (This is a test code, that's why you can see just a one class with a subclass and a simple GUI )



Now, what I need is, when the user click on the "Create" button, the generated output slideshow, should be saved in the user's computer as an Animated GIF or SWF or something that which can show the animated images when doubled clicked, or opened in web browser (Like animated GIF). I ahve no idea about how to do this. Please help me to achieve my task.. Thanks


Are you better than me? Then please show me my mistakes..
Darryl Burke
Bartender

Joined: May 03, 2008
Posts: 4523
    
    5

Searching the net for "java save animated gif" gave a few million results, and at least some of the first-page results were accompanied by code.


luck, db
There are no new questions, but there may be new answers.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41123
    
  45
Note that GIF is an 8-bit format, so any conversion from JPEG to GIF will almost certainly result in a loss of quality. It will also present the non-trivial problem of which colors to use in the resulting GIF.


Ping & DNS - my free Android networking tools app
Yohan Weerasinghe
Ranch Hand

Joined: Oct 07, 2010
Posts: 499

Darryl Burke wrote:Searching the net for "java save animated gif" gave a few million results, and at least some of the first-page results were accompanied by code.


Thanks for the info. Yes, I saw some of them. Will check and be back...
Yohan Weerasinghe
Ranch Hand

Joined: Oct 07, 2010
Posts: 499

Ulf Dittmer wrote:Note that GIF is an 8-bit format, so any conversion from JPEG to GIF will almost certainly result in a loss of quality. It will also present the non-trivial problem of which colors to use in the resulting GIF.


Thanks for the info. I will definitely keep this in my mind when I am actually doing the project...
 
 
subject: Converting to an Animated GIF or something similar
 
Similar Threads
running gifs
How to use getModel() with JTabbedPane ?
keylistener in a custom component
update the JVM from 1.5 to 1.6, JDialog background cant paint
Why are my JFrames closing?