Img2ascii
🏞️ A command-line tool for converting images to ASCII art
Install / Use
/learn @JosefVesely/Img2asciiREADME
<img src="img2ascii.png">
A command-line tool for converting images to ASCII art
</div>🛠️ Installation
# Clone the repository
git clone https://github.com/JosefVesely/img2ascii
# Navigate to the project directory
cd img2ascii
# Compile the program
make
🚀 Usage
Run using the following syntax:
img2ascii [options] -i <FILE> [-o <FILE>]
Options:
| Short | Long | Parameter | Description | |-------|-----------|-----------|-----------------------------------------------| | -i | --input | File | Path of the input image file (required) | | -o | --output | File | Path of the output file | | -w | --width | Number | Width of the output image | | -c | --chars | String | Characters to be used for the ASCII image | | -p | --print | | Print the output to the console | | -r | --reverse | | Reverse the string of characters |
🧩 Examples
| Input | Output |
|--------------------------------------------------|--------------------------------------------------|
| <img src="images/c.png" width="300"> | <img src="examples/ascii-c.png" width="500"> |
| img2ascii -i images/c.png -w 40 -p | |
| <img src="images/monroe.jpg" width="300"> | <img src="examples/ascii-monroe.png" width="500"> |
| img2ascii -i images/monroe.jpg -w 35 -p -r | |
| <img src="images/pink_floyd.jpg" width="300"> | <img src="examples/ascii-pink_floyd.png" width="500"> |
| img2ascii -i images/pink_floyd.jpg -w 80 -p -r | |
| <img src="images/pepsi.png" width="300"> | <img src="examples/ascii-pepsi.png" width="500"> |
| img2ascii -i images/pepsi.png -w 35 -p -r | |
| <img src="images/aperture.jpg" width="300"> | <img src="examples/ascii-aperture.png" width="500"> |
| img2ascii -i images/aperture.jpg -w 50 -p | |
🧪 Compatibility
The supported image file formats are PNG, JPEG and BMP
This program has been tested and works on the following operating systems:
- Windows 11
- Linux Mint 22
🤝 Contributing
Contributions are welcome! Feel free to open an issue or submit a pull request
📜 License
This project is licensed under the MIT License
Related Skills
node-connect
348.5kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
109.1kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
348.5kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
348.5kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
