FCurve Smooth Expression

Discussions about animating in SOFTIMAGE©
Post Reply
chepmedia
Posts: 36
Joined: 27 Jun 2013, 22:19

FCurve Smooth Expression

Post by chepmedia » 08 May 2015, 21:44

I have an fcurve from a camera track. It doesn' need to match the original camera so I'd like to reduce the high-frequency noise interactively. I know of "Curves > Curve Processing Options > Smooth" but I'm wondering ... can this be done non-destructively with an expression? My only frame of reference is from After Effects with the smooth(time width, samples) expression.

Thanks,

Marc

User avatar
FXDude
Posts: 1129
Joined: 19 Jun 2012, 21:59

Re: FCurve Smooth Expression

Post by FXDude » 12 May 2015, 21:44

There isn't a preset function for it like AE, and there may be a way to specify a range of frame integers,
but this Expr. works

Code: Select all

av( 
at_frame( Fc - 2, null.kine.local.posy ), 
at_frame( Fc - 1, null.kine.local.posy ), 
at_frame( Fc, null.kine.local.posy ), 
at_frame( Fc + 1, null.kine.local.posy ), 
at_frame( Fc + 2, null.kine.local.posy )
 )
(averages current Y value with 2 frames before and after)

You can have it reffer a null's anim or custom (float) parameters under your object (using the custom pset wizard)

chepmedia
Posts: 36
Joined: 27 Jun 2013, 22:19

Re: FCurve Smooth Expression

Post by chepmedia » 12 May 2015, 22:45

Thank you for this suggestion - it looks like it's just what I need . .. and I can just add more frame range to expand the averaging. Will let you know how this turns out.

Marc

Post Reply

Who is online

Users browsing this forum: No registered users and 63 guests