An utility for converting and resizing images
Project description
cmagick
Cmagick is a subprocess-based simple ImageMagick interaction for Python, supporting Python 3.6+ and Linux distributions.
The functionalities of ImageMagick implemented in cmagick are:
-Converting images to the following formats (bmp,eps,gif,tiff,webp,wbmp,tga,png,jpg,jpeg,hdr,exr)
-Resizing pictures with a declarative size
-Support path arguments
Usage
Examples:
To convert images
from cmagick import cmagick
cmagick.convert('website.jpg', 'website.webp')
To resize images
from cmagick import cmagick
cmagick.resize('website.jpg','100x100','website.jpg')
To convert and save in a defined directory
from cmagick import cmagick
cmagick.convert('website.jpg', '/Desktop/newname.webp')
To check the current formats available
from cmagick import cmagick
print(cmagick.list_formats())
Prerequisites
Python 3.6+
imagemagick for apt Debian/Ubuntu ImageMagick for yum RPM
Installation
You can install the package from PyPI:
pip install cmagick
You can install the package the GitHub repository:
$ git clone git://github.com/aissa-laribi/cmagick.git
$ cd cmagick/
$ python3 setup.py install --user
To Uninstall
$ pip uninstall cmagick
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file cmagick-0.1.4.tar.gz.
File metadata
- Download URL: cmagick-0.1.4.tar.gz
- Upload date:
- Size: 2.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.8.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6355831afb46d52dd488c158fb5c0675c9bc73b2d52e4fd884b4d264df01c052
|
|
| MD5 |
beaac84048513e4c138e55ab4c58af26
|
|
| BLAKE2b-256 |
d5e0f0c22db92545233f8be8548d211671830718b46a14968844f7cebc50b087
|
File details
Details for the file cmagick-0.1.4-py3-none-any.whl.
File metadata
- Download URL: cmagick-0.1.4-py3-none-any.whl
- Upload date:
- Size: 3.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.8.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1c2a36d54923f5236d7bb68685a0f791a570cd8bd441dd93ecce7dc10698ddb0
|
|
| MD5 |
687ad32cd5ee38e0cd56d4c61a1066d2
|
|
| BLAKE2b-256 |
ee7a6ededa041746d031aa2d796daf58e8e7dcfa57a59e394d72b683ec47d5c2
|