0
Écarté

Randomness/Noise

Tomáš Mariančík il y a 11 ans mis à jour par Freya Holmér (Developer) il y a 11 ans 0
Is it possible to add some nodes for generating random values (or source of noise textures)? Either completely random or nodes that take some value as "seed" and output random value based on that (So 0.2 would give 0.8232 and 0.21 0.1223 for example - completely different values with small change of the input).

Solution

Solution
Écarté
As far as I know, there's no way of doing that in shader code, as I've heard Unity's CG implementation doesn't support the noise() function either.

However, pretty much every shader out there that uses noise would use a noise texture, and sample from that, which should work :)

It might be a good idea to include a noise texture in the example assets though.

Thanks for the request anyhow!
Solution
Écarté
As far as I know, there's no way of doing that in shader code, as I've heard Unity's CG implementation doesn't support the noise() function either.

However, pretty much every shader out there that uses noise would use a noise texture, and sample from that, which should work :)

It might be a good idea to include a noise texture in the example assets though.

Thanks for the request anyhow!