asciifite 🎨
asciifite is a high-performance Python library for converting images and videos into colorful ASCII art and generating creative text banners for CLI applications.
By leveraging NumPy vectorized operations, this library ensures that frame-by-frame conversion is significantly faster than standard Python loops.
🚀 Features
- Video-to-ASCII: Convert standard video files (.mp4, .avi, etc.) into colorful ASCII-style videos.
- Image-to-ASCII: Transform any digital image into a detailed, textured ASCII rendering.
- Creative Banners: Generate stylized, framed text banners using multiple "brush" styles (solid, thin, dotted).
- Aspect Correction: Automatically adjusts character density to maintain the original visual proportions.
📦 Installation
Ensure you have Python installed, then navigate to the project root folder and install via pip:
pip install .
🛠 Dependencies
The library relies on the following industry-standard packages:
- opencv-python: For media decoding and rendering.
- numpy: For high-speed image matrix processing.
📖 Usage Guide & Examples
1. Generating Creative Banners
Use the BannerGenerator class to create stylized headers.
from asciifite import BannerGenerator
bg = BannerGenerator()
banner = bg.generate("ABC", style="solid", frame=True)
print(banner)
2. Converting Videos to ASCII
The process_video function handles reading frames, conversion, and writing the final video.
from asciifite import process_video
process_video(
input_path="input.mp4",
output_path="output.mp4",
width=120,
cell_size=8
)
3. Converting Images
Turn any photo into an ASCII masterpiece with process_image.
from asciifite import process_image
process_image(
input_path="photo.jpg",
output_path="ascii.jpg",
width=150,
cell_size=10
)
⚙️ Configuration Options
- width: Number of ASCII characters across the output.
- cell_size: The pixel dimensions of each character block.
- charset: Choose between 'standard', 'complex', or 'blocks'.
📂 Project Structure
asciifite_project/
├── asciifite/
│ ├── __init__.py
│ ├── core.py
│ └── io.py
├── setup.py
└── README.md
Metadata
Release files for asciifite 0.1.0
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 |
|---|---|---|---|---|
| asciifite-0.1.0.tar.gz | 16.6 kB | Without provenance | Details for asciifite-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| asciifite-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for asciifite-0.1.0-py3-none-any.whl |
Total release size: 33.5 kB
Release files / asciifite-0.1.0.tar.gz
| Download URL | asciifite-0.1.0.tar.gz |
|---|---|
| Size | 16.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b992731f242edb4e4c7c1f77ce31c2efe2c9027a4747ef6a6baea2186bed14e1
|
|
BLAKE2b-256 checksum How to use checksums |
02460a32e7e8d16b208a6df47d6e67ab5b1f19b63db73c34c41062c5776aef11
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.3
|
Release files / asciifite-0.1.0-py3-none-any.whl
| Download URL | asciifite-0.1.0-py3-none-any.whl |
|---|---|
| Size | 16.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6f43bd7b88d8a0d8d7a0a12ea65b4d10dabe403ddefcd76c814bace8cc2f8911
|
|
BLAKE2b-256 checksum How to use checksums |
a52d7ebd9535fa2030eb84f4a4f6a654cb20bea5876d2648ff9a00e5750fe99f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.3
|
Security for asciifite 0.1.0
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.