// $Id: BrGeantData.h,v 1.2 1998/04/06 21:12:08 videbaek Exp $ // // $Log: BrGeantData.h,v $ // Revision 1.2 1998/04/06 21:12:08 videbaek // Clean up and additions for Win95 // // Revision 1.1.1.1 1998/03/04 21:33:10 brahmlib // Brat geant // // #ifndef _BRGEANTDATA_H #define _BRGEANTDATA_H /////////////////////////////////////////////////////////////////////// // // // BrGeantData // // // // BRAHMS simulated raw data class // // // // BrGeantData handles geant raw data in stream i/o format // // // // Author : KrisHagel // // Created : Nov 97 // // Version : 1.0 // // Changed : 31/12/97 F.Videbaek // // /////////////////////////////////////////////////////////////////////// #include "TObject.h" #include "fstream.h" #include "stdio.h" const int MAXGVOLU = 50 ; class BrGeantHit; class BrGeantTrack; class BrEvent; struct GeantVolume { int shape; int Npar; char Name[4]; float pos[3]; float rotang[3][3]; float param[12]; int Active; }; class BrGeantData : public TObject { public: BrGeantData(); BrGeantData(Char_t *filename); virtual ~BrGeantData() { if(fFilePointer) { fFilePointer->close(); delete fFilePointer;}} virtual Bool_t Open(Char_t *fname); virtual Bool_t Close(); virtual BrEvent *GetNextEvent(); virtual Bool_t ReadStreamHeader(); Bool_t GetrHeader() { return rHeader; } void SetrHeader( Bool_t rHead ) { rHeader = rHead; } private: Bool_t rHeader; //! Header read mark Int_t fEventCounter; //! Event counter Char_t fFileName[256]; //! File name for ASCII file containing raw hits ifstream *fFilePointer; // File pointer to STREAM file Int_t fNumberOfVolumes; // Number of GEANT volumes GeantVolume fVolume[MAXGVOLU]; // Geant Volumes in STREAM file public: ClassDef(BrGeantData,0) // Interface to STREAM files }; #endif