View Full Version : Stop rail extrude from twisting

05-10-2006, 07:31 PM
OK, lets see if I can explain this...

I'm making a sort of wiggly toroid. I laid down a spline path and rail extruded a ring of 2 point polys along it. It worked and made a tube that followed the path, but the polys rotate as they follow the path so when they get back to the start they are oriented wrong and when they close to the first set they are criss crossing all over the place.

I thought the spline path was just a sequence of points, but this shows me that each point has an up and a down and can get oriented differently than the world up/down. (sorry for my newbie speak).

So, how can I either force all the points along the spline to reset their orientation relative to the world up/down without changing their x/y/z position at all? Or, how can I change/manipulate the orientation of each point without moving the x/y/z position of each point?

In case this wasn't clear, the object being extruded along the path is rotating around the axis of where the object intersects the path. (don't know if that's any better)

05-11-2006, 02:47 PM
I run into this issue from time to time as well. Even with the awesome LWCAD tools for working with curves it still happens. If anyone knows any tricks please do share the knowledge!

And on a related note...

Recently I was thinking about how nice it would be to be able to edit the spline "after" extruding, and have it affect the extruded geometry. I always have to completly redo the process when only something minor needs changing.


05-11-2006, 05:08 PM
I know what you're talking about, and it sucks.
I don't know about aligning the points like you're saying, but I will definitely be looking into that later tonight.
What I usually do is break up my spline into several pieces, then rail extrude each one separately. Most of the time it works quite well, just a little cut and paste action.

Mmmmmm, paste action...

05-11-2006, 05:13 PM
Recently I was thinking about how nice it would be to be able to edit the spline "after" extruding, and have it affect the extruded geometry. I always have to completly redo the process when only something minor needs changing.
It would be great if Newtek could get this kind of thing going, which is a fundamental feature of a competitor who shall remain nameless (and less cool.) I bet they'll work it out in a verions or two, it would seriously change the whole package.

05-11-2006, 05:16 PM
sometimes using more then one spline can help (a multirail extrude)
Also I would check out some of the tools by Pictrix.

05-11-2006, 06:01 PM
I tried selecting the curve and removing polygons, to get it back to just the points. Then I selected the points in order and then used the Construct > Curves > From Points. But it is still doing it. Either the points have some other parameter besides X,Y,Z, such as their version of a "normal" like polys have, or there is a bug in the rail extrude that rotates the object being extruded as it follows the curve.

Doing it in sections doesn't help. As the object is being extruded and follows the curve side to side and up and down the object slowly spins around the center of the curve. By the time it gets all the way around the path back to the start point it has rotated about 400 something degrees around the center axis of the curve.

I could certainly use this "effect" in what I'm trying to create, if it were controllable. But I can't see any way to orient a point without changing it's x/y/z position. Or to tell the rail extrude to orient to the x,y,z of the curve, but not to spin the object around the center axis of the curve.

For those still not getting what I'm describing, imagine a train following train tracks. As the train follows the track up and down and left to right, the roof of the train is always "up". When I rail extrude, my "train car" is ending up on it's side, upside down, etc... as it follows the curve. But I'm not animating a train along tracks, I'm trying to create a shape and want the shape to stay right side up as it follows the curve.

05-11-2006, 06:41 PM
are you extruding along one or two splines?

05-11-2006, 09:12 PM
One. I thought if you add other curves it uses those other ones to modify the shape of the extrusion.

05-11-2006, 09:22 PM
It can do that but wont if scaling is turned off or turned down. :)
If both are parallel you shouldnt have the twisting problems

05-12-2006, 05:22 PM
You are indeed the Spline God.

Thanks. It works great.

05-12-2006, 09:55 PM
Cool! :)

05-13-2006, 07:54 AM
Hmmm... Well, that other one worked well, but just tried a different one with much tighter curves and it didn't work right. It seemed like the second curve caused the "oriented" to not work in the axis that the copy of the curve was in.

In other words, the copy of the curve was raised up from the original curve, and while the original shape being extruded did follow the curve left and right as if went around in a circle, it didn't seem to tilt it up and down as the curve went up/down. This ended up making a "tube" that doesn't have even thickness, but was flattened out on parts of the curve. Without the copy the extrusion gives a uniform thickness, but like before the start and end don't match so there is a distortion where the start and end meet.

Would this be an issue because this new one has much tighter curves? The first one had twice as many points going around each direction change within the curve, while this one has sharper turns.

05-13-2006, 09:29 AM
OK, I went back to the original curve, and on closer examination this problem is there too. I was so intent at looking at the fact that it was no longer spiraling around the curve I didn't notice that the thickness was being distorted by the object being extruded no longer orienting correctly to the curve. Crap!

05-13-2006, 10:18 AM
OK. Success (I think). Rather than raise the copy of the curve above the first one I scaled it larger so it surrounds the original curve. That seems to have worked. The object being extruded now orients correctly in all axis as it follows the curve.


I need to study it closely, but from what I can see it is working now exactly like I was expecting it to do in the first place before adding a second curve at all.

Thanks again for pointing me in the right direction.

05-13-2006, 01:07 PM
Do you have a pic of what youre trying to do?

05-15-2006, 07:30 AM
I'm creating various types of braiding by extruding one path and then placing 3 copies of the result offset from each other.

Still having problems. I tried a different one yesterday extruding a flat shape in a more linear path and I can't get it to remain parallel to the "ground". It may have been a fluke of the first shape that I was able to get it to orient correctly.

05-15-2006, 08:52 AM
I've always wished Rail Extrude could extrude down 2-point poly chains. Currently you can't do straight-edged extrudes (over more than two points).

05-15-2006, 04:41 PM
Do you have a picture of your rails?

05-15-2006, 05:00 PM
For the first pic I used two curves. The one being followed looks exactly like the pink part of the image, or at least like a line going through the center of the pink ring. The second curve was a copy of that one stretched outward 110% so it is surrounding the ring. The other two colors were just copies of the pink one and just rotated 10 and 20 degrees.

For the second pic, imagine a line going directly through the center of that shape. On that one, each attempt at adding a second curve caused the shape to distort, and the object being extruded no longer oriented itself as it went around the path. In fact there was no difference with or without the "oriented" checkbox checked.

Scaling was turned off in each case involving more than one curve.

I'm using LW 7.5, in case that makes a difference.

05-15-2006, 06:40 PM
Would be nice if you could limit the influence of a Rail Extrude to certain axis, e.g. if you had a curve going all over the place but switched off the Y axis, it would just ignore any Y influence the underlying curve had on the extrude.

That would solve twisting issues!

05-16-2006, 07:28 AM
Or if the points used in the curve had the equivalent of a "normal" so you could point them in whatever direction you wanted the extrusion to twist as it follows the curve.

05-16-2006, 11:29 AM
I would also check out the various tools from Pictrix. Great stuff! :)