--- DarthVader/TrackerLevel2/inc/TrkParams.h 2007/04/27 10:39:57 1.4 +++ DarthVader/TrackerLevel2/inc/TrkParams.h 2007/11/07 10:38:51 1.10 @@ -9,6 +9,7 @@ #include #include #include +#include // EMILIANO: needed to compile with ROOT > 5.16/x #include #include @@ -19,10 +20,12 @@ /** * \brief Class to store tracker parameter information * - * Tracker parameters include calibration parameters (PED, SIG and BAD) and - * other parameters (alignment, ADC-to-mip, etc. ). - * The first can be either those evaluated online or default values. - * The second are labelled according to the DB convention: + * Tracker parameters include calibration parameters (PED, SIG and BAD), + * parameters loaded from DB (alignment, ADC-to-mip, etc. ) and some parameters + * to configure tracker processing (PFA, ecc...). + * + * Calibrations can be either those evaluated online or default values. + * External parameter are labelled according to the DB convention: * * type description * ----------------- @@ -34,6 +37,8 @@ * 6 VA1 mask * 7 default calibration * + * Internal parameters are initialized to default values +* * TrkParams::SetCalib(...) and TrkParams::Set(...) methods allow to set * required parameters, from an input path, from the DB (for a given input * run id) and from environment variable PAM_CALIB. @@ -75,9 +80,20 @@ static GL_PARAM gl[NTYPES]; static TString glpath[NTYPES]; static Bool_t glload[NTYPES]; - + // ----------------------------------------------- + // some parameters to configure tracker processing + // ----------------------------------------------- + static int init__pfa; + static int init__mini_trackmode; + static int init__mini_istepmin; + static double init__mini_fact; + static cDbg init__dbg_mode; //debug mode (for both c++ and F77 roiutines) + static float init__pfa_e234ax[6]; // angle intervals for eta2-3-4 + static float init__pfa_e234ay[6]; // angle intervals for eta2-3-4 + TrkParams(); + // --------------------------------------------- // calibration (PED-SIG-BAD) // --------------------------------------------- @@ -108,18 +124,48 @@ static Bool_t IsLoaded( UInt_t type ){return glload[TrkParams::GetIndex(type)];}; static Bool_t IsLoaded( ); + // --------------------------------------------- + // retrieve parameters + // --------------------------------------------- + static float GetBX(float*); + static float GetBY(float*); + static float GetBZ(float*); + static float GetResolution(int,float); + static int GetPFA(){return sw_.pfaid;}; // --------------------------------------------- // debug mode // --------------------------------------------- - static cDbg dbg_mode; //debug mode (for both c++ and F77 roiutines) - static void SetDebugMode() {dbg_mode.SetDebug(); dbg_=dbg_mode;}; - static void SetVerboseMode(){dbg_mode.SetVerbose(); dbg_=dbg_mode;}; - static void SetWarningMode(){dbg_mode.SetWarning(); dbg_=dbg_mode;}; - static Bool_t DebugMode(){return dbg_mode.debug;}; - static Bool_t WarningMode(){return dbg_mode.warning;}; - static Bool_t VerboseMode(){return dbg_mode.verbose;}; + static void SetDebugMode() {init__dbg_mode.SetDebug(); dbg_=init__dbg_mode;}; + static void SetVerboseMode(){init__dbg_mode.SetVerbose(); dbg_=init__dbg_mode;}; + static void SetWarningMode(){init__dbg_mode.SetWarning(); dbg_=init__dbg_mode;}; + static void SetQuietMode() {init__dbg_mode.SetNone(); dbg_=init__dbg_mode;}; + static Bool_t DebugMode(){return init__dbg_mode.debug;}; + static Bool_t WarningMode(){return init__dbg_mode.warning;}; + static Bool_t VerboseMode(){return init__dbg_mode.verbose;}; + + // ------------------------------------------------ + // alcuni metodi che non sapevo dove mettere + // per inizializzare alcune variabili in F77 common + // ------------------------------------------------ + // set to default values + static void SetTrackingMode() {track_.trackmode = init__mini_trackmode;}; + static void SetPrecisionFactor(){track_.fact = init__mini_fact; }; + static void SetStepMin() {track_.istepmin = init__mini_istepmin; }; + // set to custom values + static void SetTrackingMode(int); + static void SetPrecisionFactor(double); + static void SetStepMin(int); + static void SetPFA(int); + static void SetPFA(float *); + static void SetPFA(void); + + // --------------------------------------------- + // varie ed eventuali... + // --------------------------------------------- + static TSQLServer* SetDBConnection(); + ClassDef(TrkParams,2);