3
$\begingroup$

I'm trying to make a procedural pipe generator with geo nodes, the thing is that I have no idea how to distribute the joints where I want. The pipes work by extruding vertices. Here is an example: Pipes skeleton Pipes Geo nodes of that

But when adding joints, I have no idea how to control where to place them. I want them to be place automatically in sections like this:

Where I want them

Following this image as reference:

Image reference

Edit: Currently, I manage to slide them where I want, I just need to find a way to make the ones on each end of the pipe to not translate: Pipes

Here is how I did it: enter image description here

But I'm not sure yet how to isolate the ones at the end of each pipe as they are now seen as individual edges, not conected between them. Any ideas?

Either way I'll say that's not really important now, I thing it works pretty well as how it is right now: edit mode procedural pipes With Material

$\endgroup$
5
  • 1
    $\begingroup$ search for johnny matthews on yt. He made a great tutorial about it. $\endgroup$
    – Chris
    Commented Mar 20 at 5:42
  • $\begingroup$ This might be the video @Chris was referring to: youtube.com/watch?v=_qOLhZQM_7c $\endgroup$
    – curious_1
    Commented Mar 20 at 9:20
  • $\begingroup$ Thank you guys, unfortunatly, some nodes aren't aviable any more on Blender 4.x $\endgroup$
    – LD Furlán
    Commented Mar 20 at 23:02
  • $\begingroup$ From your picture with the red lines, I would propose to define a distance from the "central" node of the device (bend, T-junction, ...) to place joints (plus one at each end obviously). Or to add boxes centred on devices and to put joints at intersection with the segments. How much control would you like ? How automatic would you like it ? Could you use vertex weight to encode this distance ? Could you use vertex groups per kind of devices to hard-code these distances in GN graph ? $\endgroup$ Commented Mar 21 at 8:41
  • $\begingroup$ I want to make it a automatically as possible. I found a different approach but I still need help. I'm going to edit my question. $\endgroup$
    – LD Furlán
    Commented Mar 22 at 2:19

1 Answer 1

1
$\begingroup$

(Using Blender 3.6.8)

Making assumptions about some not shown parts of your GN graph, here is a proposal where new nodes are highlighted in green, and modified nodes in orange.
Before splitting edges to make disconnected curves, the number of edges connected to each vertex is recovered by an Edges of Vertex node to be stored as an attribute in Point domain. Free end vertices have a count of 1 ; others have a count of 2 or more. This attribute is firstly transmitted to curve control points through the Mesh to Curve node, then to spawned instances through the Instance on Points nodes. It is finally used as a selection mask for the Translate Instances nodes, to shift only joints with at least 2 connections.

Pipes with joints

GN graph

Resources:

$\endgroup$
1
  • $\begingroup$ Thank you! It worked perfectly! $\endgroup$
    – LD Furlán
    Commented Mar 23 at 0:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .