https://github.com/jdormit/txtpic
Generate Unicode art from images
https://github.com/jdormit/txtpic
ascii-art rust unicode-art
Last synced: about 1 year ago
JSON representation
Generate Unicode art from images
- Host: GitHub
- URL: https://github.com/jdormit/txtpic
- Owner: jdormit
- License: mit
- Created: 2017-03-28T06:56:49.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2017-04-06T21:56:04.000Z (about 9 years ago)
- Last Synced: 2025-03-18T05:11:51.833Z (about 1 year ago)
- Topics: ascii-art, rust, unicode-art
- Language: Rust
- Homepage:
- Size: 290 KB
- Stars: 23
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
# txtpic
> Generate Unicode art from images
## Installation
You'll need [Cargo](http://doc.crates.io) to install `txtpic`.
$ cargo install txtpic
## Usage
txtpic 1.2.4
Jeremy Dormitzer
Generates text representations of images
USAGE:
txtpic [FLAGS] [OPTIONS]
FLAGS:
-h, --help Prints help information
-i, --invert Invert the result to make it suitable for black text on a white background
-V, --version Prints version information
OPTIONS:
-c, --character-set An alternate character set to use
-p, --preset A preset character set to use [default: small] [values: small, medium, large, emoji]
-w, --width An approximate width value for the result [default: 80]
ARGS:
The input image
Note: the --width option attempts find a width close to the target width that preserves
the aspect ratio of the original image. For certain images, there may be only one or two
valid widths within a reasonable range, so the --width option may not appear to have an effect.
In this case, try extremely high or extremely low width values to affect the output.
## Example
Here is an adorable cat.

Converting it with:
$ txtpic --width 100 cat.jpg
Gives the [output](./example/cat.txt):
