We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5a8a183 commit bd9412dCopy full SHA for bd9412d
ascii_magic__examples/input.png
20.7 KB
ascii_magic__examples/print_ascii_string.py
@@ -0,0 +1,33 @@
1
+#!/usr/bin/env python3
2
+# -*- coding: utf-8 -*-
3
+
4
+__author__ = "ipetrash"
5
6
7
+# SOURCE: https://github.com/LeandroBarone/python-ascii_magic
8
9
10
+# pip install ascii-magic
11
+from ascii_magic import AsciiArt
12
13
14
+file_name = "input.png"
15
+my_art = AsciiArt.from_image(file_name)
16
+print(my_art.to_ascii(columns=40, monochrome=True))
17
+"""
18
19
+ ii
20
+ .]EE].
21
+ ;JXEEXJ;
22
+ iqX4444Xqi
23
+ `tXg444444gXt`
24
+ +CFLdg4444gdLFC+
25
+ xuv. >6gEEg6> .vnx
26
+ `au` :2442: `ua`
27
+ ^wXc+////[!^^![////+cXw^
28
+ %SX4d44444GLiiLG44444d4XS%
29
+ `tEg44EEEEEXn^::^nXEEEEE44gEt`
30
+ =fPEEEEEEEEd* *dEEEEEEEEPf=
31
+ i6dhhhhhhhhh6a*%ii%*a6hhhhhhhhhd6i
32
+ ^=^^^^^^^^^^=////////=^^^^^^^^^^=^
33
0 commit comments