Changeset 9338 for trunk/MagicSoft/Mars/mpointing/MSrcPosRndm.cc
- Timestamp:
- 02/15/09 15:09:12 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mpointing/MSrcPosRndm.cc
r8802 r9338 57 57 Int_t MSrcPosRndm::PreProcess(MParList *plist) 58 58 { 59 MGeomCam *geom = (MGeomCam*)plist->FindObject("MGeomCam");60 if (! geom)59 fGeom = (MGeomCam*)plist->FindObject("MGeomCam"); 60 if (!fGeom) 61 61 { 62 62 *fLog << err << "ERROR - MGeomCam not found... aborting." << endl; … … 86 86 *fLog << inf << "Source position will be produced randomly in a distance of " << fDistOfSource << "° from the camera center!" << endl; 87 87 88 fConvMm2Deg = geom->GetConvMm2Deg();89 90 88 return kTRUE; 91 89 } … … 107 105 } 108 106 109 fSrcPos->SetXY(x/fConvMm2Deg, y/fConvMm2Deg); 107 const Double_t f = fGeom->GetConvMm2Deg(); 108 109 fSrcPos->SetXY(x/f, y/f); 110 110 if (fDistOfSource>=0) 111 fSrcPosAnti->SetXY(-x/f ConvMm2Deg, -y/fConvMm2Deg);111 fSrcPosAnti->SetXY(-x/f, -y/f); 112 112 return kTRUE; 113 113 }
Note:
See TracChangeset
for help on using the changeset viewer.