Hey guys,
Sorry I haven't posted for a while, but I've been really busy. Anyways, I'm having some trouble with mathematically-generated lines. I'm using a system of bezier lines of which the user can manipulate, and therefore change the lines. The lines are constantly being redrawn on screen (every loop), so that whenever the user moves a point or a handle, the changes are reflected on screen. However, what I'd like to do is draw a second and a third line which are exact copies of the first line just enlarged or shrunk. So that instead of the user just seeing a line between the points (like so: | ), they would see a sort of road or track between the points (like so: ||| ). I'm just having trouble enlarging and shrinking the lines. I've tried scaling the points like a normal geometric figure by simply multiplying the points by 2 and 0.5. However this obviously didn't work. I tried simply adding and subtracting 5 from the X, Y, and Z coordinates. That didn't work either. Then I got some advice from someone. They basically said "for each point along the bezier line, you first generate a local coordinate system based on the direction at that point. Then you have a function that takes a coordinate in that local system and turns it into a global coordinate. You can generate this local coordinate system by using matrices." Well I'm just having lots and lots of problems with... well everything! If you have ANY ideas, I'd be happy to hear them. I've been TOTALLY stumped on this problem for a few weeks.
Thanks a lot,
Nick Small.
Lightning Wheels-Ultimate Roller Coaster Simulator