Create points along a pipe via script?

Ok so I have a pipe (actually lots and lots of pipes) and it bends and twists in every direction. I need a path along this pipe so that I can attach things to it to show things like flow direction in the pipe and even attaching a camera to the pipe. So without going through the trouble of building a path by hand for each of the 200+ pipes in my scene how can I place cubes along the pipe via script?

I have a method for connecting the cubes to create a path. SO I am not worried about that, I just need to know how to place cubes along the pipe. Any Ideas?

Preferably I want to place one cube infront of and one after each bend in the pipe.

Gonna attach a image of the pipes so you can see what I am working with…

376317--13025--$untitled_1_160.jpg

If you only need to place an object at the bends then you don’t really need a spline path.

The easiest solution would probably be to create a dummy marker mesh in your 3d app at the proper place when creating your pipe model. It would only have to be done once for each individual pipe model you have.

You can then grab the world position of your dummy mesh easily in script and use it along with an offset to place your flow direction icons.