mirror of
https://github.com/JustinSDK/dotSCAD.git
synced 2025-08-15 11:14:17 +02:00
update demo
This commit is contained in:
@@ -3,22 +3,22 @@ use <experimental/pnoise2.scad>;
|
|||||||
use <experimental/pnoise3.scad>;
|
use <experimental/pnoise3.scad>;
|
||||||
|
|
||||||
module demo1() {
|
module demo1() {
|
||||||
|
for(z = [0:.2:5]) {
|
||||||
points = [
|
points = [
|
||||||
for(z = [0:.2:3])
|
|
||||||
for(y = [0:.2:5])
|
for(y = [0:.2:5])
|
||||||
for(x = [0:.2:5])
|
for(x = [0:.2:5])
|
||||||
[x, y, z]
|
[x, y, z]
|
||||||
];
|
];
|
||||||
noise = pnoise3(points);
|
noise = pnoise3(points, 3);
|
||||||
|
|
||||||
for(i = [0:len(points) - 1]) {
|
for(i = [0:len(points) - 1]) {
|
||||||
if(noise[i] > 0) {
|
if(noise[i] > 0) {
|
||||||
|
color([noise[i], .75, .75])
|
||||||
translate(points[i])
|
translate(points[i])
|
||||||
cube(.2);
|
cube(.2);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
module demo2() {
|
module demo2() {
|
||||||
points = [
|
points = [
|
||||||
|
Reference in New Issue
Block a user