Skip to main content

Writing Animated GIFs from JKD6

4 replies [Last post]
aberrant
Offline
Joined: 2006-02-02

I found a post stating that animated GIFs could be created from a stock JDK6. I have some code that calls writeToSequence() a number of times, but I'm not sure how to set the frame rate of the resulting image. Can anyone tell me how to set the framerate/delay?

Thanks.
Aberrant

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Brian Burkhalter

You would need to pass to the writer a native GIF image metadata object with

/javax_imageio_gif_image_1.0/GraphicControlExtension@delayTime

set to the desired inter-frame delay in hundredths of a second.

Please see

http://java.sun.com/javase/6/docs/api/javax/imageio/metadata/doc-files/g...

for more information.

Brian

PS For issuess with the Java SE Image I/O packages as opposed to JAI Image I/O
Tools the most appropriate mailing list is java-imageio-interest@java.sun.com

On Fri, 21 Sep 2007, jai-imageio@javadesktop.org wrote:

> I found a post stating that animated GIFs could be created from a stock JDK6. I have some code that calls writeToSequence() a number of times, but I'm not sure how to set the frame rate of the resulting image. Can anyone tell me how to set the framerate/delay?
>
> Thanks.
> Aberrant

>^..^< >^..^<

Brian Burkhalter
Java Media, Imaging, and Graphics
Sun Microsystems, Inc.

This email message is for the sole use of the intended recipient(s)
and may contain confidential and privileged information. Any
unauthorized review, use, disclosure or distribution is prohibited.
If you are not the intended recipient, please contact the sender by
reply email and destroy all copies of the original message.

---------------------------------------------------------------------
To unsubscribe, e-mail: interest-unsubscribe@jai-imageio.dev.java.net
For additional commands, e-mail: interest-help@jai-imageio.dev.java.net

aberrant
Offline
Joined: 2006-02-02

Thank you, can you point me to some examples of specifying metadata?

Brian Burkhalter

Please see this posting and the attachment thereto:

http://forums.java.net/jive/thread.jspa?messageID=214284&#214284

On Tue, 25 Sep 2007, jai-imageio@javadesktop.org wrote:

> Thank you, can you point me to some examples of specifying metadata?
> [Message sent by forum member 'aberrant' (aberrant)]
>
> http://forums.java.net/jive/thread.jspa?messageID=237022

>^..^< >^..^<

Brian Burkhalter
Java Media, Imaging, and Graphics
Sun Microsystems, Inc.

This email message is for the sole use of the intended recipient(s)
and may contain confidential and privileged information. Any
unauthorized review, use, disclosure or distribution is prohibited.
If you are not the intended recipient, please contact the sender by
reply email and destroy all copies of the original message.

---------------------------------------------------------------------
To unsubscribe, e-mail: interest-unsubscribe@jai-imageio.dev.java.net
For additional commands, e-mail: interest-help@jai-imageio.dev.java.net

aberrant
Offline
Joined: 2006-02-02

Fantastic! Thank you.