## Recommended Posts

Hopefully this is helpful to others.

Small snippet to visualize the different noise's. I have not put them all in, but if you feel inclined please add more and reply-post.

You will need to create the menu (as this does not seem possible in VEX and has to be done via the parameter interface?

and a 100x100 grid as input.

```//
// Houdini Noise visulization - Curtis
//
// Create a Ordered Menu "NoiseMenu", In the "Pram Interface",
//Token, Lable ...
// 0 vnoise
// 1 wnoise
// 3 flownoise
// 4 curlnoise
// 5 xnoise
// 6 random
// 7 alligator

float   frequency = ch("frequency");
float   rough = ch("roughness");
float   atten = ch("attenuation");
float   jitter = ch("jitter");
int     turbulence = ch("turbulence");
int     flow = ch("flow");
int     seed = ch("seed");

//Noise data
vector  vp0, vp1;
float   output1=0;
float   output2=0;

//No Case stament in VEX ... elseif it is..
if ( NoiseMenu == 0 ){
//vnoise VEX function
//Generates Voronoi (cellular) noise.
vnoise(@P, set(jitter, jitter, jitter), seed, output1, output2, vp0, vp1);
}
else if ( NoiseMenu == 1){
//wnoise VEX function
//Generates Worley (cellular) noise.
wnoise(@P, @P.z*frequency, output1, output2); //general noise
}
else if ( NoiseMenu == 2){
//snoise VEX function
//functions are similar to wnoise.
output1 = snoise(@P,  turbulence, rough, atten);
}
else if ( NoiseMenu == 3){
//flownoise VEX function (soft)
//Generates 1D and 3D Perlin Flow Noise from 3D and 4D data.
output1 = flownoise(@P*frequency,  flow);
}
else if ( NoiseMenu == 4){
//curlnoise VEX function
//Computes divergence free noise based on Perlin noise.
output1 = curlnoise(@P*frequency);
}
else if ( NoiseMenu == 5){
//xnoise VEX function
//Simplex noise is very close to Perlin noise
output1 = xnoise(@P*frequency);
}
else if ( NoiseMenu == 6){
//random VEX function
//Generate a random number based on the position in 1-4D space.
output1 = random(@P*frequency);
}
else if ( NoiseMenu == 7){
//anoise VEX function
//Generates "alligator" noise.
output1 = anoise(@P*frequency,turbulence, rough, atten);
}

//Output to 100x100 grid as colour
@Cd = output1;```

• 2

##### Share on other sites

I've done a snippet like this...
but with a menu it's better

thanks

Edited by flcc

##### Share on other sites
On 03/07/2020 at 11:51 AM, Trilec said:

Hopefully this is helpful to others.

Small snippet to visualize the different noise's. I have not put them all in, but if you feel inclined please add more and reply-post.

You will need to create the menu (as this does not seem possible in VEX and has to be done via the parameter interface?

and a 100x100 grid as input.

```
//
// Houdini Noise visulization - Curtis
//
// Create a Ordered Menu "NoiseMenu", In the "Pram Interface",
//Token, Lable ...
// 0 vnoise
// 1 wnoise
// 3 flownoise
// 4 curlnoise
// 5 xnoise
// 6 random
// 7 alligator

float   frequency = ch("frequency");
float   rough = ch("roughness");
float   atten = ch("attenuation");
float   jitter = ch("jitter");
int     turbulence = ch("turbulence");
int     flow = ch("flow");
int     seed = ch("seed");

//Noise data
vector  vp0, vp1;
float   output1=0;
float   output2=0;

//No Case stament in VEX ... elseif it is..
if ( NoiseMenu == 0 ){
//vnoise VEX function
//Generates Voronoi (cellular) noise.
vnoise(@P, set(jitter, jitter, jitter), seed, output1, output2, vp0, vp1);
}
else if ( NoiseMenu == 1){
//wnoise VEX function
//Generates Worley (cellular) noise.
wnoise(@P, @P.z*frequency, output1, output2); //general noise
}
else if ( NoiseMenu == 2){
//snoise VEX function
//functions are similar to wnoise.
output1 = snoise(@P,  turbulence, rough, atten);
}
else if ( NoiseMenu == 3){
//flownoise VEX function (soft)
//Generates 1D and 3D Perlin Flow Noise from 3D and 4D data.
output1 = flownoise(@P*frequency,  flow);
}
else if ( NoiseMenu == 4){
//curlnoise VEX function
//Computes divergence free noise based on Perlin noise.
output1 = curlnoise(@P*frequency);
}
else if ( NoiseMenu == 5){
//xnoise VEX function
//Simplex noise is very close to Perlin noise
output1 = xnoise(@P*frequency);
}
else if ( NoiseMenu == 6){
//random VEX function
//Generate a random number based on the position in 1-4D space.
output1 = random(@P*frequency);
}
else if ( NoiseMenu == 7){
//anoise VEX function
//Generates "alligator" noise.
output1 = anoise(@P*frequency,turbulence, rough, atten);
}

//Output to 100x100 grid as colour
@Cd = output1;```

Curtis @Trilec, my old fiend, how are you mate? Where are you working on in Germany?

Thanks you for this one. I see you as me are houdini's addicted now

Here's one i could share below

________________________________________________________________

Vincent Thomas   (VFX and Art since 1998) (my procedural work for the Netfix'serie is about to end, lkooking for a new adventure to jump on now)
Senior Env and Lighting  artist & Houdini generalist & Creative Concepts

------------------------------------------------------------------------------------------------------------------------------------------------------

// wrapper function for different noises, angle ramp
float noise_wrapper(vector Q; int id)
{
float r;
if (id == 0)
{
r = float(anoise(Q));
} else
if (id == 1)
{
r = float(onoise(Q));
} else
if (id == 2)
{
r = float(snoise(Q));
} else
if (id == 3)
{
r = float(curlnoise(Q));
} else
{
r = float(noise(Q));
}
return r;

}
// get the number of multiparm
int n = chi('para');
// init string
string s;

vector up = set(0,1,0);
float angleN = acos(dot(v@N, up));

for (int i = 0; i < n; i++)
{
// multiparm index (as string)
s = itoa(i+1);
float angle = radians(chf('angle' + s));
float rangea = radians(chf('rangea' + s));
float eps = 1e-3;
if (rangea < eps)
{
return;
}
// fit angle to interval
float a = efit(angleN, angle - rangea, angle+rangea, 0, 1);
if ((a > 1) || (a < 0))
{
a = 0;
}
// evaluate ramp multiplier
float r = chramp('ra' + s, a);
// rescale noise
r *= chf('amount' + s);
// use noise multiplier/offset
vector nm = chv('nm' + s);
vector no = chv('no' + s);
int id = chi('nt' + s);
@P += v@N * noise_wrapper(nm*@P + no, id) * r;
}

## Create an account or sign in to comment

You need to be a member in order to leave a comment

## Create an account

Sign up for a new account in our community. It's easy!

Register a new account