jcoehoorn / BrickMaker

Generate STL 3D model files for Lego-like bricks that can be 3D printed
1 stars 0 forks source link

Customizer renders skinny studs #1

Closed jcoehoorn closed 5 years ago

jcoehoorn commented 5 years ago

ThingiVerse Customizer is rendering studs different than OpenSCAD.

The code below somehow produces a stud with a 2 mm diameter in the customizer and 4.825 mm in OpenSCAD.

LU = 1.6; 
stud_radius_adjustment = -.02;
base_stud_height = 1.8;
stud_height_adjustment = .1;

stud_height = base_stud_height - stud_height_adjustment;
stud_rad = (1.5*LU) - stud_radius_adjustment;

cylinder(stud_height,stud_rad, stud_rad, $fn=40);
jcoehoorn commented 5 years ago

Turns out Customizer wants floats with an absolute value < 1 to have leading zeros. Fix is in.