Birger Brunswiek said:

> I'm trying to create a new view which is supposed to be a camera
> fixed under the Cesna at the body. So far it looks like this:
> <view>
>    <name>Camera View</camera>
>    <internal type="bool">false</internal>
>    <config>
>      <from-model type="bool">true</from-model>
>      <from-model-idx type="int">0</from-model>
>      <ground-level-nearplane-m type="double">0.2f</ground-level-nearplane-m>
>      <x-offset type="double">0<x-offset>
>      <y-offset type="double">-1<y-offset>
>      <z-offset type="double">0<z-offset>
>    </config>
> </view>
> 
> So far so good... now I'm trying to change the pitch and heading defaults
> of that camera. I've tried <eye-*-*-path> and <default-*-deg> but none of those
> seems to have any effect...
> What am I doing wrong?
> 
> Birger

I'm not sure if this was answered or not...been out of the loop for while now.
 You needed to specify this as a "lookfrom" view type (similar to cockpit
view).  Then you sould be able to specify offsets (e.g. pitch-offset-deg,
heading-offset-deg) which will affect the direction of the camera.

As far as your question goes, my guess is you have misunderstood the purpose
of the eye path settings.  These just specify where in the property tree the
value for position or atitude of the camera (or eye) is stored.  In this case
you don't need that.  Just use from-model-idx number 0 as you have.  This
indicates the position and attitude data is retrieved from the same location
as the primary FDM's 3D Model Location (e.g. /orientation /position).

In other words, this camera "eye" location and atitude is the same as "fdm"
location and atitude, because it is attached to the aircraft.  You only need
some small adjustments to "offset" the camera from the origin of the FDM (and
3D Model).   The x/y/z-offset-m properties are for adjusting the location down
to the desired location below the aircraft.   Looks like you got that.  The
pitch/roll/heading-offset-deg are for making the camera point to a direction
different than the aircraft is pointing.   Straight down would be 90.0 (or
maybe -90.0) pitch-offset-deg.  Note, you will probably want to make that 89
degrees or some value not quite 90.0 because of the singularity issue that we
run into with the matrix methods.

Best,

Jim


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

Reply via email to