Jump to content

How can I create linked channels on a parm using python?


zrags

Recommended Posts

I'm trying to create and customize a node through a python script. I'm adding parms using the hou.parmTemplate() class and for one of the parameters I need to edit the Channel tab (see below).

I can't seem to find anything in the python documentation on how to do this; anybody know what the best solution would be?

Thanks!

image.png.33b25666562d1f644150cc9d4531bb7b.png

Link to comment
Share on other sites

Hi,

if you set the parm expression to link to the parm of your liking, then Houdini should add the linking automatically. (Make sure to refresh/reopen the Edit Parm Window after executing this to see the new linked channels in the Channel tab.) 

hou.node("/obj/geo").parm("parm_to_be_linked").setExpression("ch('parm_to_drive_link')")

Cheers,

Luca

  • Thanks 1
Link to comment
Share on other sites

On 10/10/2019 at 1:43 AM, LucaScheller said:

Hi,

if you set the parm expression to link to the parm of your liking, then Houdini should add the linking automatically. (Make sure to refresh/reopen the Edit Parm Window after executing this to see the new linked channels in the Channel tab.) 


hou.node("/obj/geo").parm("parm_to_be_linked").setExpression("ch('parm_to_drive_link')")

Cheers,

Luca

Thanks! This was exactly what I needed.

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...