ASCII Art Generator is a Java-based application that converts text into ASCII art using a graphical user interface (GUI). The application leverages a predefined font table to generate ASCII art representations of characters.
- Text-to-ASCII Conversion: Enter any text, and the application will generate its ASCII art representation.
- Image-to-ASCII Conversion: Enter any image, and the application will do the same thing.
- Graphical User Interface: User-friendly GUI built with Java Swing.
- Custom Font Table: Supports a wide range of characters, including letters, numbers, and symbols.
-
Make the Build Script Executable (only required once):
- Run the following command to make the
build.sh
script executable:chmod +x build.sh
- Run the following command to make the
-
Run the Build Script:
- Use the provided
build.sh
script to compile the project, create the JAR file, and run the application. - Open a terminal and navigate to the project directory.
- Run the following command:
./build.sh
- Use the provided
-
Using the GUI:
- Enter text in the input field and click the "Translate" button to see the ASCII art in the output area.
If you prefer not to use the build.sh
script, you can manually build and run the application:
-
Compile the Project:
- Run the following command to compile the Java files:
javac -d build src/Main.java src/App/*.java
- Run the following command to compile the Java files:
-
Package the JAR File:
- Run the following command to create the JAR file:
jar cfm MyApp.jar manifest.mf -C build .
- Run the following command to create the JAR file:
-
Run the Application:
- Execute the JAR file using:
java -jar MyApp.jar
- Execute the JAR file using:
ASCII_artGenerator/
├── src/
│ ├── Main.java # Main entry point with GUI implementation
│ ├── App/
│ │ ├── FontTable.java # Contains the ASCII art font table
│ │ ├── TextTranslator.java # Handles text-to-ASCII conversion
│ │ ├── ImageTranslator.java # Handles image-to-ASCII conversion
│ │ └── Translator.java # Interface for translation logic
│ └── Client/
│ ├── TextClient.java # GUI for text-to-ASCII translation
│ └── ImageClient.java # GUI for image-to-ASCII translation
├── Build/ # Compiled classes and build artifacts
├── MyApp.jar # Prebuilt JAR file for running the application
├── manifest.mf # Manifest file for JAR packaging
├── build.sh # Build script for automating the process
├── README.md # Project documentation
- Java Development Kit (JDK) 8 or higher.
This project is licensed under the MIT License. See the LICENSE
file for details.
- ASCII art font inspired by various online resources.
- Built using Java Swing for the GUI.