#include "views.hxx"
-extern int displayInstruments;
-
-
/* Handle keyboard events */
void GLUTkey(unsigned char k, int x, int y) {
fgCONTROLS *c;
t->warp_delta -= 30;
return;
case 87: /* W key */
- displayInstruments = !displayInstruments;
+ o->panel_status = !(o->panel_status);
return;
case 88: /* X key */
o->fov *= 1.05;
/* $Log$
-/* Revision 1.12 1998/06/12 14:27:26 curt
-/* Pui -> PUI, Gui -> GUI.
+/* Revision 1.13 1998/06/27 16:54:32 curt
+/* Replaced "extern displayInstruments" with a entry in fgOPTIONS.
+/* Don't change the view port when displaying the panel.
/*
+ * Revision 1.12 1998/06/12 14:27:26 curt
+ * Pui -> PUI, Gui -> GUI.
+ *
* Revision 1.11 1998/06/12 00:57:38 curt
* Added support for Pui/Gui.
* Converted fog to GL_FOG_EXP2.
// Another hack
int use_signals = 0;
-// Yet another other hack. Used for my prototype instrument code. (Durk)
-int displayInstruments;
-
// Global structures for the Audio library
#ifdef HAVE_AUDIO_SUPPORT
slScheduler audio_sched ( 8000 ) ;
v->Update(f);
v->UpdateWorldToEye(f);
- if (displayInstruments) {
- xglViewport( 0, (GLint)((v->winHeight) / 2 ) ,
- (GLint)(v->winWidth), (GLint)(v->winHeight) / 2 );
- // Tell GL we are about to modify the projection parameters
- xglMatrixMode(GL_PROJECTION);
- xglLoadIdentity();
- gluPerspective(o->fov, v->win_ratio / 2.0, 1.0, 100000.0);
- } else {
- xglViewport(0, 0 , (GLint)(v->winWidth), (GLint)(v->winHeight) );
- // Tell GL we are about to modify the projection parameters
- xglMatrixMode(GL_PROJECTION);
- xglLoadIdentity();
- gluPerspective(o->fov, v->win_ratio, 10.0, 100000.0);
- }
+ // if (!o->panel_status) {
+ // xglViewport( 0, (GLint)((v->winHeight) / 2 ) ,
+ // (GLint)(v->winWidth), (GLint)(v->winHeight) / 2 );
+ // Tell GL we are about to modify the projection parameters
+ // xglMatrixMode(GL_PROJECTION);
+ // xglLoadIdentity();
+ // gluPerspective(o->fov, v->win_ratio / 2.0, 1.0, 100000.0);
+ // } else {
+ xglViewport(0, 0 , (GLint)(v->winWidth), (GLint)(v->winHeight) );
+ // Tell GL we are about to modify the projection parameters
+ xglMatrixMode(GL_PROJECTION);
+ xglLoadIdentity();
+ gluPerspective(o->fov, v->win_ratio, 10.0, 100000.0);
+ // }
xglMatrixMode(GL_MODELVIEW);
xglLoadIdentity();
}
+#ifdef 0
// Draw a basic instrument panel
static void fgUpdateInstrViewParams( void ) {
+
+ exit(0);
+
fgVIEW *v;
v = ¤t_view;
xglMatrixMode(GL_MODELVIEW);
xglPopMatrix();
}
+#endif
// Update all Visuals (redraws anything graphics related)
xglDisable( GL_TEXTURE_2D );
- // display HUD
- if( o->hud_status ) {
- fgCockpitUpdate();
- }
+ // display HUD && Panel
+ fgCockpitUpdate();
// display instruments
- if (displayInstruments) {
- fgUpdateInstrViewParams();
- }
+ // if (!o->panel_status) {
+ // fgUpdateInstrViewParams();
+ // }
puDisplay();
xglutSwapBuffers();
}
// $Log$
+// Revision 1.28 1998/06/27 16:54:32 curt
+// Replaced "extern displayInstruments" with a entry in fgOPTIONS.
+// Don't change the view port when displaying the panel.
+//
// Revision 1.27 1998/06/17 21:35:10 curt
// Refined conditional audio support compilation.
// Moved texture parameter setup calls to ../Scenery/materials.cxx
#include "options.hxx"
#include "views.hxx"
-// extern int show_hud; // HUD state
-extern int displayInstruments;
+
extern const char *default_root;
fgFlightModelInit( FG_LARCSIM, f, 1.0 / DEFAULT_MODEL_HZ );
- // Let's not show the instrument panel
- displayInstruments = 0;
-
// Joystick support
if (fgJoystickInit(0) ) {
// Joystick initialized ok.
// $Log$
+// Revision 1.21 1998/06/27 16:54:33 curt
+// Replaced "extern displayInstruments" with a entry in fgOPTIONS.
+// Don't change the view port when displaying the panel.
+//
// Revision 1.20 1998/06/17 21:35:12 curt
// Refined conditional audio support compilation.
// Moved texture parameter setup calls to ../Scenery/materials.cxx