Metadata-Version: 2.4
Name: pyimgrid
Version: 0.1.0
Summary: Generates a grid image from an input image.
Author: Pablo Alejandro Carravetti
License: GPL-3.0-or-later
Requires-Python: >=3.9
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: Pillow
Dynamic: license-file

# pyimgrid

Generates a grid image from an input image.

## Installation

```bash
pip install pyimgrid
```

## Usage

```python
from pyimgrid import create_image

create_image(
    src='input.png',
    dst='output.png',
    cols=3,
    rows=2,
    gap=5,
)
```

### Parameters

- **src** (`str`): Path to the input image.
- **dst** (`str`): Path to save the generated image.
- **cols** (`int`): Number of columns in the grid.
- **rows** (`int`): Number of rows in the grid.
- **gap** (`int`): Spacing in pixels between images (and around the edges).
- **bg** (`str` | `tuple` | `None`, default `None`): Background color.
  - `None`: defaults to white (`#ffffff`), or transparent if `dst` is a `.png` file.
  - `str`: a color in any format accepted by Pillow (e.g. `'#ffffff'`).
  - `tuple`: an RGBA tuple (e.g. `(0, 0, 0, 0)`).

## License

MIT
