-
-
Notifications
You must be signed in to change notification settings - Fork 814
Fix the Bevel node so it applies a consistent bevel size regardless of angle #2293
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
Conversation
Thanks!
Based on this sentence, do I presume correctly that this means curved segments are left for future work? |
Yes, currently it only work for straight line only, I'll try to make it work for curve line also. |
!build |
|
This doesn't seem to have the expected behavior after passing a certain size, see video: capture_33_.mp4Could that be fixed, please? |
I attempted to resolve the algorithm. Is this the expected behavior? Screen.Recording.2025-02-20.212534.mp4 |
!build |
|
capture_34_.mp4 |
!build |
|
Screen.Recording.2025-03-15.144906.mp4Fixes the curve part |
!build |
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this contribution; however it does not work if the layer has a transform applied to it.
c7488cf
to
1875779
Compare
!build |
|
Adding bevel to the following layer crashes the node (paste this into a document then add a Bevel node):
This is a path manually constructed to represent these points from the
Please fix the edge case covered by the crash (I presume it's the case where there's a zero-length segment connected between two other segments). And then please also fix the four test cases which are failing, either due to flaws in the algorithm (which should be fixed) or outdated expected cases in the test output calculations (which should be updated within the tests). Please take care to analyze which case is which while solving these. Thanks! The behavior is looking really nice to use now, so I look forward to getting this merged. |
ec51271
to
e025103
Compare
…f angle (GraphiteEditor#2293) * feat: update the bevel algorithm for same bevel length * Fix: Resolves issue in bevel algorithm * fix bevel algorithm * Feat : update the bevel algorithm for bezier curve * Feat: Add support for rounded and inward-rounded Bevel options * fix bevel algo for curves * Nits * refactor area node * refactor close path node * small refactor of 'check_point_inside_shape' method * copy is_linear function from bezier-rs lib * refactor bevel node implementation * cleanup * refactor bevel implementation * fix transformation * cleanup * update the bevel algorithm * Code review * Clean up setup logic for failing test * update tests to reflect new algorithm * Decimal integer nits --------- Co-authored-by: Keavon Chambers <keavon@keavon.com> Co-authored-by: indierusty <indierusty@gmail.com>
Previously algorithm only spilt the line from both side with the give length.
Update the bevel algorithm for straight line only to give same bevel length.
Closes #2281