-
-
Notifications
You must be signed in to change notification settings - Fork 115
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
Rotating a cylinder causes 3MF validation error #494
Labels
topic: core
Issues relating to core geometry, operations, algorithms
topic: export
Exporting to external file formats
type: bug
Something isn't working
Comments
hannobraun
added
type: bug
Something isn't working
topic: core
Issues relating to core geometry, operations, algorithms
topic: export
Exporting to external file formats
labels
Apr 22, 2022
I can still reproduce this, although the original code no longer compiles. Here's the updated code: use std::f64::consts::FRAC_PI_4;
use fj::{syntax::*, Angle};
#[fj::model]
pub fn model() -> fj::Shape {
let cylinder = fj::Sketch::from_circle(fj::Circle::from_radius(0.5))
.sweep([0., 0., 1.])
.rotate([1., 1., 1.], Angle::from_rad(FRAC_PI_4))
.translate([4., 1., 1.]);
cylinder.into()
} This trips our own validation code now:
I've done some additional digging. This is the curve where Curve {
path: Line(
Line {
origin: [
0.0,
0.0,
],
direction: [
1.0,
0.0,
],
},
),
surface: Surface @ 0x557f15d2bee0,
global_form: GlobalCurve @ 0x557f15d0ffa0,
} And the curve where Curve {
path: Circle(
Circle {
center: [
0.0,
0.0,
],
a: [
0.5,
0.0,
],
b: [
0.0,
0.5,
],
},
),
surface: Surface @ 0x557f15d2c970,
global_form: GlobalCurve @ 0x557f15d0ffb0,
} They reference different |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
topic: core
Issues relating to core geometry, operations, algorithms
topic: export
Exporting to external file formats
type: bug
Something isn't working
Rotating cylinders is possible as of #493. However, it produces an invalid 3MF file.
Here's the code of a model that displays the issue:
And here's the error:
I wasn't able to see any obvious issues, so it must be something subtle. Probably a triangulation edge case, or possible it's related to the use of triangle representation for the cylinder side walls (#97).
The text was updated successfully, but these errors were encountered: