Page 1 of 2

3D real world trajectories, balistics etc

PostPosted: May 12, 2003 @ 4:32pm
by Conan
Does anyone have any links to good articles covering movement in 3D. Up till now I have been moving objects (player's ship moving through a planetary system) under player control & this works fine but I just coded a space probe moving in an arc and though the end result looks fine it's just a 'hatchet job' of hard coded values which get the probe to move as required. As I have to program the 'AI' of alien ships moving around in space I need to learn more than I know.

thanks in advance

PostPosted: May 12, 2003 @ 5:15pm
by Dan East

thanks for the pointers

PostPosted: May 12, 2003 @ 5:59pm
by Conan

PostPosted: May 12, 2003 @ 8:23pm
by angedelamort
Dan, did you try the V-Clip algorith.



It's a really interesting way of collision detection.

vector search gave results

PostPosted: May 15, 2003 @ 11:13am
by Conan

PostPosted: May 15, 2003 @ 3:10pm
by Dan East

PostPosted: May 16, 2003 @ 1:57pm
by ChezDoodles
Quaternions are still not to be dismissed, though.

They are more compact, using just four values, where as a 3x3 matrix takes nine values to store the same information - an important factor for low-bandwidth network traffic - or if you want to store a large number of animation data on a limited device like phone.

Also, some operations (not all!) are just more easy to do with Quaternions.

PostPosted: May 17, 2003 @ 4:47am
by Velo
Eberly sums up the performance issues surrounding matrix vs. quaternion pretty well in this paper in my opinion -


The executive summary is that quaternions are good for interpolation, matrices are good for transforming vectors. You have to convert a quaternion to a matrix in order to transform a vector anyhow, so having a matrix around is going to win in that case. However, if you're in a situation where you need to concatenate multiple orientations in order to get to the matrix you need, then quaternions are going to be a big win since they typically (unless you're on a nice simd processor) take significantly fewer operations to interpolate than matrices.

As far as general physics goes, I thought this was a pretty good book to get started with -

thanks for the link

PostPosted: May 17, 2003 @ 8:23am
by Conan
I will read the sample chapter on projectiles before I think about the book. I have too many books which do nothing on my shelf & they are not cheap in the UK.

Wonder what I would get for 'Super VGA Graphics' on e-bay. Tells you all about the state of the art 10 years ago.

PostPosted: May 17, 2003 @ 7:01pm
by RICoder
I'd suggest quaternions if you are looking for realistic physics, and matrices if you are looking to 'fake' it. Keep in mind that most physics engines don't do real world physics, the fake it. I've written a few of different engines in everything from C++ to Prolog, and what I discovered is that anything above and beyond angular momentum gets very hairy very fast.

There are a lot of good books out there, but nothing that will help more than a college level Newtonian Physics book. I have to side with Dan here and say that I found that doing it myself, while a major pain in the ass, was no more difficult than trying to interpret what someone else did in a book.

PostPosted: May 17, 2003 @ 7:59pm
by Dan East

PostPosted: May 17, 2003 @ 8:11pm
by RICoder
That's an interesting way of looking at it.

I think a lot of this depends on what you are looking at for optimizations and the number of times a 'thing' is going to pass through the engine per cycle. I suppose that in the end it is going to come down to what you need to do with the information anyway, since you are not going to want to translate from one to the other and back again every clock tick.

PostPosted: Jun 21, 2003 @ 5:10am
by Dan East

PostPosted: Jun 21, 2003 @ 9:18am
by refractor

PostPosted: Jun 21, 2003 @ 12:55pm
by Dan East