How can one create a rope winding animation as shown here:


Source: https://vimeo.com/238181837


A helix is described using the parametric equation:

$$ \vec{r} = \begin{bmatrix} \alpha t \\ r\cos{t} \\ r\sin{t} \end{bmatrix} $$

Where $\alpha$ is some scalar controlling the "wavelength" of the helix and $r$ is the radius. Sampling some points and creating a spline from them, we get:

Node Tree 1

By driving the amount of samples based on time, we get:

Node Tree 2

We can see in the reference that the helix extends tangentially for some units. To compute the position of the point that creates that extension, we have to compute the tangent of the helix at the last point. So by differentiating the parametric equation we get:

$$ \vec{r}^{\, \prime} = \begin{bmatrix} \alpha \\ -r\sin{t} \\ r\cos{t} \end{bmatrix} $$

The position of the new point is the position of the last point plus a scalar multiple of the tangent at it. So the node tree becomes:

Node Tree 3

Where the index $-1$ gets us the last point. Note that instead of computing the tangent from scratch, we used the similarity between the function and its derivative to compute the tangent.

We notice that the spline intersects the cylinder, to fix that, we add the radius of the spline to the radius of the helix:

Node Tree 3

  • $\begingroup$ Omar Ahmad, thanks you very much, and thanks you fix my title. Thanks again. $\endgroup$
    – Ethan Liu
    Aug 24 '18 at 15:54
  • $\begingroup$ @EthanLiu Please accepts the answer if it answers your question. $\endgroup$
    – Omar Emara
    Aug 24 '18 at 16:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.