1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
16 ///////////////////////////////////////////////////////////////////////////////
18 // ESD format for TRD tracklet from FEE used for triggering
20 // Author: Jochen Klein <jochen.klein@cern.ch>
22 ///////////////////////////////////////////////////////////////////////////////
24 #include "AliESDTrdTracklet.h"
26 ClassImp(AliESDTrdTracklet)
28 AliESDTrdTracklet::AliESDTrdTracklet() :
38 AliESDTrdTracklet::AliESDTrdTracklet(UInt_t trackletWord, Short_t hcid, Int_t label) :
41 fTrackletWord(trackletWord),
44 // ctor with given tracklet word (and label)
47 AliESDTrdTracklet::~AliESDTrdTracklet()
52 AliESDTrdTracklet::AliESDTrdTracklet(const AliESDTrdTracklet &trkl) :
53 AliVTrdTracklet(trkl),
55 fTrackletWord(trkl.fTrackletWord),
62 AliESDTrdTracklet& AliESDTrdTracklet::operator=(const AliESDTrdTracklet &trkl)
64 // assignment operator
69 AliVTrdTracklet::operator=(trkl);
71 fTrackletWord = trkl.fTrackletWord;
77 Int_t AliESDTrdTracklet::GetBinY() const
79 // returns (signed) value of Y
81 if (fTrackletWord & 0x1000) {
82 return -((~(fTrackletWord-1)) & 0x1fff);
85 return (fTrackletWord & 0x1fff);
89 Int_t AliESDTrdTracklet::GetBinDy() const
91 // returns (signed) value of the deflection length
93 if (fTrackletWord & (1 << 19)) {
94 return -((~((fTrackletWord >> 13) - 1)) & 0x7f);
97 return ((fTrackletWord >> 13) & 0x7f);