H o u d i n i    p a t t e r n    a n i m a t i o n


The animation and notes on this page explain how custom shaders written in the RenderMan Shading Language can be animated using Houdini and the ".otl" extension..

 

Link to a tutorial for integrating RSL shaders with Houdini written by Brian Murphy



This animation uses Houdini particles and expressions to run the noise channels

on two different shaders, the code for the checkerboard pattern is to your right.

float sNoise = s + (noise (P*wFreq) -0.5) * wAmp;
float tNoise = t + (noise (P*wFreq) -0.5) * wAmp;
vector surfcolor = set(colorBG);

for (i=0; i<=1; i+=q) {
	for (j=0; j<=1; j+=q) {
		if (((sNoise>=i) && (sNoise<(i+width))) && 
		    ((tNoise>=j) && (tNoise<(j+width))))
			surfcolor = set(colorFG);
	}
}
for (i=width; i<=1; i+=q) {
	for (j=width; j<=1; j+=q) {
		if (((sNoise>=i) && (sNoise<(i+width))) && 
		    ((tNoise>=j) && (tNoise<(j+width))))
			surfcolor = set(colorFG);
	}
}

			


This animation is another example that uses expressions on the colors and on

the noise on two different shaders, the code for the other shader is on your right.

float sNoise = s + (noise (P*sFreq) -0.5) * sAmp;
float tNoise = t + (noise (P*tFreq) -0.5) * tAmp;

vector surfcolor = set(colorBG);
if ( (cos(sNoise) * sin(tNoise) > average) || (sin(sNoise) * cos(tNoise) > average))
	surfcolor = set(colora);
if ((sExp >= tRoot)&&(tExp <= sRoot))  // these are exponential and square root proc.
	surfcolor = set(colorb);
if ((sExp <= tRoot)&&(tExp >= sRoot))
	surfcolor = set(colorc);
if (sqrt((pow((low-sNoise), power)) + (pow((high-tNoise), power)))<=radius1)
	surfcolor = set(colord);
if (sqrt((pow((high-sNoise), power)) + (pow((low-tNoise), power)))<=radius2)
	surfcolor = set(colore);
if (sqrt((pow((low-sNoise), power)) + (pow((low-tNoise), power)))<=radius3)
	surfcolor = set(colorf);