Library which replicates the Paint.net contrast & brightness functionality in Python, allowing you to increase the contrast of an image until it turns B&W.
Project description
max-contrast
Library which replicates the Paint.net contrast & brightness functionality in Python, allowing you to increase the contrast of an image until it turns B&W.
Usage
from max_contrast import contrast_image
# contrast_image(image_path, brightness, contrast, save_path=False, show=False)
contrast_image("./example.png", 0, 100, "./example-contrasted.png")
Example (Contrasting 100, Brightness 0)
Example (Contrasting -100, Brightness 0)
Credits
Inspiration for the code has been taken from OpenPND: https://github.com/rivy/OpenPDN
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
max-contrast-0.0.1.tar.gz
(3.0 kB
view hashes)
Built Distribution
Close
Hashes for max_contrast-0.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 687e0f61e6d1c202e77bdca3842763172f900b0c8bf98352e8cd367edbb559fe |
|
MD5 | 78f62e229eb7871006ddf1008cd13721 |
|
BLAKE2b-256 | d1b8591fbeacf56093b6e0c54c7df16566d10b9957d3e8c0e2c8076a801848fe |