Changeset 3514 for trunk/MagicSoft/Mars/mhist
- Timestamp:
- 03/15/04 19:51:13 (21 years ago)
- Location:
- trunk/MagicSoft/Mars/mhist
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mhist/MHCamera.cc
r3513 r3514 1262 1262 return TH1D::DistancetoPrimitive(px, py); 1263 1263 1264 if (GetPixelIndex(px, py)>=0) 1264 const Bool_t issame = TString(GetDrawOption()).Contains("same", TString::kIgnoreCase); 1265 1266 const Float_t maxr = (1-fGeomCam->GetConvMm2Deg())*fGeomCam->GetMaxRadius()/2; 1267 const Float_t conv = !issame || 1268 gPad->GetX1()<-maxr || gPad->GetY1()<-maxr || 1269 gPad->GetX2()> maxr || gPad->GetY2()>maxr ? 1 : fGeomCam->GetConvMm2Deg(); 1270 1271 cout << conv << endl; 1272 1273 if (GetPixelIndex(px, py, conv)>=0) 1265 1274 return 0; 1266 1275 … … 1279 1288 // 1280 1289 // 1281 Int_t MHCamera::GetPixelIndex(Int_t px, Int_t py ) const1290 Int_t MHCamera::GetPixelIndex(Int_t px, Int_t py, Float_t conv) const 1282 1291 { 1283 1292 if (fNcells<=1) … … 1288 1297 { 1289 1298 MHexagon hex((*fGeomCam)[i]); 1290 if (hex.DistancetoPrimitive(px, py )>0)1299 if (hex.DistancetoPrimitive(px, py, conv)>0) 1291 1300 continue; 1292 1301 -
trunk/MagicSoft/Mars/mhist/MHCamera.h
r3487 r3514 66 66 TPaveStats *GetStatisticBox(); 67 67 68 Int_t GetPixelIndex(Int_t px, Int_t py ) const;68 Int_t GetPixelIndex(Int_t px, Int_t py, Float_t conv=1) const; 69 69 70 70 void PaintAxisTitle();
Note:
See TracChangeset
for help on using the changeset viewer.