00001 /*************************************************************************** 00002 * 00003 * $Id: StTpcHit.cxx,v 2.19 2011/10/17 00:13:49 fisyak Exp $ 00004 * 00005 * Author: Thomas Ullrich, Jan 1999 00006 *************************************************************************** 00007 * 00008 * Description: 00009 * 00010 *************************************************************************** 00011 * 00012 * $Log: StTpcHit.cxx,v $ 00013 * Revision 2.19 2011/10/17 00:13:49 fisyak 00014 * Add handles for IdTruth info 00015 * 00016 * Revision 2.18 2011/03/31 19:25:13 fisyak 00017 * Keep ADC value for cluster 00018 * 00019 * Revision 2.17 2010/03/26 13:47:29 fisyak 00020 * Add methods to modify hit content 00021 * 00022 * Revision 2.16 2010/03/05 16:30:19 fisyak 00023 * Add hit id 00024 * 00025 * Revision 2.15 2009/11/23 16:34:07 fisyak 00026 * Cleanup, remove dependence on dst tables, clean up software monitors 00027 * 00028 * Revision 2.14 2009/11/10 00:40:18 ullrich 00029 * Changed print-out format. 00030 * 00031 * Revision 2.13 2007/10/03 21:47:35 ullrich 00032 * Added several new member to hold hit length info. 00033 * 00034 * Revision 2.12 2004/08/06 15:37:09 fisyak 00035 * Add clster id 00036 * 00037 * Revision 2.11 2004/07/15 16:36:25 ullrich 00038 * Removed all clone() declerations and definitions. Use StObject::clone() only. 00039 * 00040 * Revision 2.10 2004/01/13 21:01:08 fisyak 00041 * Add Truth and Quality information from simulation 00042 * 00043 * Revision 2.9 2001/04/05 04:00:57 ullrich 00044 * Replaced all (U)Long_t by (U)Int_t and all redundant ROOT typedefs. 00045 * 00046 * Revision 2.8 2001/03/24 03:34:59 perev 00047 * clone() -> clone() const 00048 * 00049 * Revision 2.7 2000/07/28 23:29:42 calderon 00050 * Added handling of Fit Flag: use this flag to tell if the point 00051 * is used in the fit. 00052 * 00053 * Revision 2.6 2000/06/01 21:39:07 ullrich 00054 * Added member mFlag and access member flag() and setFlag(). 00055 * 00056 * Revision 2.5 1999/12/01 15:56:28 ullrich 00057 * Renamed xxxInCluster() methods to xxxInHit() 00058 * 00059 * Revision 2.4 1999/11/11 10:19:52 ullrich 00060 * Inlined sector() and padrow(). 00061 * 00062 * Revision 2.3 1999/11/09 19:35:25 ullrich 00063 * Memory now allocated using StMemoryPool via overloaded new/delete 00064 * 00065 * Revision 2.2 1999/11/04 21:41:00 ullrich 00066 * Added missing default constructor 00067 * 00068 * Revision 2.1 1999/10/28 22:27:07 ullrich 00069 * Adapted new StArray version. First version to compile on Linux and Sun. 00070 * 00071 * Revision 2.0 1999/10/12 18:42:48 ullrich 00072 * Completely Revised for New Version 00073 * 00074 **************************************************************************/ 00075 #include "StTpcHit.h" 00076 #include "StTrack.h" 00077 static const char rcsid[] = "$Id: StTpcHit.cxx,v 2.19 2011/10/17 00:13:49 fisyak Exp $"; 00078 00079 StMemoryPool StTpcHit::mPool(sizeof(StTpcHit)); 00080 00081 ClassImp(StTpcHit) 00082 00083 void StTpcHit::setExtends(Float_t cl_x, Float_t cl_t, Short_t mnpad, Short_t mxpad, Short_t mntmbk, Short_t mxtmbk) { 00084 setPadTmbk(cl_x, cl_t); 00085 Short_t pad = TMath::Nint(mMcl_x/64.); 00086 Short_t time = TMath::Nint(mMcl_t/64.); 00087 mMinpad = pad - mnpad; 00088 mMaxpad = mxpad - pad; 00089 mMintmbk = time - mntmbk; 00090 mMaxtmbk = mxtmbk - time; 00091 } 00092 00093 ostream& operator<<(ostream& os, const StTpcHit& v) 00094 { 00095 return os << Form("Tpc s/r %3i/%3i ",v.sector(),v.padrow()) 00096 << *((StHit *)&v) 00097 << Form(" pmin/max %3i/%3i np %2i tmin/max %3i/%3i nt %2i tm %6.2f pad %6.2f adc %4i", 00098 (Int_t) v.minPad(), (Int_t) v.maxPad(),(Int_t) v.padsInHit(), 00099 (Int_t) v.minTmbk(), (Int_t) v.maxTmbk(),(Int_t) v.timeBucketsInHit(), 00100 v.timeBucket(),v.pad(), v.adc()); 00101 } 00102 void StTpcHit::Print(Option_t *option) const {cout << *this << endl;}
1.5.9