Archive for July 3rd, 2008

03
Jul
08

Superformula Cat

Just realised I could use my Canon PowerShot G6 and Nikon EC-9 to make environment maps for the EnvMap/superformula shader. So, I took a nice snapshot of my cat.
As you do.

03
Jul
08

Very Useful Things: The Mathematical Expressions Patch

I’ve just discovered you can use

min(number1,number2)
and
max(number1,number2)

in the Mathematical Expression patch.
min simply sets the output to the smaller of the 2 inputs, while max sets the output to the larger input number. You could quite easily combine the two to get an equivalent of the GLSL clamp() function.

Not very exciting, you might think, but it impresses me…
I’ve never liked the the Math patch, purely based on the amount of screen estate it takes up. The Mathematical Expression patch is much neater, and also somehow makes it easier for me to pretend I know something about maths (which is patently not the case, sadly).

EDIT:
Just to clarify: I’ve been using the Mathemetical Expression patch for ages. I’ve just discovered a couple of new features I didn’t know about before.