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

Support point and segment extrusion #1245

Merged
merged 4 commits into from
May 1, 2024
Merged

Support point and segment extrusion #1245

merged 4 commits into from
May 1, 2024

Conversation

pentacular
Copy link
Member

No description provided.

Copy link
Contributor

@BarbourSmith BarbourSmith left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking at bend made me think again about how to flatten out bent wood shapes and I did some research on how other CAD programs do it and it seems like for the most part they are doing a conversion to mesh and then flattening the mesh

@@ -13,7 +13,7 @@ See: [remesh](#https://raw.githubusercontent.com/jsxcad/JSxCAD/master/nb/api/rem
`;

Box(40, 1, 5)
.and(bend(20))
.And(y(20), bend(20))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does capital And do anything different?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The capital forms only use the input shape for context.

So this produces two versions of Box(40, 1, 5) -- one translated, and one bent.

The lowercase form would produce three versions -- the original, the translated, and the bent.

@@ -3,49 +3,128 @@
#include "demesh_util.h"
#include "point_util.h"

static int Bend(Geometry* geometry, double reference_radius) {
static int Bend(Geometry* geometry, double reference_radius,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does bend do again?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Applies a uniform curvature to the shape.

Effectively placing it along the perimeter of a circle of the given radius.

It's not quite what we generally want, though.

@pentacular pentacular merged commit 36f271b into master May 1, 2024
1 check passed
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.

None yet

2 participants