David Megginson <[EMAIL PROTECTED]> said:

> Jim Wilson writes:
> 
>  > Actually, no, well yes this is a good idea.  But I don't think it is
>  > necessary.  AFAIK the model rotates correctly already.
> 
> The FDMs give us lon/lat/alt and roll/pitch/hdg.  FlightGear then has
> to apply transformations to make the model appear in the right place
> and with the right orientation.  After reading your posting, I'm
> trying to remember how, exactly, we do that -- I'm willing to be that
> we just rotate the model around the origin by the roll, pitch, and
> heading.  That means that the view from inside will be wrong as well,
> especially in a big plane.
> 

Those position and orientation values are used to transform and rotate the
camera.  Here is a detailed description of what happens...extreme example (I'm
thinking I did this once before :-)):

1) You are in chase view looking at the aircraft in flight from the side, a
profile view.

2) The "origin" is set to the nose of the aircraft.

3) The aircraft model itself already rotates correctly about its c.g. even
with the origin at the nose.

4) When you pitch down, the nose decreases in altitude by anywhere from a half
to several meters depending on the aircraft and the degree of pitch down.

5) Since the camera is tied to the origin it always decreases in altitude
equal to the nose.

6) This has the effect of making it look like the nose is stationary and the
rest of the plane is wagging behind it (like a dog's tail).

This same effect is less or more depending on exactly where the "origin" is. 
We could eliminate it by offseting the lon/lat/alt and roll/pitch/hdg to the
current center of gravity for the camera,  but that isn't necessary.  It'll
look good enough (you can't visually see the error) if the origin is just
placed in a reasonable approximate location.

Best,

Jim

_______________________________________________
Flightgear-devel mailing list
[EMAIL PROTECTED]
http://mail.flightgear.org/mailman/listinfo/flightgear-devel

Reply via email to