Skip to content

Commit 9c7f7d2

Browse files
committed
More cells
1 parent dfbed9d commit 9c7f7d2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

contributed/worley_noise.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# The Coding Train / Daniel Shiffman
44
attr_reader :points
55

6-
NPOINTS = 20
6+
NPOINTS = 100
77

88
def settings
99
size(400, 400)
@@ -23,7 +23,7 @@ def draw
2323
z = frame_count % width
2424
distances << dist(x, y, z, v.x, v.y, v.z)
2525
end
26-
sorted = distances.sort!
26+
sorted = distances.sort
2727
r = map1d(sorted[0], 0..150, 0..255)
2828
g = map1d(sorted[1], 0..50, 255..0)
2929
b = map1d(sorted[2], 0..200, 255..0)

0 commit comments

Comments
 (0)