ROOT logo
#include "hmdclayer.h"
#include "hmdcsizescells.h"
#include "hgeomvolume.h"

#include <iomanip>
#include <iostream>
#include <cmath>

using namespace std;
ClassImp(HMdcLayer)


HMdcLayer::HMdcLayer(){


    //MDCI
    xcrop[0][0] = 10;   // low
    xcrop[0][1] = 10;   //  up
    ycrop[0][0] =  0;
    ycrop[0][1] = 30;

    //MDCII
    xcrop[1][0] = 20;
    xcrop[1][1] = 20;
    ycrop[1][0] =  0;
    ycrop[1][1] =  0;

    //MDCIII
    xcrop[2][0] = 20;
    xcrop[2][1] = 40;
    ycrop[2][0] = 85;
    ycrop[2][1] = 77;

    //MDCIV
    xcrop[3][0] = 20;
    xcrop[3][1] = 40;
    ycrop[3][0] = 100;
    ycrop[3][1] =  0;

}

void   HMdcLayer::setMDCCrop(Int_t m,Double_t xlowcrop,Double_t xupcrop,Double_t ylowcrop,Double_t yupcrop)
{
    xcrop[m][0] = xlowcrop;
    xcrop[m][1] = xupcrop;
    ycrop[m][0] = ylowcrop;
    ycrop[m][1] = yupcrop;
}

void   HMdcLayer::getLayerPoints     (Int_t s,Int_t m,Int_t l, TVector2& p0,TVector2& p1,TVector2& p2,TVector2& p3)
{
    p0 = layerP[s][m][l][0];
    p1 = layerP[s][m][l][1];
    p2 = layerP[s][m][l][2];
    p3 = layerP[s][m][l][3];
}
void   HMdcLayer::getCropedLayerPoints(Int_t s,Int_t m,Int_t l, TVector2& p0,TVector2& p1,TVector2& p2,TVector2& p3)
{
    p0 = layerPcrop[s][m][l][0];
    p1 = layerPcrop[s][m][l][1];
    p2 = layerPcrop[s][m][l][2];
    p3 = layerPcrop[s][m][l][3];
}

Bool_t HMdcLayer::getLayersEdge(TVector2& p,
		     Int_t s,Int_t m,Int_t l,
		     Double_t& xmin ,Double_t& xmax,Double_t& ymin,Double_t& ymax,
		     Double_t& xmincrop ,Double_t& xmaxcrop,Double_t& ymincrop,Double_t& ymaxcrop
		    )
{
    // calculates min and max values of x and y  for a given point p
    // on the MDC layer. Both for full layer and croped layer
    //
    //                  y|
    //                   |
    //        p3         L2           p2
    //          --------------------
    //          \        |         /
    //           \       |        /
    //            \      |0,0    /    x
    //         ----\-----|------/----
    //           L3 \    |     /  L1
    //               \   |    /
    //                \  |   /
    //                 \ |  /
    //                  ----
    //                p4 |  p1
    //                   | L4
    //                   |
    //

    const TVector2& p1 = layerP[s][m][l][0];
    const TVector2& p2 = layerP[s][m][l][1];
    const TVector2& p3 = layerP[s][m][l][2];
    const TVector2& p4 = layerP[s][m][l][3];

    ymax = p2.Y();
    ymin = p1.Y();

    TVector2 dir1 = (p2-p1)/fabs(p2.Y()-p1.Y());
    TVector2 dir3 = (p3-p4)/fabs(p4.Y()-p3.Y());

    TVector2 pmax  = p1 + dir1 *  fabs(p.Y()-p1.Y());  //L1
    xmax =  pmax.X();
    pmax = p4 + dir3 *  fabs(p.Y()-p4.Y());            //L4
    xmin = pmax.X();

    if(p.Y()>ymax||p.Y()<ymin||p.X()>xmax||p.X()<xmin) {
	Error("getLayersEdge()","Point outside layer %i : %f,%f edge : x %f,%f , y %f,%f !",l,p.X(),p.Y(),xmin,xmax,ymin,ymax);
	return kFALSE;
    }


    const TVector2& p1c = layerPcrop[s][m][l][0];
    const TVector2& p2c = layerPcrop[s][m][l][1];
    const TVector2& p3c = layerPcrop[s][m][l][2];
    const TVector2& p4c = layerPcrop[s][m][l][3];

    ymaxcrop = p2c.Y();
    ymincrop = p1c.Y();

    dir1 = (p2c-p1c)/fabs(p2c.Y()-p1c.Y());
    dir3 = (p3c-p4c)/fabs(p4c.Y()-p3c.Y());

    pmax  = p1c + dir1 *  fabs(p.Y()-p1c.Y());  //L1
    xmaxcrop =  pmax.X();
    pmax = p4c + dir3 *  fabs(p.Y()-p4c.Y());   //L4
    xmincrop = pmax.X();

    return kTRUE;

}

Bool_t HMdcLayer::getLayersEdge(TVector2& p,
		     Int_t s,Int_t m,Int_t l,
		     Double_t& xmin ,Double_t& xmax,Double_t& ymin,Double_t& ymax
		    )
{
    // calculates min and max values of x and y  for a given point p
    // on the MDC layer. Both for full layer and croped layer
    //
    //                  y|
    //                   |
    //        p3         L2           p2
    //          --------------------
    //          \        |         /
    //           \       |        /
    //            \      |0,0    /    x
    //         ----\-----|------/----
    //           L3 \    |     /  L1
    //               \   |    /
    //                \  |   /
    //                 \ |  /
    //                  ----
    //                p4 |  p1
    //                   | L4
    //                   |
    //

    const TVector2& p1 = layerP[s][m][l][0];
    const TVector2& p2 = layerP[s][m][l][1];
    const TVector2& p3 = layerP[s][m][l][2];
    const TVector2& p4 = layerP[s][m][l][3];

    ymax = p2.Y();
    ymin = p1.Y();

    TVector2 dir1 = (p2-p1)/fabs(p2.Y()-p1.Y());
    TVector2 dir3 = (p3-p4)/fabs(p4.Y()-p3.Y());

    TVector2 pmax  = p1 + dir1 *  fabs(p.Y()-p1.Y());  //L1
    xmax =  pmax.X();
    pmax = p4 + dir3 *  fabs(p.Y()-p4.Y());            //L4
    xmin = pmax.X();

    if(p.Y()>ymax||p.Y()<ymin||p.X()>xmax||p.X()<xmin) {
	Error("getLayersEdge()","Point outside layer %i : %f,%f edge : x %f,%f , y %f,%f !",l,p.X(),p.Y(),xmin,xmax,ymin,ymax);
	return kFALSE;
    }

    return kTRUE;
}

Bool_t HMdcLayer::getCropedLayersEdge(TVector2& p,
			   Int_t s,Int_t m,Int_t l,
			   Double_t& xmin ,Double_t& xmax,Double_t& ymin,Double_t& ymax
			  )
{
    // calculates min and max values of x and y  for a given point p
    // on the MDC layer. Both for full layer and croped layer
    //
    //                  y|
    //                   |
    //        p3         L2           p2
    //          --------------------
    //          \        |         /
    //           \       |        /
    //            \      |0,0    /    x
    //         ----\-----|------/----
    //           L3 \    |     /  L1
    //               \   |    /
    //                \  |   /
    //                 \ |  /
    //                  ----
    //                p4 |  p1
    //                   | L4
    //                   |
    //

    const TVector2& p1 = layerPcrop[s][m][l][0];
    const TVector2& p2 = layerPcrop[s][m][l][1];
    const TVector2& p3 = layerPcrop[s][m][l][2];
    const TVector2& p4 = layerPcrop[s][m][l][3];

    ymax = p2.Y();
    ymin = p1.Y();

    TVector2 dir1 = (p2-p1)/fabs(p2.Y()-p1.Y());
    TVector2 dir3 = (p3-p4)/fabs(p4.Y()-p3.Y());

    TVector2 pmax  = p1 + dir1 *  fabs(p.Y()-p1.Y());  //L1
    xmax =  pmax.X();
    pmax = p4 + dir3 *  fabs(p.Y()-p4.Y());            //L4
    xmin = pmax.X();

    if(p.Y()>ymax||p.Y()<ymin||p.X()>xmax||p.X()<xmin) {
	return kFALSE;
    }
    return kTRUE;
}

Bool_t HMdcLayer::isCroped(TVector2& p,Int_t s,Int_t m,Int_t l)
{
    // calculates min and max values of x and y  for a given point p
    // on the MDC crop layer. return kTRUE i p is outside
    //
    //                  y|
    //                   |
    //        p3         L2           p2
    //          --------------------
    //          \        |         /
    //           \       |        /
    //            \      |0,0    /    x
    //         ----\-----|------/----
    //           L3 \    |     /  L1
    //               \   |    /
    //                \  |   /
    //                 \ |  /
    //                  ----
    //                p4 |  p1
    //                   | L4
    //                   |
    //

    const TVector2& p1 = layerPcrop[s][m][l][0];
    const TVector2& p2 = layerPcrop[s][m][l][1];
    const TVector2& p3 = layerPcrop[s][m][l][2];
    const TVector2& p4 = layerPcrop[s][m][l][3];
    Double_t xmin,xmax,ymin,ymax;

    ymax = p2.Y();
    ymin = p1.Y();

    TVector2 dir1 = (p2-p1)/fabs(p2.Y()-p1.Y());
    TVector2 dir3 = (p3-p4)/fabs(p4.Y()-p3.Y());

    TVector2 pmax  = p1 + dir1 *  fabs(p.Y()-p1.Y());  //L1
    xmax =  pmax.X();
    pmax = p4 + dir3 *  fabs(p.Y()-p4.Y());            //L4
    xmin = pmax.X();

    if(p.Y()>ymax||p.Y()<ymin||p.X()>xmax||p.X()<xmin) {
	return kTRUE;
    }
    return kFALSE;
}

void HMdcLayer::fillRKPlane(HMdcSizesCells* fSizesCells){
    //---------------------------------------------------
    // path length correction for vertex
    // Labsys
    Double_t rot[9] = {1.,0,0, 0.,1.,0., 0,0,1.};
    Double_t tr[3]  = {0.,0.,-500.};
    HGeomTransform trPlane;
    for(Int_t s=0;s<6;s++) {
	if(!fSizesCells->modStatus(s,0)) continue;
	HMdcSizesCellsSec& scsec = (*fSizesCells)[s];

	const HGeomTransform *trSecLab = scsec.getLabTrans();
	HMdcSizesCellsMod &sm    = scsec[0];
	const HGeomTransform* trModSeg = sm.getSecTrans();
	trPlane.setRotMatrix(rot);
	trPlane.setTransVector(tr);
	trPlane.transFrom(*trModSeg);
	trPlane.transFrom(*trSecLab);
	plMdc[s].setPlanePar(trPlane);
    }

    targetMidPoint = fSizesCells->getTargetMiddlePoint();
}

void HMdcLayer::fillLayerPoints(HMdcSizesCells* fSizesCells, Bool_t secsys)
{
    // set layers in layer coord system (using HMdcSizesCells)
    // calulates the croped layer realtive to the full layer
    // uses xcrop and ycrop values (default values are set in constructor).
    // if secsys = kTRUE the layer points are transformed to
    // sector system (default kFALSE).


    Double_t d = 0.1; //savety
    for(Int_t s=0;s<6;s++) {
	for(Int_t m=0;m<4;m++) {

	    if(!fSizesCells->modStatus(s,m)) continue;
	    HMdcSizesCellsMod& mod=(*fSizesCells)[s][m];
	    for(Int_t l=0;l<6;l++) {
		HMdcSizesCellsLayer& lay = (mod)[l];

		HGeomVolume* v = lay.getGeomVolume();
		for(Int_t nPoint=0; nPoint<4;nPoint++) {
		    HGeomVector& p = *v->getPoint(nPoint);

		    if     (nPoint==0) layerP [s][m][l][nPoint].Set(p.getX() + d, p.getY() - d);   // lower left
		    else if(nPoint==1) layerP [s][m][l][nPoint].Set(p.getX() + d, p.getY() + d);   // upper left
		    else if(nPoint==2) layerP [s][m][l][nPoint].Set(p.getX() - d, p.getY() + d);   // upper right
		    else if(nPoint==3) layerP [s][m][l][nPoint].Set(p.getX() - d, p.getY() - d);   // lower right
		}

                calcCropedLayer(s,m,l) ;

		if(secsys){
		    for(Int_t nPoint=0; nPoint<4;nPoint++) {
			Double_t x,y,z;
                        x=layerP [s][m][l][nPoint].X();
                        y=layerP [s][m][l][nPoint].Y();
			z=0;
			lay.transFrom(x,y,z);
			layerP [s][m][l][nPoint].Set(x,y);
                        x=layerPcrop [s][m][l][nPoint].X();
                        y=layerPcrop [s][m][l][nPoint].Y();
			z=0;
			lay.transFrom(x,y,z);
			layerPcrop [s][m][l][nPoint].Set(x,y);

		    }
		}
	    }
	}
    }

}


void HMdcLayer::calcCropedLayer (Int_t s,Int_t m,Int_t l)
{

    // calulates the croped layer realtive to the full layer
    // in layer coordinate system. uses xcrop and ycrop values.
    // the layer points and xcrop and ycrop have to be filled before.

    Double_t xmin,xmax,ymin,ymax;
    TVector2 ptmp;

    ptmp.Set(0,layerP[s][m][l][0].Y()+ycrop[m][0]);
    getLayersEdge(ptmp,s,m,l,xmin,xmax,ymin,ymax);
    layerPcrop[s][m][l][0].Set(xmax-xcrop[m][0],layerP[s][m][l][0].Y()+ycrop[m][0]);

    ptmp.Set(0,layerP[s][m][l][1].Y()-ycrop[m][1]);
    getLayersEdge(ptmp,s,m,l,xmin,xmax,ymin,ymax);
    layerPcrop[s][m][l][1].Set(xmax-xcrop[m][1],layerP[s][m][l][1].Y()-ycrop[m][1]);

    ptmp.Set(0,layerP[s][m][l][2].Y()-ycrop[m][1]);
    getLayersEdge(ptmp,s,m,l,xmin,xmax,ymin,ymax);
    layerPcrop[s][m][l][2].Set(xmin+xcrop[m][1],layerP[s][m][l][2].Y()-ycrop[m][1]);

    ptmp.Set(0,layerP[s][m][l][3].Y()+ycrop[m][0]);
    getLayersEdge(ptmp,s,m,l,xmin,xmax,ymin,ymax);
    layerPcrop[s][m][l][3].Set(xmin+xcrop[m][0],layerP[s][m][l][3].Y()+ycrop[m][0]);


}

void  HMdcLayer::printLayer (Int_t s,Int_t m,Int_t l)
{

    cout<<"s "<<s<<" m "<<m<<" l "<<l
	<<" p0("<<setw(10)<<layerP[s][m][l][0].X()<<","<<setw(10)<<layerP[s][m][l][0].Y()<<"),"
	<<" p1("<<setw(10)<<layerP[s][m][l][1].X()<<","<<setw(10)<<layerP[s][m][l][1].Y()<<"),"
	<<" p2("<<setw(10)<<layerP[s][m][l][2].X()<<","<<setw(10)<<layerP[s][m][l][2].Y()<<"),"
	<<" p3("<<setw(10)<<layerP[s][m][l][3].X()<<","<<setw(10)<<layerP[s][m][l][3].Y()<<")"<<endl;

}
void  HMdcLayer::printCropedLayer (Int_t s,Int_t m,Int_t l)
{

    cout<<"s "<<s<<" m "<<m<<" l "<<l
	<<" p0("<<setw(10)<<layerPcrop[s][m][l][0].X()<<","<<setw(10)<<layerPcrop[s][m][l][0].Y()<<"),"
	<<" p1("<<setw(10)<<layerPcrop[s][m][l][1].X()<<","<<setw(10)<<layerPcrop[s][m][l][1].Y()<<"),"
	<<" p2("<<setw(10)<<layerPcrop[s][m][l][2].X()<<","<<setw(10)<<layerPcrop[s][m][l][2].Y()<<"),"
	<<" p3("<<setw(10)<<layerPcrop[s][m][l][3].X()<<","<<setw(10)<<layerPcrop[s][m][l][3].Y()<<")"<<endl;

}
 hmdclayer.cc:1
 hmdclayer.cc:2
 hmdclayer.cc:3
 hmdclayer.cc:4
 hmdclayer.cc:5
 hmdclayer.cc:6
 hmdclayer.cc:7
 hmdclayer.cc:8
 hmdclayer.cc:9
 hmdclayer.cc:10
 hmdclayer.cc:11
 hmdclayer.cc:12
 hmdclayer.cc:13
 hmdclayer.cc:14
 hmdclayer.cc:15
 hmdclayer.cc:16
 hmdclayer.cc:17
 hmdclayer.cc:18
 hmdclayer.cc:19
 hmdclayer.cc:20
 hmdclayer.cc:21
 hmdclayer.cc:22
 hmdclayer.cc:23
 hmdclayer.cc:24
 hmdclayer.cc:25
 hmdclayer.cc:26
 hmdclayer.cc:27
 hmdclayer.cc:28
 hmdclayer.cc:29
 hmdclayer.cc:30
 hmdclayer.cc:31
 hmdclayer.cc:32
 hmdclayer.cc:33
 hmdclayer.cc:34
 hmdclayer.cc:35
 hmdclayer.cc:36
 hmdclayer.cc:37
 hmdclayer.cc:38
 hmdclayer.cc:39
 hmdclayer.cc:40
 hmdclayer.cc:41
 hmdclayer.cc:42
 hmdclayer.cc:43
 hmdclayer.cc:44
 hmdclayer.cc:45
 hmdclayer.cc:46
 hmdclayer.cc:47
 hmdclayer.cc:48
 hmdclayer.cc:49
 hmdclayer.cc:50
 hmdclayer.cc:51
 hmdclayer.cc:52
 hmdclayer.cc:53
 hmdclayer.cc:54
 hmdclayer.cc:55
 hmdclayer.cc:56
 hmdclayer.cc:57
 hmdclayer.cc:58
 hmdclayer.cc:59
 hmdclayer.cc:60
 hmdclayer.cc:61
 hmdclayer.cc:62
 hmdclayer.cc:63
 hmdclayer.cc:64
 hmdclayer.cc:65
 hmdclayer.cc:66
 hmdclayer.cc:67
 hmdclayer.cc:68
 hmdclayer.cc:69
 hmdclayer.cc:70
 hmdclayer.cc:71
 hmdclayer.cc:72
 hmdclayer.cc:73
 hmdclayer.cc:74
 hmdclayer.cc:75
 hmdclayer.cc:76
 hmdclayer.cc:77
 hmdclayer.cc:78
 hmdclayer.cc:79
 hmdclayer.cc:80
 hmdclayer.cc:81
 hmdclayer.cc:82
 hmdclayer.cc:83
 hmdclayer.cc:84
 hmdclayer.cc:85
 hmdclayer.cc:86
 hmdclayer.cc:87
 hmdclayer.cc:88
 hmdclayer.cc:89
 hmdclayer.cc:90
 hmdclayer.cc:91
 hmdclayer.cc:92
 hmdclayer.cc:93
 hmdclayer.cc:94
 hmdclayer.cc:95
 hmdclayer.cc:96
 hmdclayer.cc:97
 hmdclayer.cc:98
 hmdclayer.cc:99
 hmdclayer.cc:100
 hmdclayer.cc:101
 hmdclayer.cc:102
 hmdclayer.cc:103
 hmdclayer.cc:104
 hmdclayer.cc:105
 hmdclayer.cc:106
 hmdclayer.cc:107
 hmdclayer.cc:108
 hmdclayer.cc:109
 hmdclayer.cc:110
 hmdclayer.cc:111
 hmdclayer.cc:112
 hmdclayer.cc:113
 hmdclayer.cc:114
 hmdclayer.cc:115
 hmdclayer.cc:116
 hmdclayer.cc:117
 hmdclayer.cc:118
 hmdclayer.cc:119
 hmdclayer.cc:120
 hmdclayer.cc:121
 hmdclayer.cc:122
 hmdclayer.cc:123
 hmdclayer.cc:124
 hmdclayer.cc:125
 hmdclayer.cc:126
 hmdclayer.cc:127
 hmdclayer.cc:128
 hmdclayer.cc:129
 hmdclayer.cc:130
 hmdclayer.cc:131
 hmdclayer.cc:132
 hmdclayer.cc:133
 hmdclayer.cc:134
 hmdclayer.cc:135
 hmdclayer.cc:136
 hmdclayer.cc:137
 hmdclayer.cc:138
 hmdclayer.cc:139
 hmdclayer.cc:140
 hmdclayer.cc:141
 hmdclayer.cc:142
 hmdclayer.cc:143
 hmdclayer.cc:144
 hmdclayer.cc:145
 hmdclayer.cc:146
 hmdclayer.cc:147
 hmdclayer.cc:148
 hmdclayer.cc:149
 hmdclayer.cc:150
 hmdclayer.cc:151
 hmdclayer.cc:152
 hmdclayer.cc:153
 hmdclayer.cc:154
 hmdclayer.cc:155
 hmdclayer.cc:156
 hmdclayer.cc:157
 hmdclayer.cc:158
 hmdclayer.cc:159
 hmdclayer.cc:160
 hmdclayer.cc:161
 hmdclayer.cc:162
 hmdclayer.cc:163
 hmdclayer.cc:164
 hmdclayer.cc:165
 hmdclayer.cc:166
 hmdclayer.cc:167
 hmdclayer.cc:168
 hmdclayer.cc:169
 hmdclayer.cc:170
 hmdclayer.cc:171
 hmdclayer.cc:172
 hmdclayer.cc:173
 hmdclayer.cc:174
 hmdclayer.cc:175
 hmdclayer.cc:176
 hmdclayer.cc:177
 hmdclayer.cc:178
 hmdclayer.cc:179
 hmdclayer.cc:180
 hmdclayer.cc:181
 hmdclayer.cc:182
 hmdclayer.cc:183
 hmdclayer.cc:184
 hmdclayer.cc:185
 hmdclayer.cc:186
 hmdclayer.cc:187
 hmdclayer.cc:188
 hmdclayer.cc:189
 hmdclayer.cc:190
 hmdclayer.cc:191
 hmdclayer.cc:192
 hmdclayer.cc:193
 hmdclayer.cc:194
 hmdclayer.cc:195
 hmdclayer.cc:196
 hmdclayer.cc:197
 hmdclayer.cc:198
 hmdclayer.cc:199
 hmdclayer.cc:200
 hmdclayer.cc:201
 hmdclayer.cc:202
 hmdclayer.cc:203
 hmdclayer.cc:204
 hmdclayer.cc:205
 hmdclayer.cc:206
 hmdclayer.cc:207
 hmdclayer.cc:208
 hmdclayer.cc:209
 hmdclayer.cc:210
 hmdclayer.cc:211
 hmdclayer.cc:212
 hmdclayer.cc:213
 hmdclayer.cc:214
 hmdclayer.cc:215
 hmdclayer.cc:216
 hmdclayer.cc:217
 hmdclayer.cc:218
 hmdclayer.cc:219
 hmdclayer.cc:220
 hmdclayer.cc:221
 hmdclayer.cc:222
 hmdclayer.cc:223
 hmdclayer.cc:224
 hmdclayer.cc:225
 hmdclayer.cc:226
 hmdclayer.cc:227
 hmdclayer.cc:228
 hmdclayer.cc:229
 hmdclayer.cc:230
 hmdclayer.cc:231
 hmdclayer.cc:232
 hmdclayer.cc:233
 hmdclayer.cc:234
 hmdclayer.cc:235
 hmdclayer.cc:236
 hmdclayer.cc:237
 hmdclayer.cc:238
 hmdclayer.cc:239
 hmdclayer.cc:240
 hmdclayer.cc:241
 hmdclayer.cc:242
 hmdclayer.cc:243
 hmdclayer.cc:244
 hmdclayer.cc:245
 hmdclayer.cc:246
 hmdclayer.cc:247
 hmdclayer.cc:248
 hmdclayer.cc:249
 hmdclayer.cc:250
 hmdclayer.cc:251
 hmdclayer.cc:252
 hmdclayer.cc:253
 hmdclayer.cc:254
 hmdclayer.cc:255
 hmdclayer.cc:256
 hmdclayer.cc:257
 hmdclayer.cc:258
 hmdclayer.cc:259
 hmdclayer.cc:260
 hmdclayer.cc:261
 hmdclayer.cc:262
 hmdclayer.cc:263
 hmdclayer.cc:264
 hmdclayer.cc:265
 hmdclayer.cc:266
 hmdclayer.cc:267
 hmdclayer.cc:268
 hmdclayer.cc:269
 hmdclayer.cc:270
 hmdclayer.cc:271
 hmdclayer.cc:272
 hmdclayer.cc:273
 hmdclayer.cc:274
 hmdclayer.cc:275
 hmdclayer.cc:276
 hmdclayer.cc:277
 hmdclayer.cc:278
 hmdclayer.cc:279
 hmdclayer.cc:280
 hmdclayer.cc:281
 hmdclayer.cc:282
 hmdclayer.cc:283
 hmdclayer.cc:284
 hmdclayer.cc:285
 hmdclayer.cc:286
 hmdclayer.cc:287
 hmdclayer.cc:288
 hmdclayer.cc:289
 hmdclayer.cc:290
 hmdclayer.cc:291
 hmdclayer.cc:292
 hmdclayer.cc:293
 hmdclayer.cc:294
 hmdclayer.cc:295
 hmdclayer.cc:296
 hmdclayer.cc:297
 hmdclayer.cc:298
 hmdclayer.cc:299
 hmdclayer.cc:300
 hmdclayer.cc:301
 hmdclayer.cc:302
 hmdclayer.cc:303
 hmdclayer.cc:304
 hmdclayer.cc:305
 hmdclayer.cc:306
 hmdclayer.cc:307
 hmdclayer.cc:308
 hmdclayer.cc:309
 hmdclayer.cc:310
 hmdclayer.cc:311
 hmdclayer.cc:312
 hmdclayer.cc:313
 hmdclayer.cc:314
 hmdclayer.cc:315
 hmdclayer.cc:316
 hmdclayer.cc:317
 hmdclayer.cc:318
 hmdclayer.cc:319
 hmdclayer.cc:320
 hmdclayer.cc:321
 hmdclayer.cc:322
 hmdclayer.cc:323
 hmdclayer.cc:324
 hmdclayer.cc:325
 hmdclayer.cc:326
 hmdclayer.cc:327
 hmdclayer.cc:328
 hmdclayer.cc:329
 hmdclayer.cc:330
 hmdclayer.cc:331
 hmdclayer.cc:332
 hmdclayer.cc:333
 hmdclayer.cc:334
 hmdclayer.cc:335
 hmdclayer.cc:336
 hmdclayer.cc:337
 hmdclayer.cc:338
 hmdclayer.cc:339
 hmdclayer.cc:340
 hmdclayer.cc:341
 hmdclayer.cc:342
 hmdclayer.cc:343
 hmdclayer.cc:344
 hmdclayer.cc:345
 hmdclayer.cc:346
 hmdclayer.cc:347
 hmdclayer.cc:348
 hmdclayer.cc:349
 hmdclayer.cc:350
 hmdclayer.cc:351
 hmdclayer.cc:352
 hmdclayer.cc:353
 hmdclayer.cc:354
 hmdclayer.cc:355
 hmdclayer.cc:356
 hmdclayer.cc:357
 hmdclayer.cc:358
 hmdclayer.cc:359
 hmdclayer.cc:360
 hmdclayer.cc:361
 hmdclayer.cc:362
 hmdclayer.cc:363
 hmdclayer.cc:364
 hmdclayer.cc:365
 hmdclayer.cc:366
 hmdclayer.cc:367
 hmdclayer.cc:368
 hmdclayer.cc:369
 hmdclayer.cc:370
 hmdclayer.cc:371
 hmdclayer.cc:372
 hmdclayer.cc:373
 hmdclayer.cc:374
 hmdclayer.cc:375
 hmdclayer.cc:376
 hmdclayer.cc:377
 hmdclayer.cc:378
 hmdclayer.cc:379
 hmdclayer.cc:380
 hmdclayer.cc:381
 hmdclayer.cc:382
 hmdclayer.cc:383
 hmdclayer.cc:384
 hmdclayer.cc:385
 hmdclayer.cc:386
 hmdclayer.cc:387
 hmdclayer.cc:388
 hmdclayer.cc:389
 hmdclayer.cc:390
 hmdclayer.cc:391
 hmdclayer.cc:392
 hmdclayer.cc:393
 hmdclayer.cc:394
 hmdclayer.cc:395
 hmdclayer.cc:396
 hmdclayer.cc:397
 hmdclayer.cc:398
 hmdclayer.cc:399
 hmdclayer.cc:400
 hmdclayer.cc:401
 hmdclayer.cc:402
 hmdclayer.cc:403