1 #ifndef ALIHLTMUONMANSOTRACKSBLOCKSTRUCT_H
2 #define ALIHLTMUONMANSOTRACKSBLOCKSTRUCT_H
3 /* Copyright(c) 1998-2007, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
9 * @file AliHLTMUONMansoTracksBlockStruct.h
10 * @author Artur Szostak <artursz@iafrica.com>
12 * @brief Definition of internal dimuon HLT tracks data block structure
13 * generated by the Manso algorithm.
15 * The structures are defined with C linkage since C generally gives us more
16 * binary compatibility between compilers.
19 #include "AliHLTMUONRecHitsBlockStruct.h"
25 * Track structure containing information about a partial track generated by
26 * the Manso algorithm.
28 struct AliHLTMUONMansoTrackStruct
30 AliHLTInt32_t fId; // Each Manso track should have an ID number unique
31 // for a given event. -1 == invalid.
33 AliHLTInt32_t fTrigRec; // The associated trigger record ID used as the
34 // seed for the Manso algorithm.
36 // The flags word constains the following bit fields (bit 31 is most
38 // bits: [31][30][29 --- 4][ 3 ][ 2 ][ 1 ][ 0 ]
39 // field: - + reserved hst[3] hst[2] hst[1] hst[0]
40 // Where fields hst[i] indicates if fHit[i] has been filled/set.
41 // Reserved bits should be set to zero.
42 // Particle sign: if '-' is set then particle has minus sign.
43 // if '+' is set then particle has negative sign.
44 // Either '+' or '-' should be set and if neither then the particle
46 AliHLTUInt32_t fFlags;
48 AliHLTFloat32_t fPx; // Particle's momentum X component in GeV/c.
49 AliHLTFloat32_t fPy; // Particle's momentum Y component in GeV/c.
50 AliHLTFloat32_t fPz; // Particle's momentum Z component in GeV/c.
51 AliHLTFloat32_t fChi2; // The chi squared of the fit of fHit points to
54 // Particle hit coordinates on tracking chambers 7 to 10.
55 // fHit[0] is for chamber 7 fHit[1] for chamber 8 etc...
56 AliHLTMUONRecHitStruct fHit[4];
60 * AliHLTMUONMansoTracksBlockStruct defines the format of the internal
61 * Manso tracks data block.
63 struct AliHLTMUONMansoTracksBlockStruct
65 AliHLTMUONDataBlockHeader fHeader; // Common data block header.
67 // Array of Manso tracks.
69 AliHLTMUONMansoTrackStruct fTrack[/*fHeader.fNrecords*/];
71 AliHLTMUONMansoTrackStruct fTrack[1];
79 * Stream operator for usage with std::ostream classes which prints the track
80 * information in the following format:
81 * {fId = xx, fTrigRec = yy, fFlags = 0xZZ, fPx = uu, fPy = vv, fPz = ww,
82 * fChi2 = ss, fHit[0] = {...}, fHit[1] = {...}, fHit[2] = {...},
85 std::ostream& operator << (
86 std::ostream& stream, const AliHLTMUONMansoTrackStruct& trigrec
90 * Stream operator for usage with std::ostream classes which prints the
91 * AliHLTMUONMansoTracksBlockStruct in the following format:
92 * {fHeader = xx, fTrack[] = [{..}, {..}, ...]}
94 std::ostream& operator << (
95 std::ostream& stream, const AliHLTMUONMansoTracksBlockStruct& block
99 inline bool operator == (
100 const AliHLTMUONMansoTrackStruct& a,
101 const AliHLTMUONMansoTrackStruct& b
104 return a.fId == b.fId and a.fTrigRec == b.fTrigRec
105 and a.fFlags == b.fFlags and a.fPx == b.fPx and a.fPy == b.fPy
106 and a.fPz == b.fPz and a.fChi2 == b.fChi2
107 and a.fHit[0] == b.fHit[0] and a.fHit[1] == b.fHit[1]
108 and a.fHit[2] == b.fHit[2] and a.fHit[3] == b.fHit[3];
111 inline bool operator != (
112 const AliHLTMUONMansoTrackStruct& a,
113 const AliHLTMUONMansoTrackStruct& b
116 return not operator == (a, b);
121 const AliHLTMUONMansoTracksBlockStruct& a,
122 const AliHLTMUONMansoTracksBlockStruct& b
125 inline bool operator != (
126 const AliHLTMUONMansoTracksBlockStruct& a,
127 const AliHLTMUONMansoTracksBlockStruct& b
130 return not operator == (a, b);
133 #endif // ALIHLTMUONMANSOTRACKSBLOCKSTRUCT_H