Howto:3D Aircraft Models: Difference between revisions

m
images added
mNo edit summary
m (images added)
Line 10: Line 10:
* roll is a rotation around the x-axis, where positive is clockwise viewed from behind  
* roll is a rotation around the x-axis, where positive is clockwise viewed from behind  


===Loading the model===
[[Image:heading.jpg|200px]][[Image:pitch.jpg|200px]][[Image:roll.jpg|200px]]
 
==Loading the model==
Through plib, FlightGear supports many different 3D file formats, including VRML1, AC3D, DXF, MDL (from Microsoft Flight Simulator), and many others. The property /sim/model/path in the main FlightGear property tree controls what model will be loaded; it takes a string value giving the relative path of the model from FG_ROOT (the root of the base package, such as /usr/local/share/FlightGear or C:\FLIGHTGEAR\).
Through plib, FlightGear supports many different 3D file formats, including VRML1, AC3D, DXF, MDL (from Microsoft Flight Simulator), and many others. The property /sim/model/path in the main FlightGear property tree controls what model will be loaded; it takes a string value giving the relative path of the model from FG_ROOT (the root of the base package, such as /usr/local/share/FlightGear or C:\FLIGHTGEAR\).


Line 55: Line 57:
  </PropertyList>
  </PropertyList>


===Repositioning the Model===
==Repositioning the Model==
Often, an aircraft model not designed specifically for FlightGear will not be positioned or oriented correctly; for example, it might be too far off the ground, and the nose might point to the side or even straight up.
Often, an aircraft model not designed specifically for FlightGear will not be positioned or oriented correctly; for example, it might be too far off the ground, and the nose might point to the side or even straight up.


Line 88: Line 90:
It usually takes a bit of experimentation to get the model positioned correctly.
It usually takes a bit of experimentation to get the model positioned correctly.


===Animating the Model===
==Animating the Model==
Now for the interesting part. FlightGear allows you to animate models by having parts rotate or spin in response to property changes: for example, the propellers can spin when the engine is on and the elevators can move up and down with your controller. There is no fixed limit on what parts can be animated: the only requirements are that the part is named in the 3D model file, and that there is a property in the main tree that you can use to get the positioning information.
Now for the interesting part. FlightGear allows you to animate models by having parts rotate or spin in response to property changes: for example, the propellers can spin when the engine is on and the elevators can move up and down with your controller. There is no fixed limit on what parts can be animated: the only requirements are that the part is named in the 3D model file, and that there is a property in the main tree that you can use to get the positioning information.