Skip to content

๐ŸŽฌ Welcome to imgif!

โœจ A playful Python library for converting image sequences into animated GIFs with ease!

Turn your image sequences into delightful animated GIFs with just a few lines of code. Whether you're creating animations from screenshots, visualizing data, or just having fun, imgif makes it simple and enjoyable! ๐Ÿš€

Features

  • ๐ŸŽจ Simple API - Convert images to GIF in just 3 lines of code
  • โšก Fast & Efficient - Built on Pillow for optimal performance
  • ๐ŸŽ›๏ธ Highly Configurable - Control duration, quality, size, and more
  • ๐Ÿ’ป CLI Interface - Use directly from the command line
  • ๐Ÿ“ Fully Typed - Complete type annotations for great IDE support
  • ๐Ÿงช 100% Test Coverage - Reliable and well-tested
  • ๐ŸŽญ Rich Output - Beautiful progress indicators and error messages

Quick Example

from imgif import ImageToGifConverter

# Create converter
converter = ImageToGifConverter()

# Convert images to GIF
converter.convert(
    input_dir="./my_images",
    output_path="./output.gif",
    duration=0.5,  # seconds per frame
)

print("๐ŸŽ‰ GIF created successfully!")
# Basic usage
imgif ./my_images output.gif

# With options
imgif ./my_images output.gif --duration 0.5 --loop 0

# See all options
imgif --help
from imgif import ImageToGifConverter, GifConfig

# Create custom configuration
config = GifConfig(
    fps=10,
    loop=0,
    width=800,
    optimize=True,
    maintain_aspect_ratio=True
)

# Convert with config
converter = ImageToGifConverter()
converter.convert_with_config("./images", "output.gif", config)

Installation

Install imgif using pip:

pip install imgif

For development:

# Clone the repository
git clone https://github.com/atick-faisal/img2gif.git
cd img2gif

# Install with uv
uv sync

Next Steps

Why imgif?

Creating animated GIFs from images shouldn't be complicated. imgif provides a clean, intuitive API that makes GIF creation fun and straightforward, while still offering powerful configuration options for advanced users.

Perfect for

  • ๐Ÿ“ธ Creating animations from screenshots
  • ๐Ÿ“Š Visualizing data over time
  • ๐ŸŽฎ Game development assets
  • ๐Ÿ“ฑ Social media content
  • ๐ŸŽ“ Educational materials
  • ๐ŸŽจ Digital art projects

Community & Support


Made with โค๏ธ and Python ๐Ÿ