]>
Commit | Line | Data |
---|---|---|
19a9b7cf | 1 | // $Id$ |
2 | // $MpId: testDE.C,v 1.1 2006/03/14 09:06:54 ivana Exp $ | |
3 | // | |
4 | // Test AliMpDEIterator & AliMpSegFactory classes | |
5 | ||
6 | void testDE() | |
7 | { | |
19a9b7cf | 8 | AliMpDEIterator it; |
9 | for ( it.First(); ! it.IsDone(); it.Next() ) { | |
cddd101e | 10 | cout << "In detection element: " << it.CurrentDEId() << endl; |
19a9b7cf | 11 | |
12 | // Create/get segmentation via factory | |
13 | AliMpVSegmentation* segmentation | |
cddd101e | 14 | = AliMpSegmentation::Instance() |
15 | ->GetMpSegmentation(it.CurrentDEId(), kCath0); | |
19a9b7cf | 16 | |
17 | // Print number of pads | |
18 | cout << " number of pads: " << segmentation->NofPads() << endl; | |
19 | ||
20 | // Find pad by indices in this DE | |
21 | AliMpIntPair indices(segmentation->MaxPadIndexX()/2 , | |
22 | segmentation->MaxPadIndexY()/2); | |
23 | AliMpPad pad = segmentation->PadByIndices(indices, false); | |
24 | ||
25 | cout << " found pad: " << pad << endl << endl; | |
26 | } | |
19a9b7cf | 27 | } |