Main Page | Namespace List | Class List | File List | Class Members | File Members

config.cpp

Go to the documentation of this file.
00001 #include "config.h"
00002 
00003 bool day = false;
00004 
00005 // Number of tiles per texture
00006 int g_tpt = 10;
00007 
00008 #define _g_tpt 10
00009 
00010 // Texture coord array
00011 float g_texcoord[ 2*_g_tpt ];
00012 
00013 bool g_bBlending = true;
00014 bool g_bSmoothing = true;
00015 
00016 // Height of the water surface [0-1, percentage of height field height]
00017 const float g_waterlevel = 0.5f;
00018 // Scaling of the water surface height
00019 const float g_fWaterScale = 3.0f;
00020 
00021 bool g_bFresnel = true;
00022 
00023 bool draw_fog = true;
00024 
00025 bool draw_mirror_plane = true;
00026 bool draw_mirror = true;
00027 
00028 bool draw_height_field = true;
00029 
00030 bool g_CameraRotateLeft = false, g_CameraRotateRight = false;
00031 bool g_CameraRotateDown = false, g_CameraRotateUp = false;
00032 float g_CameraAngleX=0, g_CameraAngleY = 0;
00033 
00034 float g_length = 12.0f;
00035 
00036 float g_CameraX=0, g_CameraY = 0, g_CameraZ = g_length; //2 meters
00037 
00038 float g_MirrorX = 10, g_MirrorY = 60, g_MirrorZ = 10;
00039 
00040 
00041 bool g_show_axis = false;
00042 
00043 // Base resource directory
00044 const char *g_strResourceDir = "./render/resource/";
00045 
00046 // Height field width
00047 int g_hfW = 1024;
00048 // Height field height
00049 int g_hfH = 1024;
00050 // Height field filename
00051 const char *g_strHeightFieldFile = "hf.raw_1024x1024_bw_float";
00052 
00053 
00054 
00055 // Scaling of the height field
00056 float g_fHeightScale = 10.0f;
00057 
00058 
00059 
00060 // Draw style flags
00061 bool g_bLighting = true;
00062 bool g_bFrameRate = true;
00063 
00064 
00065 
00066 // Parameters
00067 // Size which a cell occupies in the XY plane
00068 int g_cellsize = 1;
00069 // Number of cells visible from the plane in each direction
00070 int g_cells = 80;
00071 
00072 // Height of the plane over ground
00073 float g_fHeight = 20.0f;
00074 
00075 // Position of "sun"
00076 //      For this particular demo the selected Sun position
00077 //       is very good due to horror performance (when light 
00078 //       comes from the earth.
00079 float g_lightPos[4] = { 30, -30, 30, 0 };
00080 float g_lightPos2[4] = { 0, 0, 0, 0 };
00081 
00082 // Time after which the scene is redrawn (in ms)
00083 int g_nTimerDelay = 50;
00084 
00085 
00086 // Some colors
00087 const float colorWhite[4]       = { 1.0, 1.0, 1.0, 1.0 };
00088 const float colorBlue[4]        = { 0,0,1,1 };
00089 const float colorRed[4]         = { 1,0,0,1 };
00090 const float colorYellow[4]      = { 1,1,0,1 };
00091 const float colorGreen[4]       = { 0.0, 1, 0.0, 1.0 };
00092 const float colorDarkGreen[4]   = { 0.0, 0.5, 0.0, 1.0 };
00093 const float colorVeryLightGreen[4]  = { 0.0, 0.9, 0.0, 1.0 };
00094 const float colorLightGreen[4]  = { 0.0, 0.8, 0.0, 1.0 };
00095 const float colorWaterGreen[4]  = { 0.0, 0.3, 0.2, 1.0 };
00096 const float colorNone[4]        = { 0.0, 0.0, 0.0, 0.0 };
00097 const float colorDarkGrey[4]    = { 0.2, 0.2, 0.2, 0.0 };
00098 const float colorDarkYellow[4]  = { 0.6, 0.6, 0.0, 0.0 };
00099 const float colorDarkRed[4]     = { 0.5, 0.0, 0.0, 0.0 };
00100 const float colorDarkBrown[4]   = { 0.5, 0.3, 0.0, 0.0 };
00101 const float colorSky[4]         = { 0.3, 0.4, 0.8, 0.0 };
00102 

Generated on Thu Jan 20 02:46:58 2005 for Main_Demo by doxygen 1.3.6