Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed several issues with drawing ellipses #3776

Merged
merged 1 commit into from
Jul 6, 2023

Conversation

bjorn
Copy link
Member

@bjorn bjorn commented Jul 5, 2023

I've replaced the ellipse drawing algorithms with implementations by Zingl Alois, originally written in 2012 and published under MIT license.

This addresses several issues with the previously used implementations of pointsOnEllipse and ellipseRegion:

  • Ellipses no longer degrade when very large (near 2000 tiles in size).

  • No more gaps in the ellipse for some sizes.

  • Shape Fill tool can now actually draw circles of equal width and height and can draw both even and odd sized ellipses.

The Shape Fill tool was adjusted such that drawing ellipses work in bounding-box mode by default. The Alt modifier now toggles to center + radius mode, which also applies when drawing rectangles.

Closes #3775

I've replaced the ellipse drawing algorithms with implementations by
Zingl Alois, originally written in 2012 and published under MIT license.

This addresses several issues with the previously used implementations
of pointsOnEllipse and ellipseRegion:

* Ellipses no longer degrade when very large (near 2000 tiles in size).

* No more gaps in the circle for some sizes.

* Shape Fill tool can now actually draw circles of equal width and
  height and can draw both even and odd sized ellipses.

The Shape Fill tool was adjusted such that drawing ellipses work in
bounding-box mode by default. The Alt modifier now toggles to center +
radius mode, which also applies when drawing rectangles.

Closes mapeditor#3775
@bjorn bjorn merged commit d691d52 into mapeditor:master Jul 6, 2023
12 checks passed
@bjorn bjorn deleted the better-ellipses branch July 6, 2023 08:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Ellipse Shape Fill improvements
1 participant