-//______________________________________________________________________________
-void AliEveTRDDigits::ComputeRepresentation()
-{
- // Calculate digits representation according to user settings. The
- // user can set the following parameters:
- // - digits scale (log/lin)
- // - digits threshold
- // - digits apparence (quads/boxes)
- //if(!fData.HasData()){
- return;
- //}
-
- TEveQuadSet::Reset(TEveQuadSet::kQT_RectangleYZ, kTRUE, 64);
-
- Double_t scale, dy, dz;
- Int_t q, color;
- Int_t nrows = 0/*fData.GetNrow()*/,
- ncols = 0/*fData.GetNcol()*/,
- ntbs = 0/*fData.GetNtime()*/,
- det = fParent->GetID(),
- ly = AliTRDgeometry::GetLayer(det),
- stk = AliTRDgeometry::GetStack(det),
- sec = AliTRDgeometry::GetSector(det),
- vid = AliGeomManager::LayerToVolUID(AliGeomManager::kTRD1 + ly, stk + AliTRDgeometry::Nstack() * sec);
- Float_t threshold = fParent->GetDigitsThreshold();
- Short_t sig[7]={0,0,0,10,0,0,0};
-
- AliTRDtransform transform(det);
- AliTRDgeometry *geo = fParent->fGeo;
- AliTRDpadPlane *pp = geo->GetPadPlane(geo->GetLayer(det), geo->GetStack(det));
-
- printf("DET[%d] nr[%d] nc[%d] nt[%d] threshold[%f]\n", det, nrows, ncols, ntbs, threshold);
- // express position in tracking coordinates
- AliTRDcluster c;
- //fData.Expand();
- for (Int_t ir = 0; ir < nrows; ir++) {
- dz = pp->GetRowSize(ir);
- for (Int_t ic = 0; ic < ncols; ic++) {
- dy = pp->GetColSize(ic);
- for (Int_t it = 0; it < ntbs; it++) {
- //q = fData.GetData(ir, ic, it);
- //if (q < threshold) continue;
-
-/* Double_t x[6] = {0., 0., Double_t(q), 0., 0., 0.};
- Int_t roc[3] = {ir, ic, 0};
- Bool_t out = kTRUE;*/
-
- new (&c) AliTRDcluster(det, ic, ir, it, sig, vid);
- transform.Transform(&c);
-
- scale = q < 512 ? q/512. : 1.;
- color = kRed;//50+int(scale*50.);
-
- printf("\ty[%f] z[%f] x[%f] w[%f] h[%f] color[%d] q[%d]\n", c.GetY(), c.GetZ(), c.GetX(), .9*dy, dz*scale, color, q);
- AddQuad(c.GetY(), c.GetZ(), c.GetX(), .9*dy, /*dz*scale*/100.);
- QuadValue(Float_t(q));
- QuadColor(color);
- //QuadId(new TNamed(Form("ADC %d", adc), "det[%3d] col[%3d] row[%2d] tb[%2d]"));
- } // end time loop
- } // end col loop
- } // end row loop
- //fData.Compress();
-
- // rotate to global coordinates
- //RefitPlex();
- TEveTrans& t = RefMainTrans();
- t.SetRotByAngles((sec+.5)*AliTRDgeometry::GetAlpha(), 0.,0.);
-}
-