Skip to content

Small Vector Drawing App, which allows to draw efficient Graphics.

License

Notifications You must be signed in to change notification settings

NoahMeissner/Vector-Image-Drawing-App

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Vector Image Drawing App

Easily draw Bézier curves, lines, and polygons using an intuitive user interface. Save and open your work seamlessly, allowing for quick adjustments and refinements.

All functions are custom-implemented, leveraging the power of the NumPy and Tkinter libraries for efficient and interactive graphic creation.

Video_Usage_Drawing.mp4

Implemenation Details

Bresenham's Algorithm:

  • Used to draw lines by setting individual pixels in a straight path between two points with integer coordinates.
  • This algorithm ensures efficient and accurate rendering of lines, avoiding floating-point arithmetic.

De Casteljau's Algorithm:

  • Employed to create segments of Bézier curves, which are used for smooth and scalable curve generation.
  • This recursive algorithm constructs Bézier curves by iteratively subdividing control points.

Flood Fill Algorithm:

  • Applied to fill polygons or areas with a specified color by setting each pixel inside the boundary.
  • This algorithm is commonly used in paint programs and for boundary-defined color filling.

Tkinter for UI Elements:

  • Tkinter is utilized to create and manage various user interface elements such as buttons, labels, and canvases.
  • This Python library allows for the creation of interactive and graphical applications.

Tkinter create_rectangle for Pixel Manipulation:

  • Tkinter's create_rectangle method is used to set pixels individually to draw shapes and lines.
  • Unlike higher-level drawing functions like create_line, create_rectangle can be used to set each pixel's color manually.

NumPy for Pixel Matrices:

  • NumPy is used to store and manipulate pixel matrices efficiently.
  • This library provides a convenient and powerful way to handle large arrays of pixel data for image processing.

Control

  • Left Click: Draw Points
  • Press E: Switch to Edit Mode
  • Press X: Hide Control Points
  • Press C: Refresh Canvas

Usage:

Graphical Interface:

python3 main.py

Installation

pip install tkinter

pip install numpy

About

Small Vector Drawing App, which allows to draw efficient Graphics.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages