Feature request for Rhino 6 - Extract a pipe's (center) curve

Hi everybody,

I think Rhino 6 should have a built in command that could extract a curve from the center of a pipe.

After searching around I’ve found that Pascal was offering a script that does that: here and here
which works very nice. though you have to explode the pipe first and then select the pipe itself (detached from the caps) while in the script’s command

Sometimes you have a pipe and you don’t have the curve that created it,
either you didn’t make the model yourself and you got it or it just doesn’t exist in your particular file from any other reason.
and let’s say you want to have that curve so you could pipe it again with a different dimension for example or to change its control points and pipe it again.
This is not really me- as I keep all the objects all time while using my workflows, but sometimes it happens and I think it should have a simple and elegant built in solution in a form of a new command. Pascal has called the script: “PipeCenterline”.
in my opinion I would’ve called it something like: “Extractpipecurve” and may also suggest it could reside in the “curve from object” toolbar.

It’s really not a major thing that is missing of course but it’s just something I think that solves one little issue and could make working in Rhino even smoother. (is that what you would call a “paper-cut”?)

The only option I found as a workaround is to extract two isocurves from the sides of the pipe, usually snapping to the two quadrants of the circle edge of one of the two ends of the pipe and then tween curves between them. ("MeanCrv for Rhino V4 users), it works great but it is a time consuming procedure.
here is a demo:



Just sharing my opinion, what do you think?

Best Regards,

Roy Zadok.

1 Like

Another method to find the centerline of a circular pipe of constant diameter.

  1. Create two curves on the surface of the pipe, each running the length of the pipe. These curves can be isocurves but not required. Preferred if the curves are close to opposite each other but not required.

  2. Create two pipes using the surface curves from the previous step as the centerlines. These pipes need to be the same diameter as the original pipe.

  3. Intersect the two new pipes. The centerline of the original pipe will be one of the curves from the intersection of the two new pipes.

@davidcockey It could also be a way, but it is one step longer than my workaround in my opinion,
as after you have the 2 curves you only need to tween between them and with your suggestion you need to pipe them and intersect them, so that’s like one additional command. but again, it could also work.
but with your suggestion I still also think the curves need to be opposite to each other or else you won’t get the perfect center won’t you?

@Roy No, the curves do not need to opposite each other in the method I described above to obtain the “exact” centerline. That is the advantage of it. It does require a constant diameter pipe though.

@davidcockey You are right about that, that was interesting.
but yet again, I think this issue should be solved with a built in command in Rhino.
Cheers.

Hi Roy.you give me a good idea for another command i would like to put in my rhino 5 plugin. In genuary probably we have the exit.I think it would be better to create that center curve for every kind of pipe (different sections shapes) and with the possibility to change it’s number of control points so it is more flexible command.if i find the time i will put it on the first version otherwise in some relases.

That sounds cool @gianfranco74, good luck with the plug-in!

But as for the basic functionality of extracting the center curve of a constant diameter pipe,
I would have liked to see that built into Rhino.

+1… This would be very helpful

You must be reading my mind… I posted on the T-Splines forum today requesting the very same command :smile:

Where I have tspipes joined together in an organic form i’d like the centre curve to butt-up perpendicular to other curves.

Although I started with curves to drive the pipes, i’ve made many changes but would still like the overall centrelines of the existing model when I’m done.

1 Like

Sorry if i can not put my attention to it immediately. I’m in trouble with rhino installer engine and with one very difficult command of mine that takes all my seconds . as soon as i finish these two things i will do that and then if you will give me some feedback i will appreciate .

Hi @gianfranco74, Take your time, as I said, there is already a script for this function offered by Pascal here

I am a trainer and a reseller so I am not after the command for my personal use, but for Rhino in general.
I will also be glad to give you feedback for your plug-in, contact me then.

thank you