ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/FastOpenGlDisplayer/interface/SimEvent.h
Revision: 1.7
Committed: Sun Apr 27 07:27:29 2008 UTC (17 years ago) by querten
Content type: text/plain
Branch: MAIN
CVS Tags: Version_0_24
Changes since 1.6: +10 -16 lines
Log Message:
Improvements in Loading and File Size

File Contents

# User Rev Content
1 querten 1.1 // SimEvent.h: interface for the SimEvent class.
2     //
3     //////////////////////////////////////////////////////////////////////
4    
5     #ifndef _MYSIMEVENT_H__
6     #define _MYSIMEVENT_H__
7    
8 querten 1.3 #define _CRT_SECURE_NO_DEPRECATE 1
9 querten 1.1
10 querten 1.3 #include <iostream>
11 querten 1.1 #include <vector>
12 querten 1.2 #include "Chunk.h"
13 querten 1.1
14     struct MyPSimHit {float x; float y; float z; float dEdX; int ProcessType;};
15     struct MyPCaloHit {float x; float y; float z; float E; int ProcessType;};
16     struct MySimVertex{float x; float y; float z; int parentTrack_id;};
17     struct MySimTrack {int track_id;float Px;float Py; float Pz; float E;int Type;int parent_vertex;float charge;};
18    
19     struct MyRecoHit {float x; float y; float z; int DetId; int Charge;};
20 querten 1.7 struct MyRecoTrack {std::vector<MyRecoHit*> Hits;};
21 querten 1.1
22 querten 1.3 struct MyCaloHit {float E; float t; int DetId;};
23    
24 querten 1.6 struct MyMuonSegment {int DetId; float PosX; float PosY; float PosZ; float DirX; float DirY; float DirZ;};
25     struct MyMuonHit {int DetId; float x; float y; float z;};
26    
27 querten 1.1
28     class MySimEvent
29     {
30     public:
31     MySimEvent();
32     virtual ~MySimEvent();
33    
34 querten 1.2 // int LoadEvent(FILE* f);
35     void LoadEvent(FILE* pFile, stChunk* ParentChunk);
36     void SaveEvent(stChunkToSave* ParentChunk);
37 querten 1.1
38 querten 1.7 std::vector<MyPSimHit*> MyPSimHitCollection;
39     std::vector<MyPCaloHit*> MyPCaloHitCollection;
40     std::vector<MySimVertex*> MySimVertexCollection;
41     std::vector<MySimTrack*> MySimTrackCollection;
42 querten 1.1
43 querten 1.7 std::vector<MyRecoTrack*> MyRecoTrackCollection;
44 querten 1.1
45 querten 1.7 std::vector<MyCaloHit*> MyEcalCaloHitCollection;
46     std::vector<MyCaloHit*> MyHcalCaloHitCollection;
47 querten 1.1
48 querten 1.7 std::vector<MyMuonSegment*> MyMuonSegmentCollection;
49     std::vector<MyMuonHit*> MyMuonHitCollection;
50 querten 1.1 };
51    
52     class MySimEvents
53     {
54     public:
55     MySimEvents();
56     virtual ~MySimEvents();
57    
58 querten 1.5 void Load(const char* path);
59     void Save(const char* path);
60 querten 1.1 void NextEvent();
61     void PreviousEvent();
62 roberfro 1.4 void GoToEvent(unsigned int i);
63 querten 1.1 MySimEvent* GetEvent();
64    
65     std::vector<MySimEvent*> Events;
66     int Current_Event;
67     };
68    
69     #endif