2002-04-05 03:19:34 +00:00
|
|
|
// model.hxx - manage a 3D aircraft model.
|
|
|
|
// Written by David Megginson, started 2002.
|
|
|
|
//
|
|
|
|
// This file is in the Public Domain, and comes with no warranty.
|
|
|
|
|
|
|
|
#ifndef __ACMODEL_HXX
|
|
|
|
#define __ACMODEL_HXX 1
|
|
|
|
|
|
|
|
#ifndef __cplusplus
|
|
|
|
# error This library requires C++
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#include <vector>
|
|
|
|
|
|
|
|
SG_USING_STD(string);
|
|
|
|
SG_USING_STD(vector);
|
|
|
|
|
|
|
|
#include <simgear/misc/props.hxx>
|
|
|
|
|
|
|
|
#include <Main/fgfs.hxx>
|
|
|
|
|
|
|
|
#include "model.hxx"
|
|
|
|
|
|
|
|
|
|
|
|
class FGAircraftModel : public FGSubsystem
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
|
|
|
|
FGAircraftModel ();
|
|
|
|
virtual ~FGAircraftModel ();
|
|
|
|
|
|
|
|
virtual void init ();
|
|
|
|
virtual void bind ();
|
|
|
|
virtual void unbind ();
|
|
|
|
virtual void update (int dt);
|
2002-04-11 04:25:30 +00:00
|
|
|
virtual void draw ();
|
|
|
|
virtual FG3DModel * get3DModel() { return _aircraft; }
|
2002-04-05 03:19:34 +00:00
|
|
|
|
|
|
|
private:
|
|
|
|
|
|
|
|
FG3DModel * _aircraft;
|
2002-04-09 21:08:28 +00:00
|
|
|
ssgRoot * _scene;
|
|
|
|
float _nearplane;
|
|
|
|
float _farplane;
|
2002-04-05 03:19:34 +00:00
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif // __ACMODEL_HXX
|
|
|
|
|
2002-04-11 04:25:30 +00:00
|
|
|
|