Jump to content
art3mis

Attribute Create> Unable to evaluate expression $NX, $NY, NZ

Recommended Posts

Trying to create a new Vector attribute from normals but keep getting an error "Unable to evaluate expression..."

 

I can't see anything wrong...can anyone help?

unable to evaluate expression.png

Share this post


Link to post
Share on other sites

the last 0  might be your issue, or it might be in the transform if you are applying something to it 

Edited by Sepu

Share this post


Link to post
Share on other sites

If I understand correctly that you are just trying to make a new vector attribute that is your normals

just wrangle v@dir = @N;

maybe sharing the rest of error code may give us a better idea

 

 

Share this post


Link to post
Share on other sites

Thanks, missed that memo...does @N.x now replace $NX ?

Anyways am following this tutorial, starting exactly at around 5:30(screenshot attached).  The only way I can make the error go away is if I enable the Add SOP and change my class from Point to Vertex in attribute create, which has me puzzled since in my Geo Spreadsheet if I enable Vertices I see nothing in my spreadsheet. Missing something very fundamental! I think the error may be happening 'upstream' in my Point VOP and I'm not correctly generating normals since if I select the Transform SOP and the Attributes drop down, I see nothing though in the tutorial there are both Point and Normal attributes.

 

I've attached my .hip in progress...if anyone could have a look and tell me wtf I am doing wrong would be GREATLY appreciated!

 

 

 

 

attribute_create.png

edge_displacement_shader_vimeo_5:32.hiplc

Share this post


Link to post
Share on other sites

well it seems to be a bug, but when I create a new attribcreate with @N.x, @N.y and @N.z it works... try delete your node and create a new one. If the error is still there, well, just put it in a point wrangle as Yon said : v@dir = @N;

Share this post


Link to post
Share on other sites

not bug...you just need eagle eyes...

look at next to the gear icon...it's got 'funny' colors....

click on it and change it back (from python) to Hscript

Now $NX/Y/Z will work

(if you already have something in the fields and after you've changed it back to hscript and still didn't work...just 'delete' all channels and retype in $NX/Y/Z)

Share this post


Link to post
Share on other sites

As Noobini said, N.x is for python scripting and NX is hscript. It all just depends on what coding you are working with.  your attributecreate is set to python and not hscript. 

Share this post


Link to post
Share on other sites

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

Sign in

Already have an account? Sign in here.

Sign In Now

×