User Tools

Site Tools


ascii_art

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
ascii_art [2023/03/24 10:53] frchrisascii_art [2023/03/24 11:04] – [Step 0. Choose an image] frchris
Line 34: Line 34:
 </code> </code>
 ==== Step 0. Choose an image ==== ==== Step 0. Choose an image ====
-==== Step 1. Read your image and print its height and width in pixels ==== 
  
 +Choose the first image that you want to convert into ASCII art. It’s good to start with an image around 640x480.  It can be in color, a photo, or a drawing.  Light pixels will be represented by small characters like a dot (.), which leave lots of the background exposed. On the other extreme, dense characters like $ are used to cover up the background.
 +==== Step 1. Read your image and print its height and width in pixels ====
 +==== Step 2. Load your image’s pixel data into a 2-dimensional array ====
 +==== Step 3. Convert the RGB tuples of your pixels into single brightness numbers  ====
 +==== Step 4. Convert brightness numbers to ASCII characters  ====
 +==== Step 5. What if it looks your image looks squashed? ====
  
  
 [[https://robertheaton.com/2018/06/12/programming-projects-for-advanced-beginners-ascii-art/|This is from RObert Heaton's Advanced Beginners Projects]] [[https://robertheaton.com/2018/06/12/programming-projects-for-advanced-beginners-ascii-art/|This is from RObert Heaton's Advanced Beginners Projects]]
ascii_art.txt · Last modified: 2023/03/27 10:46 by frchris

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki