Any help to code this example (attached)

Hey everybody,

I’m learning digital tools. I would love to learn how to make this code made by # Simon Pähler, if you have any recommendations or you can tell me something that I can search I will be really helpfull.

Code by Simon Pahler

I’ve tried to contact him with no chance so far.
Thanks in advance!!!

1 Like

I have no idea

You can look at the examples where they talk about springs and stuff.

It’s hard to tell what we are actually seeing here.

From my understanding it’s 2D and not 3D.

Then the circles move. Question is do they move on it’s own or is each circle moving because it’s drawn by a connection to other circles near by?

To start off, I would assume the first. Then you could store the points of the circumference of each circle and make the circle move back and forth.

Then check these 360 points against the points of another circle near by and when they are close/ below a threshold connect them

1 Like

Hello @dovkev,

I managed to do this:

  • Created arrays of PVectors to store data
  • Rotated a PVector and stored the data so I had points around a circle
  • Joined the points from array1\circle1 with a line to array2\circle2
  • Added some transparency to color
  • Added some simple sinusoidal motion to the circles; cosinusoidal if you prefer
  • Experimenting with blendMode(); using ADD for now.
  • It’s a start…

Static image:

They do move around nicely and look better in my sketch.

:slight_smile:

2 Likes

When the distance is too big, you don’t draw

You could set fill in in a way that the transparency is proportional to the distance (see dist() command).

Also when you say background (0,10); the lines would fade away slowly

1 Like