Create the readme file yooooooo 🥰💙🦀

This commit is contained in:
Anas Elgarhy 2022-10-03 23:14:50 +02:00
parent 37e39e3c9d
commit e5651877a5
24 changed files with 213 additions and 0 deletions

193
README.md Normal file
View file

@ -0,0 +1,193 @@
# aarty: A simple CLI tool to convert the images to ASCII art with rust 🦀
![srceenshots/anime_2_colored_scale_4.gif](./srceenshots/anime_2_colored_scale_4.gif)
![money mouth face colored scale 2](./srceenshots/money_mouth_face_colored_scale_2.png)
![money mouth face normal scale 2](./srceenshots/money_mouth_face_normal_scale_2.png)
<details>
<summary>More screenshots</summary>
![crab colored scale 1](./srceenshots/crap_colored_scale_1.png)
[Original image](./images/crab.png)
![crap colored scale](./srceenshots/crap_colored_scale_2.png)
[Original image](./images/crab.png)
![nerd face colored scale](./srceenshots/nerd_face_colored_scale_2.png)
[Original image](./images/nerd_face.png)
![nerd face normal scale](./srceenshots/nerd_face_normal_scale_2.png)
[Original image](./images/nerd_face.png)
![srceenshots/anime_2_colored_scale_4.gif](./srceenshots/anime_2_colored_scale_4.gif)
[Original image](./images/anime_2.jpg)
![anime colored scale 3](./srceenshots/anime_colored_scale_3.gif)
[Original image](./images/anime.jpg)
</details>
```
~~~~~~~!!!!~!!~ ~!!!!!!!!!~~~~~
~~~~!!!!!!!!!!!!!!!! !!!!!!!!!!!!!!!!~~~~
~~~~~!!!!!!!!!!!!!!!!!!~ !!!!!!!!!!!!!!!!!!!!~~~~
~~~~~~!!!!!!!!!!!!!!!!!!!~ ~!!!!!!!!!!!!!!!!!!!!!!~~~~
~~~~~~~!!!!!!!!!!!!!!!!!!!!! !!!!!!!!!!!!!!!!!!!!!!!!~~~~~
~~~~~~~~!!!!!!!!!!!!!!!!!!!!!!~!!!!!!!!!!!!!!!!!!!!!!!!~~~~~
~~~~~~~~!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!~~~~~
~~~~~~~~!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!~~~~~
~~~~~~~~!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!~~~~~~
~~~~~~~~~!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!~~~~~~
~~~~~~~~~!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!~~~~~~~
~~~~~~~~~~!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!~~~~~~~
~~~~~~~~~~!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!~~~~~~~
~~~~~~~~~~~!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!~~~~~~~~
~~~~~~~~~~~~!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!~~~~~~~~~
~~~~~~~~~~~~!!!!!!!!!!!!!!!!!!!!!!!!!!~~~~~~~~~~~
~~~~~~~~~~~~~~~!!!!!!!!!!!!!!!!!!!~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~!!!~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~
~~~~~~~~~~
~~~~~
```
## Install
- from crates.io
```bash
crago install aarty
```
- From aur:
```shell
yay -S aarty
```
## Options and arguments
```bash
aarty --help
```
```
A simple CLI tool to convert the images to ASCII art
Usage: aarty [OPTIONS] <IMAGE>
Arguments:
<IMAGE>
The image to convert to ASCII art
Options:
-m, --mode <MODE>
The art mode to use
[default: normal-ascii]
Possible values:
- normal-ascii: Normal ASCII art
- colored: Colored ASCII art, the colors are based on the terminal colors
--output-method <OUTPUT_METHOD>
[default: stdout]
Possible values:
- file: Save the ascii art to a file
- stdout: Print the ascii art to the terminal
-c, --characters <CHARACTERS>
The character to use for drawing the image (lighter to darker) You can user one character if you uses the color mode
[default: " .,-~!;:=*&%$@#"]
-s, --scale <SCALE>
The output scale (1 is the original size)
[default: 4]
-b, --background <BACKGROUND>
The background color to use
-o, --output <OUTPUT>
The output file to write to (if output_method is file)
[default: ascii_image.txt]
-h, --help
Print help information (use `-h` for a summary)
-V, --version
Print version information
```
## Examples
```shell
aarty -m images/airplane.png
```
```
:=:**
=***:*
~~!!!~~~~~~~ ~~~ =*****=
~~~!!!!!!!!=*****=
~:*****=
:===**:!~
;======~!!~~
;:===:: ~!~
;:;~::: ~!!~~
~~!!;~~:; !!~
~~!!~ ~!~
~!~ !~
~~ ~~
```
```shell
aarty -m colored images/airplane.png
```
![airplane colored scale 4](./srceenshots/airplane_colored_scale_4.png)
```shell
aarty -m colored images/airplane.png -s 2
```
![airplane colored scale 2](./srceenshots/airplane_colored_scale_2.png)
```shell
aarty -c " ~okOK#\$%" images/ok_hand.png
```
```
$$$#
#$$$$#
K#KO#$$$$#
k###O#$$$$#
kK#OK$$$$#K
OKKO#$$$#
O#$$#O KKK$$$$#
K$$$$$$$$$$$$$#OOk#$$$#K
K$$$$$$$$$$$$$$$$##K#$$#K
#$K OO OK#$$$$$$$$$$###
#$$$$# OO##$$$$$$$$$#
O#$$$$# #$$$$$$$$$$KO
K#$$$$# K#$$$$$$$$$$KO
O#$$$$$$#KK####$$$$$$$$$##K
K#$$$$$$$$$$$$$$$$$$$$#KO
K##$$$$$$$$$$$$$$$$$##O
kK###$$$$$$$$$$$$###K
OK######$$######KO
OOKKKKKKKKOO
```
```shell
aarty -c " ~okOK#\$%" images/ok_hand.png -m colored
```
![ok hand colored scale 4 custome chars](./srceenshots/ok_hand_colored_scale_4_custome_chars.png)
```shell
aarty -c " ~okOK#\$%" images/ok_hand.png -m colored --output-method file -o ok_ascii.txt
```
![ok hand colored scale 4 custome chars in file](./srceenshots/ok_hand_colored_scale_4_custome_chars_in_file.png)
> If you get here, don't forget the star yooo ⭐
[![License MIT](https://img.shields.io/badge/license-MIT-green.svg)](https://spdx.org/licenses/MIT.html)

BIN
images/blue_heart.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2 KiB

BIN
images/ok_hand.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

BIN
images/red_heart.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

20
ok_ascii.txt Normal file
View file

@ -0,0 +1,20 @@
                                        
                     $$$#               
                     #$$$$#             
                  K#KO#$$$$#            
                  k###O#$$$$#           
                    kK#OK$$$$#K         
                      OKKO#$$$#         
              O#$$#O    KKK$$$$#        
         K$$$$$$$$$$$$$#OOk#$$$#K       
         K$$$$$$$$$$$$$$$$##K#$$#K      
       #$K OO     OK#$$$$$$$$$$###      
      #$$$$#         OO##$$$$$$$$$#     
      O#$$$$#          #$$$$$$$$$$KO    
       K#$$$$#       K#$$$$$$$$$$KO     
       O#$$$$$$#KK####$$$$$$$$$##K      
         K#$$$$$$$$$$$$$$$$$$$$#KO      
          K##$$$$$$$$$$$$$$$$$##O       
           kK###$$$$$$$$$$$$###K        
             OK######$$######KO         
                OOKKKKKKKKOO            

Binary file not shown.

After

Width:  |  Height:  |  Size: 49 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 50 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 83 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 56 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 43 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 92 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 104 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB