Skip to main content

Cut images into tiles and reassemble them..

Project description

https://badge.fury.io/py/image_slicer.png https://secure.travis-ci.org/samdobson/image_slicer.png https://coveralls.io/repos/samdobson/image_slicer/badge.png

documentation | website

Image Slicer

What does it do?

Splits an image into n equally-sized tiles. Also capable of joining the pieces back together.

Whether you are planning a collaborative art project, creating a jigsaw puzzle, or simply get a kick out of dividing images into identical quadrilaterals… this package is for you!

Installation

$ pip install image_slicer

Python versions supported:

  • 2.6+

  • 3.2+

Usage

Slice an image with Python:

>>> import image_slicer
>>> image_slicer.split_image('cake.jpg', 4)
(<Tile #1 - cake_01_01.png>, <Tile #2 - cake_01_02.png>, <Tile #3 - cake_02_01.png>, <Tile #4 - cake_02_02.png>)

… or from the command line:

$ slice-image cake.jpg 36

Further examples can be found in the documentation.

Used by

  • split-image.net

  • puzzle-shifter.net

  • reveal-image.net

  • collab-art.net

About

This module was developed for collabart, a web application to help you launch a collaborative art project.

0.1.0 (coming soon)

  • New Tile class.

  • split_image() now saves tiles by default.

  • get_basename() can now handle paths.

  • More comprehensive validation in validate_image().

  • Fix incorrect filenames returned by save_tiles().

  • Expand documentation.

  • Improve test coverage.

0.0.2 (07/23/2013)

  • Fix dependencies in setup.py

0.0.1 (07/19/2013)

  • Initial release.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

image_slicer-0.1.0.tar.gz (90.5 kB view details)

Uploaded Source

File details

Details for the file image_slicer-0.1.0.tar.gz.

File metadata

  • Download URL: image_slicer-0.1.0.tar.gz
  • Upload date:
  • Size: 90.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for image_slicer-0.1.0.tar.gz
Algorithm Hash digest
SHA256 5786b3472e31665520c3ba4681da4f1f5fd614d007670aa79d5f7837d947245e
MD5 58a969bd0685ad66495be077af1cc4ad
BLAKE2b-256 c4d099751fddccd035a4e04c97c79215f0e29aedeb0d8cf854de3c074014a4d9

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page