Skip to content

staszkiet/PolygonEditor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Project: Polygon and Curvilinear Polygon Editor

This project is a graphical editor focused on creating, editing, and managing single polygons or curvilinear polygons with detailed constraint-handling capabilities and Bezier segment support. The editor includes specific features for polygon manipulation and constraint-based editing.

Polygon Creation and Manipulation:

Supports one polygon per scene. Allows creation of new polygons, as well as deletion and modification of existing one.

Editing:

One can move vertices and control points of Bezier segments, add vertices along edges, and remove vertices. To modify an edge leftclick on it and the menu with options shows up. Move the entire polygon by dragging with the left mouse button.

Constraints for edges:

Constraints include horizontal/vertical edges or edges with a specified length. Users can set custom edge lengths via an edit window, with the current length as the default. Only one constraint per edge can be added, adjacent edges cannot both be horizontal or vertical. Adding or removing vertices along an edge removes existing constraints and updates adjacent edge types.

Bezier Segments

In the edge-editing window you can change the edge into a 3rd-degree Bezier segment. Apply continuity requirements at vertices adjacent to Bezier segments:
G0: Positional continuity.
G1: Tangent vector continuity.
C1: Full tangent vector continuity.

Drawing Algorithms:

Straight segment rendering supports both a library-based algorithm and a custom implementation of Bresenham's algorithm. Bezier segments are drawn with a fast, iterative algorithm.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages