How to create a new omnigraph environment

Hello,

we would like to make a “Scene Creation Graph” for our current research project.

This should ideally be an extension, in which the user can build the scene by connecting different omnigraph nodes, each representing a different scene object. Those scene objects, for example a robot cell or a robot arm, have different mounting points. Connecting these object nodes together should allow for an automatic positioning and if needed creation of joints between those objects based on those mounting points.

We could probably implement this with custom nodes in a normal action or push graph, but we would like to make a custom user interface for that (for example with a button to create the scene and with a defined selection of nodes to chose from).

Is it possible to make such a custom omnigraph environment? And is there a documentation or a tutorial for that?

Kind regards

Hi @axel.goedrich. In the Code app, we have a the Omni.UI Graph Docs which would be a good place for you to start:

Dev team is telling me that Omni.UI graph is more advanced and that they strongly recommend starting with custom nodes for Action/Generic graph. You could customize the property panel for your custom nodes, that might serve your needs.

If you choose explore custom graphs and backends, Anim Graph is an interesting example to look at. It uses ActionGraph with custom nodes, but the state machine is currently a different backend that also uses Omni.UI Graph, and shares some widgets with OmniGraph.

1 Like

Thanks for the hint. I will look into it.

I have already experimented with custom omnigraph nodes. The process was pretty straight forward and easy to set up.

The only thing that was missing for our application is access to omnigraph node events, like node creation, destruction or a change of node inputs. It would be very helpful to have access to such events within a node itself.

Hi @axel.goedrich. That sounds interesting. If you have some example of how you’d find that functionality useful. I can share it with the dev team.

Hi @mati-nvidia,

one interesting use case for us is scene creation.

The video below is from a quick prototype I created for actiongraph.

The idea behind this is that individual components of the scene can be created through Omnigraph nodes and automatically positioned and possibly parameterized by connecting them.

This is motivated by our current research project, in which we want to train robots for assembly applications on industrial plants. The plants we are looking at mostly consist of the same or at least similar components connected in different configurations.

Omnigraph would theoretically be a nice and user-friendly solution to assemble such systems from components.

The following functions would be very helpful for that:

#gets called on node creation
def on_startup(db): 
    #load the USD


#gets called on node destruction
def on_shutdown(db): 
    #remove usd prim


#gets called when node inputs change
def on_input_change(db): 
    #for example position object based on inputs

In addition, it would be useful if the node object from the respective node class is initiated during node creation. This would open up the benefits of object-oriented programming.