Pipe Overview

Layout Styles

../_images/pipe_layout_types.gif

The NodeGraphQt.NodeGraph class has 3 different pipe layout styles as shown above this can be set easily with the NodeGraphQt.NodeGraph.set_pipe_style() function.


Here’s a example snippet for setting the pipe layout style to be “angled”.
1from NodeGraphQt import NodeGraph
2from NodeGraphQt.constants import PipeLayoutEnum
3
4graph = NodeGraph()
5graph.set_pipe_style(PipeLayoutEnum.ANGLE.value)
There are 3 different pipe layout styles see: NodeGraphQt.constants.PipeLayoutEnum

Note

If you’ve set up your node graph with the NodeGraph.set_context_menu_from_file() function and the example example JSON then you’ll already have the actions to set the pipe layout under the “Pipes” menu.

../_images/pipe_layout_menu.png

Layout Direction

The NodeGraphQt.NodeGraph pipes can also be set with a vertical layout direction with the NodeGraphQt.NodeGraph.set_layout_direction() function.

../_images/vertical_layout.png