-
- All Implemented Interfaces:
public class Gif.Companion
-
-
Field Summary
Fields Modifier and Type Field Description public final static Gif.CompanionINSTANCE
-
Method Summary
Modifier and Type Method Description final Result<Gif>from(File file, PixelPacking pixelPacking)Open a gif file, using a java.io.RandomAccessFile to access the data: The gif wont be loaded fully in memory. final Result<Gif>from(InputStream inputStream, PixelPacking pixelPacking)Load a gif from an InputStream: The InputStream will be fully read and loaded in memory. final Giffrom(Gif gif)Creates a new gif from an existing gif. -
-
Method Detail
-
from
final Result<Gif> from(File file, PixelPacking pixelPacking)
Open a gif file, using a java.io.RandomAccessFile to access the data: The gif wont be loaded fully in memory. It allows handling crazy big files, as some gifs are actually several hundred mega byte big, as some users seem to mistake them for movie files.
- Parameters:
file- The file to openpixelPacking- Optional pixel packing, default to ARGB.
-
from
final Result<Gif> from(InputStream inputStream, PixelPacking pixelPacking)
Load a gif from an InputStream: The InputStream will be fully read and loaded in memory.
- Parameters:
inputStream- The input stream containing the gif data.pixelPacking- Optional pixel packing, default to ARGB.
-
-
-
-