3 // Test macro that starts from a given pad and prints
4 // all pads up, down, right, left from this pad
5 // (up to the plane border).
7 void testPadsUpEtc(AliMpStationType station = kStation1,
8 AliMpPlaneType planeType = kBendingPlane)
10 AliMpReader reader(station, planeType);
11 AliMpSector* sector = reader.BuildSector();
12 AliMpSectorSegmentation segmentation(sector);
14 AliMpIntPair indices(85, 101);
15 if( planeType == kNonBendingPlane) indices = AliMpIntPair(129, 10);
18 if (segmentation.HasPad(indices)) {
20 pad = segmentation.PadByIndices(indices);
21 cout << "Pad: " << pad << endl << endl;
23 cout << "######### GO UP ############### " << endl;
25 AliMpPadPair nextPads(pad, pad);
26 while (nextPads.GetFirst().IsValid()) {
27 nextPads = segmentation.PadsUp(nextPads.GetFirst());
28 cout << " up 1: " << nextPads.GetFirst() << endl;
29 cout << " 2: " << nextPads.GetSecond() << endl;
32 cout << "######### GO DOWN ############### " << endl;
34 nextPads = AliMpPadPair(pad, pad);
35 while (nextPads.GetFirst().IsValid()) {
36 nextPads = segmentation.PadsDown(nextPads.GetFirst());
37 cout << " down 1: " << nextPads.GetFirst() << endl;
38 cout << " 2: " << nextPads.GetSecond() << endl;
41 cout << "######### GO RIGHT ############### " << endl;
43 nextPads = AliMpPadPair(pad, pad);
44 while (nextPads.GetFirst().IsValid()) {
45 nextPads = segmentation.PadsRight(nextPads.GetFirst());
46 cout << " right 1: " << nextPads.GetFirst() << endl;
47 cout << " 2: " << nextPads.GetSecond() << endl;
50 cout << "######### GO LEFT ############### " << endl;
52 nextPads = AliMpPadPair(pad, pad);
53 while (nextPads.GetFirst().IsValid()) {
54 nextPads = segmentation.PadsLeft(nextPads.GetFirst());
55 cout << " left 1: " << nextPads.GetFirst() << endl;
56 cout << " 2: " << nextPads.GetSecond() << endl;