Class GifSequenceWriter


  • public class GifSequenceWriter
    extends java.lang.Object
    Baseed on work by Elliot Kroo on 2009-04-25 and adapted rewritten.

    This work is licensed under the Creative Commons Attribution 3.0 Unported License. To view a copy of this license, visit http://creativecommons.org/licenses/by/3.0/ or send a letter to Creative Commons, 171 Second Street, Suite 300, San Francisco, California, 94105, USA.

    • Constructor Detail

      • GifSequenceWriter

        public GifSequenceWriter​(long frameDelayMillis,
                                 boolean infiniteLoop)
      • GifSequenceWriter

        public GifSequenceWriter()
    • Method Detail

      • withFrameDelay

        public GifSequenceWriter withFrameDelay​(long frameDelayMillis)
      • withInfiniteLoop

        public GifSequenceWriter withInfiniteLoop​(boolean infiniteLoop)
      • output

        public java.nio.file.Path output​(ImmutableImage[] images,
                                         java.nio.file.Path path)
                                  throws java.io.IOException
        Throws:
        java.io.IOException
      • output

        public java.nio.file.Path output​(ImmutableImage[] images,
                                         java.io.File file)
                                  throws java.io.IOException
        Throws:
        java.io.IOException
      • output

        public java.nio.file.Path output​(ImmutableImage[] images,
                                         java.lang.String path)
                                  throws java.io.IOException
        Throws:
        java.io.IOException
      • bytes

        public byte[] bytes​(ImmutableImage[] images)
                     throws java.io.IOException
        Throws:
        java.io.IOException
      • getNode

        protected javax.imageio.metadata.IIOMetadataNode getNode​(javax.imageio.metadata.IIOMetadataNode rootNode,
                                                                 java.lang.String nodeName)
        Returns an existing child node, or creates and returns a new child node (if the requested node does not exist).
        Parameters:
        rootNode - the IIOMetadataNode to search for the child node.
        nodeName - the name of the child node.
        Returns:
        the child node, if found or a new node created with the given name.
      • populateGraphicsControlNode

        protected void populateGraphicsControlNode​(javax.imageio.metadata.IIOMetadataNode root,
                                                   java.time.Duration frameDelay)
      • populateCommentsNode

        protected void populateCommentsNode​(javax.imageio.metadata.IIOMetadataNode root)
      • populateApplicationExtensions

        protected void populateApplicationExtensions​(javax.imageio.metadata.IIOMetadataNode root,
                                                     boolean infiniteLoop)