mirror of
https://github.com/JustinSDK/dotSCAD.git
synced 2025-08-20 05:21:38 +02:00
rename
This commit is contained in:
@@ -2,7 +2,7 @@ use <hull_polyline3d.scad>;
|
||||
use <rotate_p.scad>;
|
||||
use <square_maze.scad>;
|
||||
use <matrix/m_rotation.scad>;
|
||||
use <experimental/pt2sphere.scad>;
|
||||
use <experimental/tf_sphere.scad>;
|
||||
|
||||
r = 10;
|
||||
rows = 24;
|
||||
@@ -26,7 +26,7 @@ module sphere_maze() {
|
||||
for(wall_pts = walls) {
|
||||
rxpts = [
|
||||
for(p = wall_pts)
|
||||
pt2sphere(size, mr * [p[0], p[1], 0, 0] + p_offset, r)
|
||||
tf_sphere(size, mr * [p[0], p[1], 0, 0] + p_offset, r)
|
||||
];
|
||||
hull_polyline3d(rxpts, wall_thickness, $fn = 6);
|
||||
}
|
||||
|
@@ -1,5 +1,5 @@
|
||||
use <pixel/px_gray.scad>;
|
||||
use <experimental/pt2sphere.scad>;
|
||||
use <experimental/tf_sphere.scad>;
|
||||
|
||||
photo_size = [100, 100];
|
||||
levels = [
|
||||
@@ -110,14 +110,14 @@ dots = px_gray(levels, center = true, normalize = true);
|
||||
|
||||
color("white")
|
||||
for(dot = dots) {
|
||||
translate(pt2sphere(photo_size, dot[0] + [50, 50], 50, [180, 180]))
|
||||
translate(tf_sphere(photo_size, dot[0] + [50, 50], 50, [180, 180]))
|
||||
square(dot[1] * 2.5);
|
||||
}
|
||||
|
||||
rotate([180, 0, 0])
|
||||
color("white")
|
||||
for(dot = dots) {
|
||||
translate(pt2sphere(photo_size, dot[0] + [50, 50], 50, [180, 180]))
|
||||
translate(tf_sphere(photo_size, dot[0] + [50, 50], 50, [180, 180]))
|
||||
square(dot[1] * 2.5);
|
||||
}
|
||||
|
||||
|
@@ -6,7 +6,7 @@ use <rotate_p.scad>;
|
||||
r: sphere radius.
|
||||
angle: [za, xa] mapping angles.
|
||||
*/
|
||||
function pt2sphere(size, p, r, angle = [180, 360]) =
|
||||
function tf_sphere(size, p, r, angle = [180, 360]) =
|
||||
let(
|
||||
x = p[0],
|
||||
y = p[1],
|
Reference in New Issue
Block a user