Skip to content

achnitreda/Jart

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

4 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Jart - Java Geometric Art Generator

A Java library for programmatically creating images composed of various geometrical shapes. Generate beautiful artwork using points, lines, circles, rectangles, and triangles with automatic random coloring.

🎨 Features

  • Multiple Shape Types: Points, Lines, Circles, Rectangles, Triangles
  • Automatic Random Colors: Each shape gets a unique random color
  • High-Quality Rendering: Uses Bresenham's line algorithm for crisp, pixel-perfect lines
  • Flexible API: Object-oriented design with interfaces for extensibility
  • Image Export: Save your creations as PNG files
  • Random Generators: Built-in methods to create random shapes within specified bounds

πŸ“ Project Structure

jart/
β”œβ”€β”€ geometrical_shapes/
β”‚   β”œβ”€β”€ Displayable.java      # Interface for drawable surfaces
β”‚   β”œβ”€β”€ Drawable.java         # Interface for drawable shapes
β”‚   β”œβ”€β”€ Image.java           # Canvas implementation
β”‚   β”œβ”€β”€ Point.java           # Point shape
β”‚   β”œβ”€β”€ Line.java            # Line shape using Bresenham's algorithm
β”‚   β”œβ”€β”€ Circle.java          # Circle shape
β”‚   β”œβ”€β”€ Rectangle.java       # Rectangle shape
β”‚   └── Triangle.java        # Triangle shape
β”œβ”€β”€ Main.java                # Example usage
β”œβ”€β”€ README.md               # This file
└── .gitignore              # Git ignore rules

πŸš€ Quick Start

Prerequisites

  • Java 17 or higher
  • Any Java IDE or command line tools

Compilation & Running

# Compile the project
javac -d build Main.java

# Run the example
java -cp build Main

# View the generated image
# Opens image.png in your default image viewer

About

generates an image composed of various geometrical shapes

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages