Is Connected VOP

   357   6   1
User Avatar
Member
257 posts
Joined: July 2006
Offline
I'm trying to use the Is Connected VOP for the first time.

I'm in a subnet ( ultimately to become an HDA ), and I want it to output one color ( red ) if an input is not connected, otherwise output the connected input ( green ). The way I have it set up, it's outputting the expected color when the input is connected, but not when not connected ( it's outputting black instead of red ). So, is this not the way it's meant to be used?

Please see the attached hip file.
Edited by A-OC - Aug. 28, 2025 01:53:38

Attachments:
im.png (358.4 KB)
is_conn.hip (688.6 KB)

User Avatar
Member
9242 posts
Joined: July 2007
Offline
while Is Connected VOP doesnt seem to work, you don't really need it

- just create your HDA and then set default value to your promoted custom_input parm and if you don't want to see it in UI make it invisible

- or alternatively use Parameter VOP set to Subnet Input using the same idea

Attachments:
is_conn_mod.hipnc (691.6 KB)

Tomas Slancik
CG Supervisor
Framestore, NY
User Avatar
Member
257 posts
Joined: July 2006
Offline
Thank you, the problem is that my actual need is to use "Position" instead of color, that was just the simplest scene possible, I guess it was too simple then.

So, what I really need is to output the connected position ( when it is connected ), otherwise output uvs ( from UV Position node )
User Avatar
Member
9242 posts
Joined: July 2007
Offline
so it looks like Is COnnected only woks with Subnet Inputs node, which seems to be hidden
not with the default Subnet Input Connector node, and it's probably a bug

have a look at the attached example using Subnet Inputs

Attachments:
is_conn_mod2.hipnc (686.0 KB)

Tomas Slancik
CG Supervisor
Framestore, NY
User Avatar
Member
257 posts
Joined: July 2006
Offline
Interesting. I'm trying to recreate it but it's not working for me: I connect P to null_1, then that to null_2, then make a subnet out of null_1, inside there is the Subnet Inputs node, then build the logic there. When done, if I disconnect P outside I get an error, so I guess it only works with hda's. So I create an hda, then test again, but when I disconnect P I get black as output again. What did I do differently?
User Avatar
Member
9242 posts
Joined: July 2007
Offline
A-OC
What did I do differently?
hard to tell, but try plugging your result into next output, not the same name as our input, I'm also getting black if I use the same name
Tomas Slancik
CG Supervisor
Framestore, NY
User Avatar
Member
257 posts
Joined: July 2006
Offline
Amazing, that's it. Thanks a lot once again.
  • Quick Links