A utility for separating a single png (such as one produced by an [inkscape](https://inkscape.org/) export) into
separate per-color images such as might be useful for silk screen printing at a place like
[ooshirts](http://www.ooshirts.com).
## Features
The current feature set includes:
- separation into a specifiable number colors
- a "near pixel threshold" option for fuzzily matching colors that are close but not exactly what's expected
- a "white base" option to produce a white pixel under all active pixels of any color
- a specifiable alpha threshold beneath which all pixels will be discarded
## Requirements
Colorsep probably requires python 3. I'll gladly accept PRs to fix this and/or assertions to the contrary. I just
haven't tested it.
## Install
It should be as simple as `pip install colorsep` for python-friendly folks.
## Basic usage
To generate the images I needed to make my t-shirt, I ran this:
```colorsep --input resources/farm_scene.png --output-base output/output_ --num-colors=7 --base-white --near-pixel-threshold=100```
To get help:
```
$ colorsep --help
Usage: colorsep [OPTIONS]
Options:
--input TEXT input png
--output-base TEXT base name of output pngs
--alpha-threshold INTEGER on/off threshold for alpha
--num-colors TEXT use to set number of output colors
--base-white should all color be underlaid with white?
--near-pixel-threshold INTEGER tolerance for nearest-color computation
--help Show this message and exit.
$
```
Metadata
Release files for colorsep 0.0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| colorsep-0.0.3.tar.gz | 5.3 kB | Without provenance | Details for colorsep-0.0.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| colorsep-0.0.3-py3-none-any.whl | Python 3 | none | any | Details for colorsep-0.0.3-py3-none-any.whl |
Total release size: 11.1 kB
Release files / colorsep-0.0.3.tar.gz
| Download URL | colorsep-0.0.3.tar.gz |
|---|---|
| Size | 5.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c78071393343f19764f88746bf6c41a3cd3fe7e8d422717a88a0deaa966ef02d
|
|
BLAKE2b-256 checksum How to use checksums |
f0c3984028809c56855e352dd2cfdd76d2ee8c06274f7d30ff9b6d8b4fffa48e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.6
|
Release files / colorsep-0.0.3-py3-none-any.whl
| Download URL | colorsep-0.0.3-py3-none-any.whl |
|---|---|
| Size | 5.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9cac4cf271ada63a18fb12c83e331c864eae78611afc299fe02000a5985c0343
|
|
BLAKE2b-256 checksum How to use checksums |
112016e21280e4501bea376d94eabf742d3fc127542ec9b2bf9cf0f6f8a05c08
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.6
|
Security for colorsep 0.0.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.