MAXON CINEMA 4D: Cinema 4D Forum Adobe After Effects Forum

Xpresso user data slider problem

COW Forums : Maxon Cinema 4D

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
James Ronan
Xpresso user data slider problem
on Jan 15, 2015 at 1:41:20 pm

Hi there,

I am having trouble with a custom slider I have created.

The slider goes from 0 - 180 and controls a bend deformers strength.
What I would like the bend deformer to do is this:

Slider: 0, Bend Strength: 0
Slider: 90, Bend Strength: -30
Slider: 135, Bend Strength: 30
Slider: 180, Bend Strength: 0

I am very stuck, I feel like it could be done with the range mapper, but my expresso knowledge is very limited.

Any help would be appreciated so much!


James :)

Return to posts index

Brian Jones
Re: Xpresso user data slider problem
on Jan 16, 2015 at 3:52:25 am

yes a Range Mapper will work but you will have to use the Spline function at the bottom. Check the manual for how splines work in the parameters they are in.
Range mapper would be set to Input lower = 0 Input upper = 180 (slider min and max) coming in which you want to map to your highest and lowest output values which are 30 and -30 so -30 is your output lower and 30 your output upper.
The spline then modifies that. I think of it as output along the y, input on the x.
Start with a Linear preset spline.
If you click on any one point in the spline you can type in the values for X and Y underneath (click the little black triangle by the spline box)
You want Slider 0 = Bend 0 so the first point on the left (in/slider = 0) should be at 1/2 (50% or .5 however you want to think about it) because halfway between the output min = -30 and max = 30 is 0 so first point is X=0 Y=0/5.
Next point (you will have to add it (control-click)) is at slider = 90 and that's 1/2 way so add a point close to 1/2 way then you can type in the exact values are the values, the bend to be -30 which is the minimum value of the output so the second point should be X=0.5 Y= 0
The next point is slider = 135 which is 3/4 of 180 and you want the bend to be 30 (the max value) so X=0.75 Y=1
The fourth point should be at X=1 Y=0.5

Like this

oh yeah and a Degree node needs to go in between the Range Mapper and the Bend Deformer because the math is in degrees but C4D uses Radians for all angles so the Degree node set to Degree To Radians does the math...

Return to posts index

James Ronan
Re: Xpresso user data slider problem
on Jan 16, 2015 at 12:31:26 pm

Hurrar, success!

You are amazing! Such a detailed description too!

This is working great. Really helped with what I'm doing.

Will be using this a lot in the future, thanks again.

Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2018 All Rights Reserved