Hi
I have a shader prim that I would like to add a texture to via vex. With usd_setattrib(0, @primpath, "inputs:tex0", "texturepath") I am successfull to change the attribute, however Redshift doesn't like it. On comparision between a value set with a material node I can see that the texture path is encapsulated by @ -> @texturepath@.
The reason is that inputs:tex0 is a usd input, rather than a string I suppose. However when the attribute is created with a material node (so that the input is set up correctly) then using the same line works.
So is there a way to create the attribute as an usd_input. I tried with python a bit but ... that pixar documentation beats me down every time.
Creating texture path with VEX
2510 3 1- Marco Dörner
- Member
- 31 posts
- Joined: June 2016
- Offline
- Marco Dörner
- Member
- 31 posts
- Joined: June 2016
- Offline
- rafal
- Staff
- 1449 posts
- Joined: July 2005
- Offline
You can call `usd_addattrib()` with the desired type ("asset"), first. Then set it.
https://www.sidefx.com/docs/houdini/vex/functions/usd_addattrib.html [www.sidefx.com]
https://www.sidefx.com/docs/houdini/vex/functions/usd_addattrib.html [www.sidefx.com]
- Marco Dörner
- Member
- 31 posts
- Joined: June 2016
- Offline
-
- Quick Links