Git Product home page Git Product logo

ascii-art's Introduction

ASCII Art Generator

Welcome to my ASCII Art Generator project! This repository contains code that allows you to transform images into captivating ASCII art. This project is based on the tutorial by Robert Heaton, which you can find here.

Project Overview

This project involves the following steps:

  1. Load Images: I use an image processing library to load images and access their pixel data.

  2. Convert to Brightness: I transform the RGB tuples of pixels into single brightness values.

  3. ASCII Transformation: I map the brightness values to ASCII characters, creating an ASCII representation of the image.

Getting Started

To run this project, follow these steps:

  1. Clone this repository:

    git clone https://github.com/joethesaint/ascii-art-generator.git
    
  2. Install the required library. For Python, you can use Pillow:

    pip install Pillow
    
  3. Place your image in the repository directory and update the image path in the code.

  4. Run the Python script:

    python ascii_art_generator.py
    

Code Structure

  • ascii_art_generator.py: The main script that performs image loading, brightness conversion, and ASCII transformation.

ASCII Character Mapping

In this project, I've used the following ASCII character set for mapping brightness to characters:

`^",:;Il!i~+_-?][}{1)(|\\/tfjrxnuvczXYUJCLQ0OZmwqpdbkhao*#MW&8%B@$

Results

Upon running the script, you'll see the ASCII representation of your image printed in the terminal. Experiment with different images and character sets to create unique ASCII art!

Acknowledgements

This project is based on Robert Heaton's tutorial on Programming Projects for Advanced Beginners: ASCII Art.

License

This project is licensed under the MIT License.

ascii-art's People

Contributors

joethesaint avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.