mirror of
https://github.com/JustinSDK/dotSCAD.git
synced 2025-08-20 05:21:38 +02:00
format
This commit is contained in:
@@ -20,11 +20,11 @@ module torus_knot_dragon_and_pearl() {
|
|||||||
|
|
||||||
knot = torus_knot(2, 3, phi_step);
|
knot = torus_knot(2, 3, phi_step);
|
||||||
d_path = reverse([for(i = [6:len(knot) - 4]) knot[i]]);
|
d_path = reverse([for(i = [6:len(knot) - 4]) knot[i]]);
|
||||||
|
|
||||||
one_body_scale_data = one_body_scale(body_r, body_fn, scale_fn, scale_tilt_a);
|
one_body_scale_data = one_body_scale(body_r, body_fn, scale_fn, scale_tilt_a);
|
||||||
along_with(d_path, scale = 0.85, method = "EULER_ANGLE")
|
along_with(d_path, scale = 0.85, method = "EULER_ANGLE")
|
||||||
scale(0.06)
|
scale(0.06)
|
||||||
one_segment(body_r, body_fn, one_body_scale_data);
|
one_segment(body_r, body_fn, one_body_scale_data);
|
||||||
|
|
||||||
function __angy_angz(p1, p2) =
|
function __angy_angz(p1, p2) =
|
||||||
let(
|
let(
|
||||||
@@ -34,21 +34,21 @@ module torus_knot_dragon_and_pearl() {
|
|||||||
ya = atan2(dz, sqrt(dx * dx + dy * dy)),
|
ya = atan2(dz, sqrt(dx * dx + dy * dy)),
|
||||||
za = atan2(dy, dx)
|
za = atan2(dy, dx)
|
||||||
) [ya, za];
|
) [ya, za];
|
||||||
|
|
||||||
h_angy_angz = __angy_angz(d_path[len(d_path) - 2], d_path[len(d_path) - 1]);
|
h_angy_angz = __angy_angz(d_path[len(d_path) - 2], d_path[len(d_path) - 1]);
|
||||||
|
|
||||||
translate([2.5, -1.1, .55])
|
translate([2.5, -1.1, .55])
|
||||||
scale(0.07)
|
scale(0.07)
|
||||||
rotate([0, h_angy_angz[0] + 28, h_angy_angz[1] + 245])
|
rotate([0, h_angy_angz[0] + 28, h_angy_angz[1] + 245])
|
||||||
dragon_head();
|
dragon_head();
|
||||||
|
|
||||||
t_angy_angz = __angy_angz(d_path[1], d_path[0]);
|
t_angy_angz = __angy_angz(d_path[1], d_path[0]);
|
||||||
|
|
||||||
translate([2.1, 1.55, -.80])
|
translate([2.1, 1.55, -.80])
|
||||||
rotate([0, t_angy_angz[0], t_angy_angz[1]])
|
rotate([0, t_angy_angz[0], t_angy_angz[1]])
|
||||||
rotate([0, -95, -75])
|
rotate([0, -95, -75])
|
||||||
scale([0.055, 0.055, 0.065])
|
scale([0.055, 0.055, 0.065])
|
||||||
tail();
|
tail();
|
||||||
|
|
||||||
// pearl
|
// pearl
|
||||||
polyhedron_hull(fibonacci_lattice(66, .5));
|
polyhedron_hull(fibonacci_lattice(66, .5));
|
||||||
|
Reference in New Issue
Block a user