using relative paths in op:

   14474   7   4
User Avatar
Member
1799 posts
Joined: Oct. 2010
Offline
This may be a simple syntax question, but is there a way to use a relative path with the op: keyword? I am trying to point to a COP operator, and I can do this successfully with absolute paths but will not work with relative paths

I know I have done this is the past with expressions such as op:`opinputpath(“..”, 1)` in cases where I have a node wired as an input. However, when I tried to use opfind, I had no success

Any help on this would be huge!

Attachments:
op.jpg (29.8 KB)

-G
User Avatar
Member
665 posts
Joined: July 2005
Offline
Hi Grey,


You can use the opfullpath() expression for this.

op:`opfullpath('..')`

cheers,
-j
User Avatar
Member
1799 posts
Joined: Oct. 2010
Offline
That worked perfect! Thank you!
-G
User Avatar
Member
12 posts
Joined: Jan. 2017
Offline
How can I link the output from a COP2 network to a texture map in a normal mantra-material in Houdini 15.5.480 ?
The method with the “op:`opfullpath('..')`”-function doesen't seems to work in this version.
User Avatar
Member
25 posts
Joined: May 2015
Offline
xXchrizzoXx
How can I link the output from a COP2 network to a texture map in a normal mantra-material in Houdini 15.5.480 ?
The method with the “op:`opfullpath('..')`”-function doesen't seems to work in this version.

That's my question exactly. Any takers?!
User Avatar
Member
670 posts
Joined: Sept. 2013
Offline
This is probably not the right way to do it, but it works:
op:/img/tex/OUT
https://procegen.konstantinmagnus.de/ [procegen.konstantinmagnus.de]
User Avatar
Member
25 posts
Joined: May 2015
Offline
Hello Konstantin,

Thanks for your suggestion.

This is what I get. Actually, I get that whether I do your “opimg/tex/OUT” or the standard “opimg/img1/OUT”

Oddly, my material turns this light pink as opposed to the standard grey, either way, when I try to call in the texture from null node.

What am I missing, or messing up?

PS. The smilies are from the colons + forward slash.
Edited by marque_pierre - Sept. 11, 2017 10:40:44

Attachments:
Houdini_null.jpeg (631.4 KB)

User Avatar
Member
7803 posts
Joined: Sept. 2011
Offline
op: references don't currently work that way in /mat, as only parameters on materials are scanned for references to external nodes.

You will need to encapsulate your material network in a builder node, and then use a parameter vop to pass the filepath to the texture node. Then for the value on the filepath, you can put the op reference. (note: putting the op reference directly on the parameter default value does not work)
  • Quick Links