Search - User list
Full Version: APEX Make Template Graph in Component Script?
Root » Rigging » APEX Make Template Graph in Component Script?
dayton_busse
Hi! Does anyone know how to define a function in APEX Script, and then tell a component script to create a graph::Template node containing that function in the graph it’s modifying? I need to plug a compiled graph into a SimEngine node in the rig. OR does anyone know how to modify the internal subnet of a graph::Template after it’s created?

The SideFX website has an example of “Invoking a graph” with script which only creates a graph::Template node containing a function IN the component script. I’d like the component script to create this node in the actual rig.
esttri
def myTest(a: Int, b: Int):
    a += 1
    a += b
    return a

templ  = graph.addNode('templ', 'graph::Template')
templ.setSubnetContents(myTest)

here you go
dayton_busse
Ahh got it. I can just set the internal subnet with a function call. Vey helpful, thank you so much!
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Powered by DjangoBB