Time/frame intervals in geometry nodes

Looking for a way to procedurally recreate this type of animation in GN. Now i ended up just manually placing keyframes with intervals, but it’s very tedious. Tried different math functions with scene time, like wrap and ping pong, but nothing really worked like i need. Will be greatful for any help )

@Finally_Free

Hi,

well that was an interesting challenge . . . :smile:

I should add, however, that the specific timing of the animation you’re trying to achieve is pure guess work on my behalf, but I took the view you wanted to create a more ‘deliberate’ movement, rather than just a pure continous rotating motion.

To achieve this you need to include a curve function in the timings/spacing values to bias the rotation/motion to be slower at the start and faster at the end of each ‘step’. The most obvious one is y=x^2. In my Geonodes there is an orange coloured group that contains this function. The complexity of the geo nodes in general is to do with the specific calculations of the rotations, the pivot point and the transform offsets. . .

I won’t even begin to explain how this entire thing works as you may already have figured out another solution. I came up with an alternative that used the Sin values, which produced a simpler GN setup, but lacked the crsip accuracy of this method…either way both graphs include the y=x^n function.

In the outliner, I’ve added three input variables that allow the cube/animation to be tweaked:

The cube size.

The degrees per frame [ how fast the cube rotates/moves. high values == faster]

Snap strength. This is a value between 0 and 4. and is the exponent [n] of the y=x^n function. A value of 0 will give the cube a linear rolling motion, a value of 4 a ‘laboured’ motion.

My file.

RollingCubes.blend (1.1 MB)

Hope something in there is of use to you.

Cheers,
Dj.