-
Notifications
You must be signed in to change notification settings - Fork 267
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
[BUG] Narrow peaks can exceed plot area #347
Comments
Thank you for creating the issue! Could you share some minimal reproducible example code? That would help us debug. |
I have added a working, minimal example project, as well as updated the description with additional information and observations. |
This bug was caused by the default rasterizer plolygonize a path line with stroke width later than 1. When angle is too small, the polygon vertex might be very far away from the center line. In SVG rasterizer, this vertex will be dropped - but our rasterizer lack of this type of check. This change implemented the check, when distance between the line vertex the coresponding plolygon vertex on the outter side is larger than 2 times of the stroke width - Then we cap the polygon.
Hi there, I've pushed a fix. Could you please confirm this is fixed. Thanks! Feel free to reopen it if the fix doesn't work. |
Thank you for your work! I can confirm that the issue is fixed. |
Describe the bug
The line drawing seems to have an overshoot issue for very narrow peaks. These overshoots can reach beyond the drawing area.
Some examples of the observed behavior:
To Reproduce
Plot data with very narrow peaks that exceed the plot area. The peaks have to be steep enough that they are but a pixel wide or so when rendered. The attached code example includes data that illustrates these issues.
Version Information
plotters: git version
fltk: 1.3.6
plotters_doodle.zip
The text was updated successfully, but these errors were encountered: