add some models

This commit is contained in:
Robin Appelman 2025-12-12 17:43:23 +01:00
commit 5c5b0b3768
2 changed files with 264 additions and 0 deletions

View file

@ -0,0 +1,22 @@
use std::ops::*;
use std::math::*;
use std::geo3d::*;
use gridfinity::*;
mod gridfinity;
fn getOffset(units: Integer) -> Length {
if units > 1 {
return 5.1mm;
} else {
return 3.2mm;
}
}
part Holder(diameter: Length) {
units = int(diameter / BasicUnitXY) + 1;
Box(gridsX = units, gridsY = units, gridsZ = 4, magents = true) - Cylinder(radius = diameter / 2, height = 100mm, offset = getOffset(units));
}
#[resolution = 200%]
Holder(60.5mm);