Skip to content

This code generates an image with three horizontal lines of varying lengths (10px, 100px, and 1000px) on a white background. The lines are rendered with a bright cyan color, and the image dimensions are calculated to include a 500px margin on all sides (top, bottom, left, and right).

Notifications You must be signed in to change notification settings

mankin3n/imageWithLinesGenerator

Repository files navigation

Line Drawing Project

This project is designed to generate an image with three distinct horizontal lines of varying lengths (10px, 100px, and 1000px) on a white background. Each line is accompanied by a label indicating its length.

Features

Generates a .png image with three lines. Lines are labeled with their respective lengths. Image includes a 500px margin on all sides. Lines are rendered in bright cyan color for clarity.

Setup and Installation

Clone the repository:

git clone https://github.com/mankin3n/imageWithLinesGenerator/ Navigate to the project directory:

cd https://github.com/mankin3n/imageWithLinesGenerator/ Install dependencies using Yarn:

yarn install

Usage

Run the script using:

yarn start After execution, you'll find the generated image named output.png in the project directory.

Dependencies

canvas: A powerful drawing library to create the image output.

About

This code generates an image with three horizontal lines of varying lengths (10px, 100px, and 1000px) on a white background. The lines are rendered with a bright cyan color, and the image dimensions are calculated to include a 500px margin on all sides (top, bottom, left, and right).

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published