- Timestamp:
- 06/02/08 09:58:38 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mgeom/MGeomPix.cc
r8756 r8908 19 19 ! Author(s): Harald Kornmayer 1/2001 20 20 ! 21 ! Copyright: MAGIC Software Development, 2000-200 321 ! Copyright: MAGIC Software Development, 2000-2008 22 22 ! 23 23 ! … … 139 139 // ------------------------------------------------------------------------ 140 140 // 141 // Return distance of center to coordinate origin: hypot(fX,fY) 142 // 143 Float_t MGeomPix::GetDist() const 144 { 145 return TMath::Hypot(fX, fY); 146 } 147 148 // ------------------------------------------------------------------------ 149 // 150 // Return distance of center to center of pix: hypot(fX-pix.fX,fY-pix.fY) 151 // 152 Float_t MGeomPix::GetDist(const MGeomPix &pix) const 153 { 154 return TMath::Hypot(fX-pix.fX, fY-pix.fY); 155 } 156 157 // ------------------------------------------------------------------------ 158 // 159 // Return angle defined by the center and the center of pix: 160 // atan2(fX-pix.fX,fY-pix.fY) 161 // 162 Float_t MGeomPix::GetAngle(const MGeomPix &pix) const 163 { 164 return TMath::ATan2(fX - pix.GetX(), fY - pix.GetY()); 165 } 166 167 // ------------------------------------------------------------------------ 168 // 141 169 // compute the distance of a point (px,py) to the Hexagon center in 142 170 // MGeomPix coordinates. Return kTRUE if inside.
Note:
See TracChangeset
for help on using the changeset viewer.