zuo yuanle

zuoyuanle

About Me

EXPERTISE
Game Artist
INDUSTRY
Gamedev

Connect

LOCATION
China
WEBSITE

Houdini Skills

Availability

Not Specified

Recent Forum Posts

MultiParm Block list - return the attribute menu script June 22, 2024, 10:06 a.m.

How can I achieve functionality similar to "Attribute Swap", where the dropdown menu returns the corresponding data types based on the attribute type?
To ensure that your script handles multiple class parameters without overwriting each other and executes correctly, you need to accumulate the results for each class parameter and avoid reassigning the result list. Here's an updated script that ensures the attributes for each class are correctly added to the final result:

r = []
node = kwargs['node']
inputs = node.inputs()
number_casts = node.evalParm("number_casts")
if inputs and inputs[0]:

    geo = inputs[0].geometry()
    
    if geo:
        

#遍历每个属性类别
        for i in range(1, number_casts + 1):
            c = node.parm('class'+str(i)).evalAsString()
        
            if c == 'detail':
                attrs = geo.globalAttribs()
            elif c == 'primitive':
                attrs = geo.primAttribs()
            elif c == 'point':
                attrs = geo.pointAttribs()
            else: # vertex
                attrs = geo.vertexAttribs()
        for a in attrs:
            r.extend([a.name(), a.name()])
return r
Is there anyone who can help guide me? Thank you very much

how to Dynamic set houdini hda reference inputs ? June 1, 2024, 8:38 a.m.

and what does the "is reference" check box in the type properties page under inputs/outputs mean? I want to set
reference inputs show connecting wires as dashed lines

how to Dynamic set houdini hda reference inputs ? June 1, 2024, 8:36 a.m.

reference inputs show connecting wires as dashed lines