I can create a new parameter with hou.Ramp((lin, lin), (0, 1), (2.5, 4.5))
and put it on the template in an a node.
but is there a way that I can link it?
promote and link a ramp with python
4799 5 2-
- pelos
- Member
- 624 posts
- Joined: Aug. 2008
- Offline
-
- edward
- Member
- 8081 posts
- Joined: July 2005
- Offline
-
- pelos
- Member
- 624 posts
- Joined: Aug. 2008
- Offline
-
- djolafrite
- Member
- 1 posts
- Joined: Aug. 2012
- Offline
Hey guys sorry to revive this topic. I'm running into the same issue and i've tried what you were saying Edward and think I got the syntax right but its not working. It seems I'm missing something
as an example I have a geo1 node in /obj with two nulls, null1 and null2. I added a float ramp on each of them with the same name called parm
and then I try to run this in the textport :
this yields nothing like nothing happened. However if I run
if outputs :
I also tried creating a subnetwork with a null and a ramp and then promoting it from the subnetwork and its connected it works
I then run
It will output :
So then I tell myself ok then lets create another subnetwork with a null that has a ramp parameter called parm. Create a ramp parameter on the subnetwork also called parm and run the same thing as what it outputed just previously:
so I run
Nothing happens. I move and add stuff on the ramp on the subnet but the null ramp just ignores it
I check its connected by using
and it outputs
same as with the subnet which I manually promoted the ramp.
Is there another step I am missing to get this to work ? I feel I've tried everything you mentioned here and in other threads on odforce or anything I could find
Thanks for the help
as an example I have a geo1 node in /obj with two nulls, null1 and null2. I added a float ramp on each of them with the same name called parm
and then I try to run this in the textport :
opmultiparm /obj/geo1/null1 'parm#pos' '../null2/parm#pos' 'parm#value' '../null2/parm#value' 'parm#interp' '../null2/parm#interp'
this yields nothing like nothing happened. However if I run
opmultiparm /obj/geo1/null1
if outputs :
opmultiparm null1 'parm#pos' '../null2/parm#pos' 'parm#value' '../null2/parm#value' 'parm#interp' '../null2/parm#interp'
I also tried creating a subnetwork with a null and a ramp and then promoting it from the subnetwork and its connected it works
I then run
opmultiparm /obj/geo1/subnet1/null1
It will output :
opmultiparm null1 'parm#pos' '../parm#pos' 'parm#value' '../parm#value' 'parm#interp' '../parm#interp'
So then I tell myself ok then lets create another subnetwork with a null that has a ramp parameter called parm. Create a ramp parameter on the subnetwork also called parm and run the same thing as what it outputed just previously:
so I run
opmultiparm /obj/geo1/subnet2/null1 'parm#pos' '../parm#pos' 'parm#value' '../parm#value' 'parm#interp' '../parm#interp'
Nothing happens. I move and add stuff on the ramp on the subnet but the null ramp just ignores it
I check its connected by using
opmultiparm /obj/geo1/subnet2/null1
and it outputs
opmultiparm null1 'parm#pos' '../parm#pos' 'parm#value' '../parm#value' 'parm#interp' '../parm#interp'
same as with the subnet which I manually promoted the ramp.
Is there another step I am missing to get this to work ? I feel I've tried everything you mentioned here and in other threads on odforce or anything I could find
Thanks for the help
-
- OdFotan
- Member
- 192 posts
- Joined: April 2015
- Offline
-
- OdFotan
- Member
- 192 posts
- Joined: April 2015
- Offline
Check out this hip file guys. That works really well.
You only have to fickle a bit with the 'ramp copier' for it to work.
Is there a way to have this 'constantly' being evaluated?
I don't want to set any callback script on the ramp that is being copied. Only on the ramp_copier hda.
I see there is a hou.ui.addEventLoopCallback(), but that seems more like a global function, rather than something that lives in the HDA, inside that parameter.
(also: I want to do this via a script and this "ramp_path_parameter", and not with opmultiparm)
-
You only have to fickle a bit with the 'ramp copier' for it to work.
Is there a way to have this 'constantly' being evaluated?
I don't want to set any callback script on the ramp that is being copied. Only on the ramp_copier hda.
I see there is a hou.ui.addEventLoopCallback(), but that seems more like a global function, rather than something that lives in the HDA, inside that parameter.
(also: I want to do this via a script and this "ramp_path_parameter", and not with opmultiparm)
-
Edited by OdFotan - Nov. 15, 2021 20:49:52
-
- Quick Links



