Jump to: Board index » General » Fusion

Rotating every frame a certain degree (Expression)

Learn about 3D compositing, animation, broadcast design and VFX workflows.
  • Author
  • Message
Offline

Sanse.

  • Posts: 6
  • Joined: Sun Feb 28, 2021 3:19 pm
  • Real Name: Sanse Azo

Rotating every frame a certain degree (Expression)

PostTue Jun 08, 2021 10:14 am

Hi it's me again,

Was wondering if I could rotate something via expression for example with a degree of 22,5 every frame so that it has the degree of 45 at the second frame.

I looked at the expression cheat sheet but couldn't figure something out

I guess you could somehow use "Keyframe stretcher" for that too in some way.

Can someone help?
Offline

Sander de Regt

  • Posts: 2260
  • Joined: Thu Nov 13, 2014 10:09 pm

Re: Rotating every frame a certain degree (Expression)

PostTue Jun 08, 2021 12:05 pm

Yes. Just create a simple expression on an angle control and enter

Code: Select all
time*22.5


And that's it.
Sander de Regt

ShadowMaker SdR
The Netherlands
Offline

Sanse.

  • Posts: 6
  • Joined: Sun Feb 28, 2021 3:19 pm
  • Real Name: Sanse Azo

Re: Rotating every frame a certain degree (Expression)

PostWed Jun 09, 2021 10:01 pm

Mh I tried that but it just speed up the whole thing instead of looking choppy/stop motion like.
Offline

David Ward

  • Posts: 12
  • Joined: Fri Oct 09, 2020 7:45 am
  • Real Name: David Ward

Re: Rotating every frame a certain degree (Expression)

PostWed Jun 09, 2021 10:18 pm

Bit unclear as to what you are trying to achieve. If you want a picture to rotate 22.5 degrees every frame it is going to perform a complete revolution in 16 frames and will look quite fast. What effect are you trying to achieve? Do you want it to snap to a degree of rotation and stop for a stop motion effect?
Offline

Sanse.

  • Posts: 6
  • Joined: Sun Feb 28, 2021 3:19 pm
  • Real Name: Sanse Azo

Re: Rotating every frame a certain degree (Expression)

PostMon Jun 14, 2021 1:10 am

Oh I see now, it has of course to stay on that degree for a while so it wouldn't be on every frame.
What I try to achieve is a choppy stop motion look instead of a smooth/fast rotation.
I'll try to figure something out next time I work on it, thanks for the help. :D
Offline
User avatar

Bryan Ray

  • Posts: 1928
  • Joined: Mon Nov 28, 2016 5:32 am
  • Location: Los Angeles, CA, USA

Re: Rotating every frame a certain degree (Expression)

PostMon Jun 14, 2021 4:35 am

Try this:

math.floor(time/[interval])*22.5

where [interval] is the number of frames you want to wait between rotations.

math.floor() is a function that rounds down to the nearest integer, so math.floor(2.6) = 2. By dividing time by your interval, it will only tick upward when the numerator is a multiple of the interval.
Bryan Ray
http://www.bryanray.name
http://www.musevfx.com

Return to Fusion

Who is online

Users browsing this forum: No registered users and 13 guests