Why does noise() not work my expression?

   2345   5   0
User Avatar
Member
59 posts
Joined: 10月 2010
Offline
I am trying to add some variation to particle birth rate and I thought I could use the noise() function in an expression (see screen grab)




but alas, an error results:

Unable to evaluate expression (Invalid number of arguments for function (/obj/particle_emitter/dopnet1/popsource1/constantrate)).

The Help page on the noise() function clearly says that you can use the form

float noise(pos)




I can use rand() or sin() without an error. Why can I not use the noise() function?


Many thanks
Edited by dansidi - 2020年1月16日 17:06:14

Attachments:
Annotation 2020-01-16 215158.png (33.0 KB)
Annotation 2020-01-16 215841.png (17.6 KB)

User Avatar
Member
8605 posts
Joined: 7月 2007
Offline
different noise function
https://www.sidefx.com/docs/houdini/expressions/noise.html [www.sidefx.com]
Tomas Slancik
FX Supervisor
Method Studios, NY
User Avatar
Member
59 posts
Joined: 10月 2010
Offline
Hmm. thanks, Tomas



I tried that one but it only returns 0.0, whatever I put in the parentheses

noise($FF, $FF, $FF) = 0.0
noise($FF, 0.0, 0.0) = 0.0
noise($FF, $FF+100, $FF+1000) = 0.0
noise($FF, 123, 456) = 0.0

Dunno what's going on with noise()
Edited by dansidi - 2020年1月16日 17:23:53
User Avatar
Member
171 posts
Joined: 10月 2016
Offline
strangely that corresponded python function does work if to do it somehow so
hou.hmath.noise1d(hou.Vector3(0.00,0.00,0.00))*100
User Avatar
Member
2042 posts
Joined: 9月 2015
Offline
Yeah seems to be a bug as noise() will only work if at least one of the arguments is an explicit float value.
The remaining then can be $FF.

but I can get a result using $FF(for all three arguments) with snoise().
Edited by BabaJ - 2020年1月17日 10:56:11
User Avatar
Member
59 posts
Joined: 10月 2010
Offline
I gave up with noise() and found snoise() which did seem to work OK.

I can't believe this is a bug that has somehow slipped through.
Surely people are using it all the time but I'm just doing it wrong.
(That's usually what's happening…)

Thanks for your input though!
  • Quick Links