[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.gef3d] Re: interpolated animation

Hi Miles,

On 2009-06-16 01:17:16 +0200, Miles Parker <milesparker@xxxxxxxxx> said:

OK, this is waaay out on the "some day would be nice" frontier, but I'm wondering if there is any way to get animation for figures that have moved between refreshes, ala GEF. (Actyually, I haven't had great success getting this to work there anyway.)

Since GEF3D uses the very same update mechanisms as GEF, GEF animations should work similarly as well. SO you may start with a GEF animation and then try the very same animation in a 3D-fied editor.


We have already camera animation working, simply by using a Timer and a TimerTask. The camera is then simply moved like that:

@Override

public void run() {

	final Vector3fImpl newPos = new Vector3fImpl();

	Math3D.add(camera.getPosition(null), delta, newPos);

	Display.getDefault().asyncExec(new Runnable(){

		public void run(){

			camera.moveTo(newPos.x, newPos.y, newPos.z);

		}});

}

But this is a special case an the camera is a concept not known in GEF.

Cheers,

Jens