I was trying to create a compound that takes input from a port, but if the port is unconnected, takes its value from elsewhere. A sort of "value override".
I tried to solve this using a "First Valid" node, but it seems the exposed input ports always have a value.
What am I missing here? How could I solve this?
Compound input ports always valid?
-
Hirazi Blue
- Administrator
- Posts: 5113
- Joined: 04 Jun 2009, 10:15
Compound input ports always valid?
Stay safe, sane & healthy!
-
Hirazi Blue
- Administrator
- Posts: 5113
- Joined: 04 Jun 2009, 10:15
Re: Compound input ports always valid?
As I came across this problem again today, let's BUMP it, even though it didn't get any reactions the first time around...
;)
;)
Stay safe, sane & healthy!
-
rray
- Moderator
- Posts: 1810
- Joined: 26 Sep 2009, 13:51
- Location: Bonn, Germany
Re: Compound input ports always valid?
Exposed ports always have some kind of control item on the property page - for example, a scalar value has a slider. Its default value is what it was at at the time it was exposed.
You could change the default value by removing the port, changing the value inside the compound, and then re-exposing. Unless I completely missed the point x-D
I don't see any way to make the compound go red if nothing is connected. Maybe there's some option when editing the XML, like "no_ui_please" ?-o no idea
You could change the default value by removing the port, changing the value inside the compound, and then re-exposing. Unless I completely missed the point x-D
I don't see any way to make the compound go red if nothing is connected. Maybe there's some option when editing the XML, like "no_ui_please" ?-o no idea
softimage resources section updated Sep 26th 2026
-
Mathaeus
- Posts: 1778
- Joined: 08 Jun 2009, 19:11
- Location: Zagreb, Croatia
Re: Compound input ports always valid?
as far as I know, you can't do that directly, but - sometimes - it's possible to do the creativity, if you exactly know what you expect from input port. I'd believe I'm a small master in this field
.
For example, if your expected input is array, you can use something like get array size> if more than 1 (or maybe zero...) then... ...as additional benefit, that will force desired context in the same time....
There are two compounds in latest Kristinka Hair tools, doing that with geometry queries: 'Is NURBS input exists' and 'Is curve input exists'.
Probably you can do something usable with ICE Multiple input ports feature, or Set Data on same attribute again, after all, with a new node.... or you just can't, sometimes
as usually, it depends what you doing....
P.S. of course, that 'always checking' if something exists or not, has a price of extra evaluation - I think that in ICE philosophy, the best way is to use the new node....
For example, if your expected input is array, you can use something like get array size> if more than 1 (or maybe zero...) then... ...as additional benefit, that will force desired context in the same time....
There are two compounds in latest Kristinka Hair tools, doing that with geometry queries: 'Is NURBS input exists' and 'Is curve input exists'.
Probably you can do something usable with ICE Multiple input ports feature, or Set Data on same attribute again, after all, with a new node.... or you just can't, sometimes
as usually, it depends what you doing....
P.S. of course, that 'always checking' if something exists or not, has a price of extra evaluation - I think that in ICE philosophy, the best way is to use the new node....
Last edited by Mathaeus on 05 Oct 2010, 11:30, edited 1 time in total.
-
Hirazi Blue
- Administrator
- Posts: 5113
- Joined: 04 Jun 2009, 10:15
Re: Compound input ports always valid?
Thanks, guys, I will look into it some more... ;)
Stay safe, sane & healthy!