The 'random' expression
Here you are a brief explanation of all controls in Nuke's random expression.
This is the full function 'by default':
(random(1,frame*1)*1)+0
or just simplified: random(1,frame)
This creates a curve containing random values between 0 and 1.
The breakdown controls:
(random(seed,frame*frequency)*amplitude)+valueOffset
seed value randomly changes the curve without modify its nature
frequency value increase or reduce the amount of oscillations (1 = 1 peak per frame by default)
amplitude indicates the maximum value of your oscillation (max=1 by default)
valueOffset value decides where the curve sits on Y axis (0 by default)
Example:
if you want to generate a curve with random values between 2 and 8 with a (low) frequency of 1 peak every 5 frames this is the formula:
(random(1,frame*0.2)*6)+2
You can use this function as an expression in any numerical knob.
Comments
it is very useful for me
Thanks again
http://pastebin.com/p4fzUu8C
In AE it's the default setting. Duplicate a layer with a random() expression and the seed will be different.
In Nuke, to make this, I write "xpos" or "ypos" in the seed parameter. It will take the position where the node was created as the seed.
random(ypos, 1)
random(frame) * (myMaxValue-myM inValue) + myMinValue
so in your case this would be:
random(frame) * (1.5-1) + 1
if you link min and max values to user knobs you can drive this interactively.
ie: 1st frame value 1
2nd frame value 0
I need source code of random and noise function in nuke for using in maya.
can you help me?
RSS feed for comments to this post