ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/FastOpenGlDisplayer/soft/main.h
Revision: 1.6
Committed: Sat Apr 19 14:34:58 2008 UTC (17 years ago) by querten
Content type: text/plain
Branch: MAIN
CVS Tags: Version_0_23
Changes since 1.5: +4 -2 lines
Log Message:
Add DT/CSC Segments and RPC Hits

File Contents

# User Rev Content
1 querten 1.1
2     // SimEvent.h: interface for the SimEvent class.
3     //
4     //////////////////////////////////////////////////////////////////////
5    
6     #ifndef _MAIN_H__
7     #define _MAIN_H__
8    
9    
10     #ifdef linux
11     #include <GL/gl.h>
12     #include <GL/glu.h>
13     #include "../interface/glut.h"
14     #else
15     #define _CRT_SECURE_NO_DEPRECATE 1
16     #include <windows.h>
17     #include <gl/gl.h>
18     #include <gl/glu.h>
19     #include <gl/glut.h>
20     #pragma comment (lib,"glaux.lib")
21     #pragma comment (lib,"glu32.lib")
22     #pragma comment (lib,"opengl32.lib")
23     #pragma comment (lib,"glut.lib")
24     #pragma comment (lib,"glut32.lib")
25     #endif
26    
27     #include <stdio.h>
28     #include <math.h>
29    
30     #include "../interface/SimEvent.h"
31     #include "../interface/Geometry.h"
32    
33     #include "DrawPrimitive.h"
34     #include "ScreenShot.h"
35     #include "Logo.h"
36     #include "Texture.h"
37     #include "ReadCards.h"
38     #include "FROG_Struct.h"
39    
40     int SAVE_WINDOW_W = 800;
41     int SAVE_WINDOW_H = 600;
42     int SAVE_WINDOW_X = 10;
43     int SAVE_WINDOW_Y = 10;
44    
45     bool FULLSCREEN = false;
46     int WINDOW_WIDTH = 800;
47     int WINDOW_HEIGHT = 600;
48     int SCREENSHOT = 0;
49    
50     float CAM_R = 700;
51     float CAM_tx = 0.0;
52     float CAM_ty = 0.0;
53    
54     int CMS_TRACKER_RADIUS = 129;
55 querten 1.6 int CMS_TRACKER_LENGTH = 300;
56 querten 1.1
57     int TRACKING_RADIUS = 129;//295;
58 querten 1.6 int TRACKING_LENGTH = 300;//645;
59 querten 1.1
60     float PT_CUTOFF = 1.0;
61 roberfro 1.3 float EHCAL_CUTOFF = 4.0;
62     float EECAL_CUTOFF = 4.0;
63 querten 1.1
64     bool MouseStates[3];
65    
66     std::vector<GLuint> theSimTracks;
67 querten 1.5 GLuint theGeomMuon[3];
68 querten 1.6 GLuint theGeomMuonInEvent;
69 querten 1.1 GLuint theGeomTracker[6];
70     GLuint theGeomTrackerInEvent;
71     GLuint theGeomEcal[3];
72     GLuint theGeomEcalInEvent;
73     GLuint theGeomHcal[4];
74     GLuint theGeomHcalInEvent;
75    
76     GLuint LogoTexture;
77    
78     double t = 0;
79    
80 querten 1.4 std::string inputVisFile;
81     std::string inputTrackerGeom;
82     std::string inputEcalGeom;
83     std::string inputHcalGeom;
84 querten 1.5 std::string inputMuonGeom;
85 querten 1.1
86     MySimEvent* event;
87     MySimEvents* events;
88    
89     Geometry* geom;
90    
91     char gTracker = 0;
92     char gEcal = 0;
93     char gHcal = 0;
94 querten 1.5 char gMuon = 0;
95 roberfro 1.3 char gSim = 2;
96     char gReco = 7;
97 querten 1.1
98     int mTrackI = -1;
99     bool mLoading = true;
100     int mLoading_I = 0;
101    
102     int eventNumber = 0;
103    
104     bool mHelpScreen= false;
105     bool mRotate = true;
106     float mDt = 0.005f;
107    
108    
109     GLint Menu_Geom_Tracker = 0;
110     GLint Menu_Geom_Ecal = 0;
111     GLint Menu_Geom_Hcal = 0;
112 querten 1.5 GLint Menu_Geom_Muon = 0;
113 querten 1.1 GLint Menu_Geom = 0;
114     GLint Menu_SimEvent = 0;
115     GLint Menu_RecoEvent = 0;
116     GLint Menu_Main = 0;
117    
118     WidthAndColor WaC_BackGround = {1.0 , 0.0 , 1.0 , 0.0 , 1.0};
119     WidthAndColor WaC_Txt = {1.0 , 0.0 , 1.0 , 1.0 , 1.0};
120     WidthAndColor WaC_CMS_Framework = {1.0 , 1.0 , 0.5 , 1.0 , 0.3};
121     WidthAndColor WaC_LHC_Axis = {3.0 , 1.0 , 0.5 , 1.0 , 0.3};
122     WidthAndColor WaC_Default_SimTrack = {2.0 , 0.0 , 1.0 , 1.0 , 1.0};
123     WidthAndColor WaC_Selected_SimTrack = {2.0 , 1.0 , 1.0 , 0.0 , 1.0};
124    
125     void DrawTrack(MySimTrack* track, MySimVertex* vertex1, MySimVertex* vertex2);
126     void reshape (int w, int h);
127     void display();
128 querten 1.5 void initGeomMuon();
129 querten 1.6 void initGeomMuonInEvent();
130 querten 1.1 void initGeomTracker();
131     void initGeomTrackerInEvent();
132     void initGeomEcal();
133     void initGeomEcalInEvent();
134     void initGeomHcal();
135     void initGeomHcalInEvent();
136 querten 1.5
137 querten 1.1 void initSimTrack();
138     void init();
139     void menu_callback(int value);
140     void menu_create();
141     void LoadCard(const char* inputCard );
142    
143 querten 1.2 #endif
144