项目作者: R4yGM

项目描述 :
translate images, videos and text to Ascii arts easy
高级语言: Python
项目地址: git://github.com/R4yGM/AsciiPy.git
创建时间: 2019-09-12T16:00:54Z
项目社区:https://github.com/R4yGM/AsciiPy

开源协议:

下载


AsciiPy

translate images, videos and text to Ascii arts easy

translate text to asciiart with 400+ different fonts and images, videos from any path or url!

Install

to install you have to clone the repository

  1. $ git clone https://github.com/R4yGM/AsciiPy

Depencies

this tool has dependency, and to install them you have to run

  1. $ pip install -r requirements.txt

Asciify in your python script

to start asciifying in your script you have to import the module

  1. import AsciiPy

Asciify a text in python script

after you have imported the module type:

  1. text = AsciiPy.AsciiText.GenerateText(TEXT, FONT")
  2. text = AsciiPy.AsciiText.GenerateText("Hey", "graffiti")
  3. print(text)

to asciify a text

Asciify a image from url in your python script

after you have imported the module type:

  1. img = AsciiPy.AsciiImage.GenerateFromUrl("https://r4yan.ga/images-videos/python-logo.png")
  2. print(img)

to asciify a image by url

Asciify a image from path in your python script

after you have imported the module type:

  1. img = AsciiPy.AsciiImage.GenerateFromPath("python-logo.png")
  2. print(img)

to asciify a image by url

Asciify a video from path in your python script

after you have imported the module type:

  1. AsciiPy.AsciiImage.VideoFromPath("images-videos/cube.mp4")
  2. #this will automatically prints the video

to asciify a video by path

Asciify a video from url in your python script

after you have imported the module type:

  1. AsciiPy.AsciiImage.VideoFromUrl("https://r4yan.ga/images-videos/cube.mp4")
  2. #this will automatically prints the video

to asciify a video by url

Get list of fonts in python script

after you have imported the module type:

  1. lst = AsciiPy.AsciiText.FontList()
  2. print(lst)

this will print ove 400 different fonts you can use to generate texts

Asciify in Terminal

Asciify a image from url

to asciify a image you have to run

  1. $ py AsciiPy -u [url for your image]

example

  1. $ py AsciiPy -u https://r4yan.ga/images-videos/python-logo.png

Asciify a image from path

to asciify a image from path you have to run

  1. $ py AsciiPy -p [path for your image]

Asciify a text

  1. $ py AsciiPy -t [text] [font]

if you need a font list just type

  1. $ py AsciiPy -f

Asciify a Video from path

  1. $ py AsciiPy -vid-path [path to video]

Asciify a Video from url

  1. $ py AsciiPy -vid-url [url to video]

help

  1. $ py AsciiPy -h

this prints a list of commands with examples

still in development