]> git.mxchange.org Git - flightgear.git/blobdiff - Main/views.hxx
C++-ifying.
[flightgear.git] / Main / views.hxx
index 77acb063c6c220b29c40c7a366e8a421eef922d0..22b5f1c5f03e759c3e114ead0deb3b8253aee8cb 100644 (file)
@@ -1,4 +1,3 @@
-//
 // views.hxx -- data structures and routines for managing and view parameters.
 //
 // Written by Curtis Olson, started August 1997.
 #endif                                   
 
 
-#include <Include/fg_types.h>
-#include <Flight/flight.h>
+#include <Flight/flight.hxx>
 #include <Math/mat3.h>
+#include <Math/point3d.hxx>
 #include <Time/fg_time.hxx>
 #include <Time/light.hxx>
 
 #include "options.hxx"
 
-#ifndef BOOL
-#define BOOL int
-#endif
 
-#ifndef TRUE
-#define FALSE 0
-#define TRUE 1
-#endif
+// used in views.cxx and tilemgr.cxx
+#define USE_FAST_FOV_CLIP 
+
 
 // Define a structure containing view information
 class fgVIEW {
@@ -61,7 +56,7 @@ public:
     double goal_view_offset;
 
     // flag forcing update of fov related stuff
-    BOOL update_fov;
+    bool update_fov;
        
     // fov of view is specified in the y direction, win_ratio is used to
     // calculate the fov in the X direction = width/height
@@ -83,6 +78,10 @@ public:
     // slope of view frustum edge in eye space X axis
     double slope_x;
 
+#if defined( USE_FAST_FOV_CLIP )
+    double fov_x_clip, fov_y_clip;
+#endif // USE_FAST_FOV_CLIP
+
     // View frustum cull ratio (% of tiles culled ... used for
     // reporting purposes)
     double vfc_ratio;
@@ -91,14 +90,14 @@ public:
     int tris_rendered;
 
     // absolute view position
-    fgPoint3d abs_view_pos;
+    Point3D abs_view_pos;
 
     // view position translated to scenery.center
-    fgPoint3d view_pos;
+    Point3D view_pos;
 
     // cartesion coordinates of current lon/lat if at sea level
     // translated to scenery.center*/
-    fgPoint3d cur_zero_elev;
+    Point3D cur_zero_elev;
 
     // vector in cartesian coordinates from current position to the
     // postion on the earth's surface the sun is directly over
@@ -181,6 +180,15 @@ extern fgVIEW current_view;
 
 
 // $Log$
+// Revision 1.15  1998/10/16 23:27:56  curt
+// C++-ifying.
+//
+// Revision 1.14  1998/10/16 00:54:04  curt
+// Converted to Point3D class.
+//
+// Revision 1.13  1998/09/08 15:04:36  curt
+// Optimizations by Norman Vine.
+//
 // Revision 1.12  1998/08/24 20:11:15  curt
 // Added i/I to toggle full vs. minimal HUD.
 // Added a --hud-tris vs --hud-culled option.