View previous topic :: View next topic |
Author |
Message |
paul_nicholls DeleD PRO user
Joined: 05 Dec 2007 Posts: 356 Location: Hobart, Tasmania, Australia
|
Posted: Fri Jan 22, 2010 12:56 am Post subject: curved (spline) path primitives tracker item thoughts |
|
|
I am having a think about this item I added:
https://sourceforge.net/tracker/?func=detail&aid=2934744&group_id=293758&atid=1241130
and had some questions for you all while I'm nutting out some ideas in this area.
I'm not sure which way to go with this.
I have a few different splines I could include here.
Out of this list:
http://www.blackpawn.com/texts/splines/
I was thinking cubic bezier and catmull-rom as the two major contenders.
a) cubic bezier - has separate control points aside from the path vertices.
b) catmull rom - the only control points are the path vertices themselves.
I could do this with the splines when creating them:
a) have multiple different spline types that you can select, eg. catmull rom, cubic bezier from the create list.
b) have 1 spline type that you can select from the create list, but with the options to use one of the different spline types when actually creating the spline.
So there would in actuallity be multiple spline path types, but expressed differently at the creation stage...
I hope this makes sense?
Any thoughts?
cheers,
Paul _________________ Long live DeleD!
Hi ho...hi ho...it's off 3d modeling I go... |
|
Back to top |
|
|
chronozphere DeleD PRO user
Joined: 20 Jun 2006 Posts: 1010 Location: Netherlands
|
Posted: Fri Jan 22, 2010 8:40 am Post subject: |
|
|
IMHO we should add a single spline item in the "create" section, which lets you create multiple types of splines (New types could be introduced in the future). This will keep the creation panel clean.
I am looking forward to cubic bezier splines because as you said, they are more "controllable". On the other hand, we need a new kind of "gizmo" to manipulate splines. I'm talking about a line with two handles, show in any 2D view. Like this:
It's unclear to me how to add gizmo's to DeleD. Furthermore we need to figure out how we can combine such a gizmo with the existing DeleD tools (move, rotate etc).
I would like to invest some time in this feature because my games will probably benefit from it.
This will probably a lot of work. We first need to document the important bits of the source and discuss these things with Jeroen and PJ.
Just my 2 cents. |
|
Back to top |
|
|
paul_nicholls DeleD PRO user
Joined: 05 Dec 2007 Posts: 356 Location: Hobart, Tasmania, Australia
|
Posted: Fri Jan 22, 2010 9:02 am Post subject: |
|
|
chronozphere wrote: |
IMHO we should add a single spline item in the "create" section, which lets you create multiple types of splines (New types could be introduced in the future). This will keep the creation panel clean. |
I agree, this would keep the panel cleaner
chronozphere wrote: |
I am looking forward to cubic bezier splines because as you said, they are more "controllable". On the other hand, we need a new kind of "gizmo" to manipulate splines. I'm talking about a line with two handles, show in any 2D view. Like this:
|
Exactly my thoughts too about the flexibility of cubic bezier splines
Nice diagrams, BTW...very informative - just what we need.
I'm not sure if we need new gizmo's for this though...I figure that if we just manipulate the control points as normal vertices with the usual operators, then the spline(s) will automatically change shape to follow...
chronozphere wrote: |
It's unclear to me how to add gizmo's to DeleD. Furthermore we need to figure out how we can combine such a gizmo with the existing DeleD tools (move, rotate etc).
I would like to invest some time in this feature because my games will probably benefit from it.
This will probably a lot of work. We first need to document the important bits of the source and discuss these things with Jeroen and PJ.
Just my 2 cents. |
Well, your 2 cents are worth lots
BTW, you are right, this WILL be a lot of work - I have had a bit of a fiddle with trying to add in a simple path primitive to DeleD, and THIS is quite a bit of work!
I STILL haven't figured out all the bits I need to alter yet LOL
Mind you, in the long run, it will make DeleD so MUCH more 'valuable' as a viable tool for more people.
cheers,
Paul _________________ Long live DeleD!
Hi ho...hi ho...it's off 3d modeling I go... |
|
Back to top |
|
|
chronozphere DeleD PRO user
Joined: 20 Jun 2006 Posts: 1010 Location: Netherlands
|
Posted: Fri Jan 22, 2010 9:13 am Post subject: |
|
|
Quote: |
I'm not sure if we need new gizmo's for this though...I figure that if we just manipulate the control points as normal vertices with the usual operators, then the spline(s) will automatically change shape to follow...
|
Beware that you don't want to mix up "real geometry" with this kind of helper geometry. The advantage of having gizmo's is that they can look different from geometry, which makes them easier to recognize and use.
Maybe we should add more abstraction to DeleD. We could let some tools manipulate an abstract structure that can either be real geometry or a gizmo. This will need some good thought.
Can you elaborate on using vertices for this task? |
|
Back to top |
|
|
paul_nicholls DeleD PRO user
Joined: 05 Dec 2007 Posts: 356 Location: Hobart, Tasmania, Australia
|
Posted: Fri Jan 22, 2010 10:29 am Post subject: |
|
|
chronozphere wrote: |
paul_nicholls wrote: |
I'm not sure if we need new gizmo's for this though...I figure that if we just manipulate the control points as normal vertices with the usual operators, then the spline(s) will automatically change shape to follow...
|
Beware that you don't want to mix up "real geometry" with this kind of helper geometry. The advantage of having gizmo's is that they can look different from geometry, which makes them easier to recognize and use.
Maybe we should add more abstraction to DeleD. We could let some tools manipulate an abstract structure that can either be real geometry or a gizmo. This will need some good thought.
Can you elaborate on using vertices for this task? |
Ok, those are very good points you make there about gismo's vs real geometry
I was thinking that the control points of the splines would of course be part of the spline class, but stored as vertices and also the spline class would know how to recalculate the curve data after the vertices are moved.
Maybe I'm rambling on a bit here, and this isn't even practical to do... LOL
I suppose I could do bit of a small experiment or similar with the code to see what I could do...
cheers,
Paul _________________ Long live DeleD!
Hi ho...hi ho...it's off 3d modeling I go... |
|
Back to top |
|
|
chronozphere DeleD PRO user
Joined: 20 Jun 2006 Posts: 1010 Location: Netherlands
|
Posted: Fri Jan 22, 2010 12:38 pm Post subject: |
|
|
I have another idea. We could add "up-vectors" to each control point of our spline. This will make the spline more usable. For example:
- You can use the spline as camera path, and use the upvector to turn the camera upside-down during the path.
- You can extrude a polygon along the spline and make it twist by rotating the upvectors.
The reason I'm saying this, is that my next TubeRunner game will probably need this data too. |
|
Back to top |
|
|
paul_nicholls DeleD PRO user
Joined: 05 Dec 2007 Posts: 356 Location: Hobart, Tasmania, Australia
|
Posted: Sat Jan 23, 2010 4:10 am Post subject: |
|
|
Sounds like a very good idea, having 'up vectors' as part of the spline vertices
cheers,
Paul _________________ Long live DeleD!
Hi ho...hi ho...it's off 3d modeling I go... |
|
Back to top |
|
|
|