ACIIFY is a tool used to convert images into ASCII art and print them onto the console.
Input Formats currently Supported:
- PNG
- JPEG
- Install
go
. Installation instructions for it are here - Fork the Repository.
- Clone the repository in your local environment.
- Go to the directory and run
go build ./main.go
- Then, run
go run ./main.go -f ./data/golang.png -r 0.1 -c
usage: TODO
options:
-help
show this help message and exit
-c Display ASCII art in color
-f string
Image Path to Convert
-p Display Pixelated art
-r float
Ratio to Scale the given Image (default 1)
Specify path to file (jpeg, png) you want to convert into ASCII art.
go run ./main.go -f ./data/<image>
NOTE:./data/ is the folder within the project folder you can add images there or change that as well refer Example 2
Example:
go run ./main.go -f ./data/gradient.png
Example 2 Another folder from your pc:
go run ./main.go -f ./hacktober/2022 Hacktoberfest Event Kit/Email Banners
NOTE: Most of the time, running without ratio results in very large ASCII arts. So, always try with
-r 0.1
flag.
Ratio to Scale the given Image into
go run ./main.go -f ./data/<image> -r <ratio to scale into>
Example:
go run ./main.go -f ./data/golang.png -r 0.1
This option is used to display the ASCII art in color (256).
go run ./main.go -f ./data/<image> -c
Example:
go run ./main.go -f ./data/golang.png -r 0.1 -c
This option is used to display Pixelated art of the given image.
go run ./main.go -f ./data/<image> -p
To print colored Pixelated art, use -c
with -p
.
go run ./main.go -f ./data/<image> -r 0.1 -p -c
Example:
go run ./main.go -f ./data/gradient.png -r 0.1 -c -p
Image | ASCII Art |
---|---|
You can fork the project and implement the changes you want for a pull request.
Contributions are Welcome! :)