Changeset 10090 for trunk/Mars/mgeom
- Timestamp:
- 01/06/11 16:53:13 (14 years ago)
- Location:
- trunk/Mars/mgeom
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Mars/mgeom/MGeomCam.cc
r9398 r10090 422 422 // -------------------------------------------------------------------------- 423 423 // 424 // Check if the photon which is flying along the trajectory u has passed 425 // (or will pass) the frame of the camera (and consequently get 426 // absorbed). The position p and direction u must be in the 427 // telescope coordinate frame, which is z parallel to the focal plane, 428 // x to the right and y upwards, looking from the mirror towards the camera. 429 // 430 // The units are cm. 431 // 432 Bool_t MGeomCam::HitFrame(MQuaternion p, const MQuaternion &u, Double_t margin) const 433 { 434 if (margin<=0) 435 return HitFrame(p, u); 436 437 // z is defined from the mirror (0) to the camera (z>0). 438 // Thus we just propagate to the focal plane (z=fDist) 439 p.PropagateZ(u, GetCameraDist()*100); // m->cm 440 return p.R()<margin; 441 } 442 443 // -------------------------------------------------------------------------- 444 // 424 445 // Check if the position given in the focal plane (so z can be ignored) 425 446 // is a position which might hit the detector. It is meant to be a rough … … 583 604 // at the end. 584 605 // 585 // All pixel swith a center withing 1.75*GetT() are considered neiighbors,606 // All pixels with a center withing 1.75*GetT() are considered neighbors, 586 607 // Only six neighbors are allowed. 587 608 // -
trunk/Mars/mgeom/MGeomCam.h
r9594 r10090 122 122 123 123 virtual Bool_t HitFrame(MQuaternion p, const MQuaternion &u) const { return kFALSE; } 124 Bool_t HitFrame(MQuaternion p, const MQuaternion &u, Double_t margin) const; 124 125 virtual Bool_t HitDetector(const MQuaternion &p, Double_t offset=0) const; 125 126 -
trunk/Mars/mgeom/MGeomCamDwarf.cc
r9863 r10090 101 101 Bool_t MGeomCamDwarf::HitFrame(MQuaternion p, const MQuaternion &u) const 102 102 { 103 // z is defined from the mirror (0) to the camera (z>0).104 // Thus we just propagate to the focal plane (z=fDist)105 //p -= 1700./u.Z()*u;106 p.PropagateZ(u, GetCameraDist()*100); // m->cm107 108 103 // Add 10% to the max radius and convert from mm to cm 109 return p.R()<GetMaxRadius()*0.11;//TMath::Abs(p.X())<65 && TMath::Abs(p.Y())<65; 104 // FIXME: Why does the compiler complain without this cast? 105 return static_cast<const MGeomCam*>(this)->HitFrame(p, u, GetMaxRadius()*0.11); 110 106 } 111 107
Note:
See TracChangeset
for help on using the changeset viewer.