PDA

View Full Version : polygon keyframe animation with interpolation?



noeska
23-08-2009, 03:40 PM
On thinking on the possibilties of adding keyframe animation the following options came to mind, but none are good enough in my opinion:

Keyframe animation should be stored as as an array consisting of framnumberid and a glvgobject(read polygon shape).

1)
Render the apropriate glvg object accoriding to its framenumberid and the current frame. Animation can become jumpy going from one shape to another at once. Each frame is tesselated(triangulated) in advance.

2)
vertex interpolation: is not going to be possible as each glvgobject may be composed of a different number of vertexes and even their order may vary.

3)
polygon interpolation: each intermediate glvgObjects needs to be tesselated realtime. Could mean major slowdown on complex glvgObjects.

4)
precalculated polygon interpolation: All intermediate glvgObjects need to be interpolated and tesselated in advance. Could clog up lots of memory for long animation sequences.

5)
geometry shaders? Don't know anything about them and i would like to support older hardware.

6)
Are there other clever ways to do this?

Thanks for your help and answers in advance.

JSoftware
23-08-2009, 05:20 PM
I don't understand what you try to accomplish. Do you tesselate models before rendering them? That'll make keyframe animation close to impossible unless you use some sort of skinning method. That's effectively morphing geometry which is pretty hard

I would just use keyframe animation on vertex group basis and then interpolate, and then tesselate afterwards if it's necessary

noeska
23-08-2009, 08:15 PM
i have a 2d vector graphics unit called glvg.
all shapes consists of paths made of line, qsplines and csplines.
those paths are tesselated(triangulated) before rendering. And you can force it to tesselate earlier e.g. after construction so it is already tesselated on rendering. E.g. the render is stupid and just renders a bunch of triangles.
I use glutess to do the tesselation.
For as far as i know only option 1 is possible.