- Open terminal and locate folder to copy to
git clone https://github.com/kailau02/ascii-transformer.git
conda create --name ./env --file requirements.txt
- Open terminal and locate folder to copy to
git clone https://github.com/kailau02/ascii-transformer.git
pip3 install opencv-python numpy pillow
In main.py
, you must instantiate the ASCIITransformer
class-object and then you can call methods to transform images and videos to ASCII representations
- The webcam mode loads by default from
main.py
by writing in terminalpython3 main.py
- Make sure to allow the program access to your webcam to run
- The script may need to be ran twice before working properly
- While the program is running, you can set the ascii density/quality by clicking
1
2
and3
on your keyboard
Call the video capture method using obj.transform_to_video()
- Open an existing image on object instantiation like:
obj = ASCIITransformer(fname="image.jpeg")
- Or, open an image directly from the object like:
obj.open(fname="image.jpeg")
- Convert the image to an ASCII image like:
obj.transform_to_img(fname="resulting-image.png")
- Open an existing image on object instantiation like:
obj = ASCIITransformer(fname="image.jpeg")
- Or, open an image directly from the object like:
obj.open(fname="image.jpeg")
- Convert the image to an ASCII text file like:
obj.transform_to_txt(fname="resulting-text.txt")