Fix pill-shaped screw hole CSG export issue
Add epsilon offsets to pill hole geometry to prevent coplanar face issues during STL/3MF export. F6 render was correct but mesh export was dropping the recesses due to CGAL handling of coincident surfaces. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
de88c8b794
commit
a243e9a1f9
@ -107,16 +107,18 @@ module paddle_opening_3d() {
|
|||||||
module screw_holes() {
|
module screw_holes() {
|
||||||
if (screw_holes_enabled) {
|
if (screw_holes_enabled) {
|
||||||
// Main screw holes: recessed from back face (positive Z), solid wall on front
|
// Main screw holes: recessed from back face (positive Z), solid wall on front
|
||||||
main_screw_start_z = plate_thickness - main_screw_recess_depth;
|
// Start slightly below target to ensure clean CSG intersection
|
||||||
|
main_screw_start_z = plate_thickness - main_screw_recess_depth - 0.01;
|
||||||
|
main_screw_cut_height = plate_thickness - main_screw_start_z + 0.1;
|
||||||
|
|
||||||
// Top main screw hole (pill-shaped, horizontal)
|
// Top main screw hole (pill-shaped, horizontal)
|
||||||
translate([0, screw_hole_spacing/2, main_screw_start_z])
|
translate([0, screw_hole_spacing/2, main_screw_start_z])
|
||||||
linear_extrude(height = main_screw_recess_depth + 0.1)
|
linear_extrude(height = main_screw_cut_height)
|
||||||
rect([screw_hole_width, screw_hole_height], rounding=screw_hole_height/2);
|
rect([screw_hole_width, screw_hole_height], rounding=screw_hole_height/2);
|
||||||
|
|
||||||
// Bottom main screw hole (pill-shaped, horizontal)
|
// Bottom main screw hole (pill-shaped, horizontal)
|
||||||
translate([0, -screw_hole_spacing/2, main_screw_start_z])
|
translate([0, -screw_hole_spacing/2, main_screw_start_z])
|
||||||
linear_extrude(height = main_screw_recess_depth + 0.1)
|
linear_extrude(height = main_screw_cut_height)
|
||||||
rect([screw_hole_width, screw_hole_height], rounding=screw_hole_height/2);
|
rect([screw_hole_width, screw_hole_height], rounding=screw_hole_height/2);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -101,16 +101,18 @@ module paddle_opening_3d() {
|
|||||||
module screw_holes() {
|
module screw_holes() {
|
||||||
if (screw_holes_enabled) {
|
if (screw_holes_enabled) {
|
||||||
// Main screw holes: recessed from back face (positive Z), solid wall on front
|
// Main screw holes: recessed from back face (positive Z), solid wall on front
|
||||||
main_screw_start_z = plate_thickness - main_screw_recess_depth;
|
// Start slightly below target to ensure clean CSG intersection
|
||||||
|
main_screw_start_z = plate_thickness - main_screw_recess_depth - 0.01;
|
||||||
|
main_screw_cut_height = plate_thickness - main_screw_start_z + 0.1;
|
||||||
|
|
||||||
// Top main screw hole (pill-shaped, horizontal)
|
// Top main screw hole (pill-shaped, horizontal)
|
||||||
translate([0, screw_hole_spacing/2, main_screw_start_z])
|
translate([0, screw_hole_spacing/2, main_screw_start_z])
|
||||||
linear_extrude(height = main_screw_recess_depth + 0.1)
|
linear_extrude(height = main_screw_cut_height)
|
||||||
rect([screw_hole_width, screw_hole_height], rounding=screw_hole_height/2);
|
rect([screw_hole_width, screw_hole_height], rounding=screw_hole_height/2);
|
||||||
|
|
||||||
// Bottom main screw hole (pill-shaped, horizontal)
|
// Bottom main screw hole (pill-shaped, horizontal)
|
||||||
translate([0, -screw_hole_spacing/2, main_screw_start_z])
|
translate([0, -screw_hole_spacing/2, main_screw_start_z])
|
||||||
linear_extrude(height = main_screw_recess_depth + 0.1)
|
linear_extrude(height = main_screw_cut_height)
|
||||||
rect([screw_hole_width, screw_hole_height], rounding=screw_hole_height/2);
|
rect([screw_hole_width, screw_hole_height], rounding=screw_hole_height/2);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user