GuitarModels/2BangerCommon.scad

34 lines
889 B
OpenSCAD

include <AluTCommon.scad>
$fn = $preview ? 32 : 512;
mink_fn = $preview ? 12 : 128;
mink_fn_2d = $preview ? 32 : 256;
function tang_points(a0 = -160, a1 = -90, r = 13) =
concat(
[[r*cos(a1), r*sin(a0)]],
[for (a = [a0:a1]) [r*cos(a), r*sin(a)]]
);
module tang_block(a0 = -160, a1 = -90, r = 13)
translate(T_circumcenter)
polygon(tang_points(a0=a0, a1=a1, r=r));
module tang_outline(offset = -0.1, base_width = 1) {
difference() {
offset((base_width+offset)/2) tang_block();
offset(-(base_width+offset)/2) tang_block();
}
}
module tapered_tang_groove(depth, taper = 1, offset = 0.1, base_width = 1) {
difference() {
hull() {
linear_extrude(depth) offset((base_width+offset)/2) tang_block();
translate([0,0,depth]) linear_extrude(taper) offset(-(base_width)/2) tang_block();
}
linear_extrude(depth + taper) offset(-(base_width+offset)/2) tang_block();
}
}