An open API service indexing awesome lists of open source software.

https://github.com/grandmoff100/imagelayers

Split and process image layers and segments.
https://github.com/grandmoff100/imagelayers

image-processing image-segmentation pillow pypi-package python3 readme

Last synced: 7 months ago
JSON representation

Split and process image layers and segments.

Awesome Lists containing this project

README

          

# ImageLayers

## Installation
There are a variety of ways to install this project.

### From [Github](https://github.com/GrandMoff100/ImageLayers)
```
$ git clone https://github.com/GrandMoff100/ImageLayers
$ cd ImageLayers
$ python setup.py install
```

### From [PyPI](https://pypi.org/project/imagelayers)
```
$ pip install imagelayers
```

## Usage

This project provides two classes, `ImageLayer`, and `LayeredImage`.

### Example
```py
from PIL import Image

with Image.open('image.png') as f:
img = LayeredImage(f)

i = 0
for layer in img.layersbyedge(): # layer is an instance of `ImageLayer`
layer.save(f'layer{i}.png')
i += 1
```