Hi All,
My trig maths is awful ! to the point I cannot seem to replicate what I can do in SOPs . I have built a vop sop and try to replicate in the scene what an attribute SOP is doing. In this case a simple sin wave with a frequency and amplitude < no sure in VOP sops why I could get inverted values. Any ideas
Rob
Trig Vop
2384 5 0- circusmonkey
- Member
- 2624 posts
- Joined: Aug. 2006
- Offline
- tamte
- Member
- 8579 posts
- Joined: July 2007
- Offline
- sanostol
- Member
- 575 posts
- Joined: Nov. 2005
- Offline
- circusmonkey
- Member
- 2624 posts
- Joined: Aug. 2006
- Offline
Hi Tomas,
Thanks for the tip, thats one for the note book without doubt. Part 2 of my question because it interests me and Im sure others, sin() is values between -1 and 1 . So if I have values that currently go from -2 to 2 is there a way to move the range to positive numbers without the clamping. I thought fit(sin($FF*12)*2,-2,2,0,4) would do that job. Its been so long since messing with numbers I have done a quick refresher and got something working
Always helps to visually drive something with values ! . fixed scene attached for others to look at
Rob
Thanks for the tip, thats one for the note book without doubt. Part 2 of my question because it interests me and Im sure others, sin() is values between -1 and 1 . So if I have values that currently go from -2 to 2 is there a way to move the range to positive numbers without the clamping. I thought fit(sin($FF*12)*2,-2,2,0,4) would do that job. Its been so long since messing with numbers I have done a quick refresher and got something working
Always helps to visually drive something with values ! . fixed scene attached for others to look at
Rob
Gone fishing
- tamte
- Member
- 8579 posts
- Joined: July 2007
- Offline
that's correct fit(sin($FF*12)*2,-2,2,0,4) will rescale -2..2 range to 0..4
and since sin()*2 has limits at -2,2, it will not be clamped
but in that case multiplying sin() by 2 is redundand
so you can just use
fit11(sin($FF*12),0,4)
fit11() will assume source range is -1..1, which for sin() is correct
and since sin()*2 has limits at -2,2, it will not be clamped
but in that case multiplying sin() by 2 is redundand
so you can just use
fit11(sin($FF*12),0,4)
fit11() will assume source range is -1..1, which for sin() is correct
Tomas Slancik
FX Supervisor
Method Studios, NY
FX Supervisor
Method Studios, NY
- circusmonkey
- Member
- 2624 posts
- Joined: Aug. 2006
- Offline
-
- Quick Links