useful mathematic curves

If you do a lot of procedural stuff you need curves and functions all the time. Use them for procedural imaging, shaders, falloff, etc… Here is a short list of the most common functions I use:

squared

hard and fast falloff (light)

1/x2

log

useful for long range falloffs

1/log(x)

scatter

useful for in scattering and nice distance falloffs

1/(offset+factor·distance)power


smooth

transition from 0.0 to 1.0, non-linear, smooth start and end

x2·(3-2x)

interpolate

transition from a to b (input 0.0 – 1.0)

a+x·(b-a)

– syphobia

Advertisements

~ by syphobia on 2011-04-07.

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s