source: Sophya/trunk/SophyaPI/PIext/pihisto2d.cc@ 4018

Last change on this file since 4018 was 3615, checked in by cmv, 16 years ago

Modifs relatives a l'introduction de RandomGeneratorInterface + delete de srandgen.c, cmv 01/05/2009

File size: 34.0 KB
Line 
1#include <stdio.h>
2#include <stdlib.h>
3#include <pisysdep.h>
4#include PIAPP_H
5
6#include <iostream>
7#include <math.h>
8
9#include "sopnamsp.h"
10#include "pihisto2d.h"
11#include "srandgen.h"
12
13static int dbg = 0;
14
15
16//------ Implementation classe P2DHistoWrapper
17P2DHistoWrapper::P2DHistoWrapper(int_4 asx, int_4 asy)
18 : P2DArrayAdapter(asx, asy) ,
19 mScale(1.) , mOff(0.) , mRetFg(0)
20{
21}
22
23P2DHistoWrapper::~P2DHistoWrapper()
24{
25}
26
27
28double P2DHistoWrapper::MeanVal(int ix1, int ix2, int jy1, int jy2)
29{
30 int ec;
31 if (ix1>ix2) { ec=ix1; ix1=ix2; ix2=ec; }
32 if (jy1>jy2) { ec=jy1; jy1=jy2; jy2=ec; }
33 double ss = 0.;
34 for(int j=jy1; j<=jy2; j++)
35 for(int i=ix1; i<=ix2; i++) ss += (double)((*this)(i, j));
36 ss /= (double)((jy2-jy1+1)*(ix2-ix1+1));
37 return ss;
38}
39
40int P2DHistoWrapper::GetStatInfoAsText(vector<string> & /* text */ )
41{
42 return 0;
43}
44
45int P2DHistoWrapper::DecodeOptionString(vector<string> & opt, bool rmdecopt)
46{
47 if(opt.size() < 1) return(0);
48
49 vector<string> udopt; // On gardera ici les options non decodees
50 unsigned int k = 0;
51 int ndec = opt.size();
52 for( k=0; k<opt.size(); k++ ) {
53 string & opts = opt[k];
54 if(opts.substr(0,7) == "hs1") {
55 mScale = 1.; mOff = 0.;
56 }
57 else if(opts.substr(0,7) == "hscale=") {
58 mScale = atof(opts.substr(7).c_str());
59 }
60 else if(opts.substr(0,8) == "hoffset=") {
61 mOff = atof(opts.substr(8).c_str());
62 }
63 else if(opts.substr(0,8) == "hbincont") {
64 mRetFg = 0;
65 }
66 else if(opts.substr(0,7) == "hbinerr") {
67 mRetFg = 1;
68 }
69 else if(opts.substr(0,7) == "hbinent") {
70 mRetFg = 2;
71 }
72 else {
73 ndec--;
74 // S'il faut supprimer les options decodees
75 if (rmdecopt) udopt.push_back(opts);
76 }
77 }
78 // S'il faut supprimer les options decodees, on remplace l'argument opt
79 // par le vecteur des options non decodees.
80 if (rmdecopt) opt = udopt;
81 return(ndec);
82}
83
84int
85P2DHistoWrapper::OptionToString(vector<string> & opt) const
86{
87 char buff[64];
88 sprintf(buff, "hscale=%g", mScale); opt.push_back(buff);
89 sprintf(buff, "hoffset=%g", mOff); opt.push_back(buff);
90 if (mRetFg == 2) opt.push_back("hbinent");
91 else if (mRetFg == 1) opt.push_back("hbinerr");
92 else opt.push_back("hbincont");
93
94 return 1;
95}
96
97//++
98// Class PIHisto2D
99// Lib PIext
100// include pihisto2d.h
101//
102// Classes de dessin des histogrammes a 2 dimensions pour
103// objets *Histo2D*
104//--
105
106//++
107// Links Parents
108// PIDrawer
109//--
110
111//++
112// Titre Constructeur, méthodes
113//--
114
115//++
116PIHisto2D::PIHisto2D(P2DHistoWrapper* histowp, bool ad)
117//
118// Createur d'une classe de dessin pour l'histogramme 2D histo.
119//--
120: PIDrawer(), mHistoWp(histowp), mAdDO(ad), mLogScale(10.), mFPoints(0.5)
121{
122// mAdDO : Flag pour suppression automatique de mHistoWp
123// Attention: mFPoints n'est initialise que si on display par nuages de points
124// mLogScale n'est initialise que si on utilise une echelle log
125UseScale();
126UseColors();
127UseDisplay();
128UseDyn();
129UseFrac();
130SetStats();
131SetStatPosOffset();
132SetName("Histo2DDrw");
133// PIHisto2D has specific control tools
134mFgSpecContWind = true;
135}
136
137//++
138PIHisto2D::~PIHisto2D()
139//
140// Destructeur.
141//--
142{
143// La fonction virtuelle DeactivateControlWindow() doit etre appele
144// a ce niveau - En effet au niveau du destructeur de base, il
145// semble pointer sur la fonction de la classe de base
146// Reza - Octobre 2002
147// Desactivation totale de la fenetre de controle specialise
148// ---> parametre d'appel PIBaseWdgGen* wdg=NULL
149DeactivateControlWindow(NULL);
150if(mAdDO && mHistoWp!=NULL) delete mHistoWp;
151}
152
153//++
154void PIHisto2D::UseColors(bool fg,CMapId cmap,bool revcmap)
155//
156// Choix de la couleur si fg=true avec la color map cmap.
157// (pour la couleur cmap cf picmap.h).
158// Independamment du choix du display, la dynamique est
159// codee sur la color map donnant ainsi une double
160// information. Par exemple, carres de tailles variables
161// en couleur. Cette option est incontournable dans le cas
162// d'un display par des carres de taille fixe.
163// revcmap doit etre mis a "true" si on veut avoir une color map
164// inversee.
165//| -**- gestion dans H2WinArg par menu deroulant Black&White etc...
166//--
167{
168mFgCol = fg; mCmap = cmap; mRevCmap = revcmap;
169}
170
171//++
172void PIHisto2D::UseScale(unsigned short type,double logscale)
173//
174// Pour changer les echelles (lineaire ou logarithmique)
175//| Type = 0 : echelle lineaire
176//| = 1 : echelle log10
177//| -**- Explication du codage en type=0 (lineaire) :
178//| 1. [hmin,hmax] -> [0,1]
179//| h -> f = (h-hmin)/(hmax-hmin)
180//| 2. codage de f=[0,1] sur la dynamique du display choisi
181//| -**- Explication du codage en type=1 (logarithmique base 10) :
182//| 1. map lineaire entre 0 et 1:
183//| [hmin,hmax] -> [0,1]
184//| h -> f = (h-hmin)/(hmax-hmin)
185//| 2. transformation logarithmique de base 10 :
186//| [0,1] -> [0,1]
187//| f -> lf = log10(1.+f*(logscale-1))/log10(logscale)
188//| 3. codage de lf=[0,1] sur la dynamique du display choisi
189//| -**- gestion dans H2WinArg par menu deroulant Lineaire/Log10
190//| et "logscale" par saisie de valeur dans champ LogScal
191//--
192{
193if(type==0) mTypScal=0;
194else if(type==1) {mTypScal=1; if(logscale>1.) mLogScale=logscale;}
195else mTypScal=0;
196}
197
198//++
199void PIHisto2D::UseDisplay(unsigned short type,double fnpt)
200//
201// Type de Display
202//| Type = 0 : carres de tailles variables
203//| Type = 1 : nuages de points
204//| Le nombre de points a utiliser est fnpt*N
205//| ou N est le nombre de pixels ecran contenu
206//| dans un bin de l'histogramme.
207//| Type = 2 : code a la "hbook2" " .+123...9AB...YZ*"
208//| (cf detail PIHisto2D::HPrint2)
209//| Type = 3 : carres de taille fixe (couleur).
210//| -**- gestion dans H2WinArg par menu deroulant Carres_Var etc...
211//| et "fnpt" par saisie de valeur dans champ PerPt
212//--
213{
214if(type==0) mTypDisp = 0;
215else if(type==1) {
216 mTypDisp = 1;
217 if(fnpt<0.) mFPoints = 0.;
218 else if(fnpt>1.) mFPoints = 1.;
219 else mFPoints = fnpt;
220}
221else if(type==2) mTypDisp = 2;
222else if(type==3) mTypDisp = 3;
223else mTypDisp = 1;
224}
225
226//++
227void PIHisto2D::UseDyn(double fmin,double fmax)
228//
229// Gestion de la dynamique a representer:
230//| La dynamique va etre transformee de [hmin,hmax] vers [0,1] selon
231//| [hmin,hmax] -> [0,1]
232//| h -> f = (h-hmin)/(hmax-hmin)
233//| Par la suite, selon ce qui est demande, f va coder le display
234//| ou etre transforme en une autre echelle [0,1] (ex: echelle log10).
235//| Si hmax<=hmin, ils sont forces a la dynamique totale de l'histo2D.
236//| -**- gestion dans H2WinArg par saisie de valeurs dans champ Dyn
237//--
238{
239if( (mHistoWp) && (mHistoWp->NBinX()>0) && (mHistoWp->NBinY()>0) && (fmin>=fmax) ) {
240 double v,hmin,hmax;
241 hmin = hmax = (*mHistoWp)(0,0);
242 for (int_4 i=0; i<mHistoWp->NBinX(); i++)
243 for (int_4 j=0; j<mHistoWp->NBinY(); j++) {
244 v = (*mHistoWp)(i, j);
245 if(v<hmin) hmin = v;
246 if(v>hmax) hmax = v;
247 }
248 fmin = hmin; fmax = hmax;
249}
250
251if(fmin>=fmax) fmax = fmin+1.;
252mHMin = fmin; mHMax = fmax;
253}
254
255//++
256void PIHisto2D::UseFrac(double frmin,double frmax)
257//
258// Pour definir la fraction de la dynamique a dessiner:
259//| Selon le type de display (f=[0,1] cf PIHisto2D::UseDyn),
260//| - on ne dessine rien si f <= frmin dans les cas de display avec
261//| des nuages de points ou des carres de tailles variables.
262//| Pour un display "a la hbook2" on force frmin = 0.
263//| - frmax n'est utilise que pour la representation avec
264//| des carres de tailles variables: c'est la taille
265//| maximum que peut avoir le carre exprimee en unite
266//| de la taille du bin (ex: si frmax=0.8 le carre
267//| le + grand qui pourra etre dessine dans un bin
268//| aura une taille egale a 0.8*(taille du bin)).
269//| -**- gestion dans H2WinArg par saisie de valeurs dans champ Frac
270//--
271{
272if(frmin<0. || frmin>=1.) frmin = 0.;
273if(frmax<=0. || frmax>1. ) frmax = 1.;
274if(frmin>=frmax) {frmin=0.1; frmax=0.9;}
275mFracMin = frmin; mFracMax = frmax;
276}
277
278//++
279void PIHisto2D::Print(int lp)
280//
281// Print de l'etat des options du display.
282//--
283{
284printf("PIHisto2D::Print FgCol=%d Cmap=%d (Rev=%d) TypScal=%d TypDisp=%d (FPoints=%g)\n"
285 ,(int)mFgCol,(int)mCmap,(int)mRevCmap,mTypScal,mTypDisp,mFPoints);
286printf(" Dyn=%g,%g Frac=%g,%g LogSc=%g H=%p\n"
287 ,mHMin,mHMax,mFracMin,mFracMax,mLogScale,mHistoWp);
288fflush(stdout);
289}
290
291//++
292void PIHisto2D::UpdateLimits()
293//
294// Definition des tailles graphiques en fonction
295// des caracteristiques de l'histogramme a dessiner.
296//--
297{
298 if(!mHistoWp) return;
299 SetLimits(mHistoWp->XMin(), mHistoWp->XMax(), mHistoWp->YMin() , mHistoWp->YMax());
300}
301
302//++
303void PIHisto2D::ShowControlWindow(PIBaseWdgGen* wdg)
304//
305// Affichage de la fenetre de controle H2WinArg
306//--
307{
308 H2WinArg::SetCurrentPIHisto2D(this);
309 H2WinArg::ShowPIHisto2DTools(wdg);
310}
311
312//++
313void PIHisto2D::DeactivateControlWindow(PIBaseWdgGen* wdg)
314//
315// Desactivation de la fenetre de controle specialisee
316//--
317{
318 if (H2WinArg::GetCurrentPIHisto2D() == this) {
319 // si wdg != NULL, c'est un Detach (Drawer detache du PIBaseWdg
320 // si wdg == NULL, c'est un delete du PIHisto2D (du PIDrawer)
321 if ((wdg == NULL) || (H2WinArg::GetCurrentBaseWdg() == wdg)) {
322 H2WinArg::SetCurrentBaseWdg(NULL);
323 H2WinArg::SetCurrentPIHisto2D(NULL);
324 H2WinArg::HidePIHisto2DTools();
325 }
326 }
327 PIDrawer::DeactivateControlWindow(wdg);
328 return;
329}
330
331//++
332void PIHisto2D::Draw(PIGraphicUC* g,double xmin,double ymin,double xmax,double ymax)
333//
334// Dessin de l'histogramme.
335//| -**- Code de dessin selon choix des options:
336//| (detail voir UseColors UseScale UseDisplay UseDyn UseFrac)
337//| - [hmin,hmax] -> f=[0,1]
338//| (Choix hmin,hmax champ Dyn de H2WinArg)
339//| - Eventuellement ech Log -> re-codage log10 entre f=[0,1]
340//| (Choix menu deroulant et champ LogScal de H2WinArg)
341//| - Restriction de f=[0,1] -> f=[Frac(min),Frac(max)]
342//| (Choix champ Frac de H2WinArg)
343//| -**- Puis selon display:
344//| 0 carres variables, menu "Carres Var." de H2WinArg:
345//| if(f>Frac(min)) taille carre = f * Frac(max) * taille_du_bin
346//| 1 nuage de points, menu "....." et champ PerPt de H2WinArg:
347//| if(f>Frac(min)) npoints = f * PerPt * npoints_ecran_dans_bin
348//| 2 code hbook2, menu ".12..Z*" de H2WinArg:
349//| if(f>0) map de f=]0,1] dans ".+...Z*"
350//| 3 carres pleins, menu "Carres Pleins" et couleurs de H2WinArg):
351//| couleur = lut[ f * nombre_d_entree_dans_la_lut ]
352//--
353{
354if (axesFlags != kAxesNone) DrawAxes(g);
355
356if(!mHistoWp) return;
357if(mHistoWp->NBinX()<=0 || mHistoWp->NBinY()<=0) return;
358
359// Caracteristiques histogramme
360double dx = mHistoWp->WBinX(),dy = mHistoWp->WBinY();
361double p1dx,p1dy;
362g->DGrC2UC(1.,1.,p1dx,p1dy);
363
364// Gamme a representer entre [0,1] mais >=fracmin et scale fracmax
365double fracmin=FMin(), fracmax=FMax();
366double llscale = log10(LogScale());
367
368// gestion Couleurs.
369PIColors fgcoul = GetGraphicAtt().GetFgColor();
370PIColors bgcoul = GetGraphicAtt().GetBgColor();
371PIColorMap* cmap=NULL;
372int ncol = 0;
373if (mFgCol) {
374 cmap = new PIColorMap(mCmap);
375 cmap->ReverseColorIndex(mRevCmap);
376 ncol = cmap->NCol();
377 if(mTypDisp==3) fracmin=-1.;
378}
379
380// gestion epaisseur de ligne
381PILineAtt LineAtt = GetGraphicAtt().GetLineAtt();
382if(LineAtt == PI_NotDefLineAtt) GetGraphicAtt().SetLineAtt(PI_ThinLine);
383
384// gestion Markers ou plot avec des points.
385PIMarker Mk = GetGraphicAtt().GetMarker();
386int MkSz = GetGraphicAtt().GetMarkerSize();
387int npt = 1;
388if(mTypDisp==1) {
389 g->SelMarker(1,PI_DotMarker);
390 npt = (int)(NPixBin(g)*FPoints()); if(npt<=0) npt = 2;
391}
392
393// gestion Font.
394PIFontAtt FontAtt = GetGraphicAtt().GetFontAtt();
395int FontSize = GetGraphicAtt().GetFontSzPt();
396if(mTypDisp==2) {
397 double dxg,dyg,dg;
398 g->DUC2GrC(dx,dy,dxg,dyg);
399 dg =(dxg<dyg) ? dxg : dyg;
400 int npix = (int) (dg*0.9); if(npix<8) npix = 8;
401 g->SelFontSzPt(npix,FontAtt);
402 fracmin = 0;
403}
404
405// Plot de l'histogramme
406for(int i=0; i<mHistoWp->NBinX(); i++)
407 for(int j=0; j<mHistoWp->NBinY(); j++) {
408
409 r_8 left0,bottom0;
410 mHistoWp->BinLowEdge(i,j,left0,bottom0);
411
412 // Gestion de la dynamique a dessiner
413 double frac = ((*mHistoWp)(i,j)-HMin())/(HMax()-HMin());
414 if(frac<0.) continue;
415 if(mTypScal==1) { // echelle log10
416 frac = log10(1.+frac*(LogScale()-1.))/llscale;
417 if(frac<0.) continue;
418 }
419 if(frac<=fracmin) continue;
420 if(frac>1.) frac = 1.;
421 double fracred = frac * fracmax;
422
423 // Gestion de la couleur
424 int icol = 0;
425 if (cmap) {
426 icol = int(ncol*frac);
427 if(icol>=ncol) icol = ncol-1; else if(icol<0) icol=0;
428 g->SelForeground(*cmap,icol);
429 }
430
431// Pour ne pas dessiner en dehors des axes
432 if ( (left0+dx/2. < xmin) || (left0+dx/2. > xmax) ||
433 (bottom0+dy/2. < ymin) || (bottom0+dy/2. > ymax) ) continue;
434
435 // Dessin proprement dit selon le choix graphique.
436 if(mTypDisp==0) {
437 //..... carres de tailles variables
438 double left = left0 + 0.5*(1.-fracred)*dx, width = fracred*dx;
439 double bottom = bottom0 + 0.5*(1.-fracred)*dy, height = fracred*dy;
440 if (cmap) g->DrawFBox(left,bottom,width,height);
441 else g->DrawBox(left,bottom,width,height);
442 } else if(mTypDisp==1) {
443 //..... nuage de points .....
444 int ipt = int(npt *frac);
445 for(int k=0;k<ipt;k++) {
446 double x = left0 + drand01()*dx;
447 double y = bottom0 + drand01()*dy;
448 g->DrawMarker(x,y);
449 }
450 } else if(mTypDisp==2) {
451 //..... type hbook2/hprint .+23-Z*
452 char c[2];
453 c[0] = HPrint2(frac); c[1]='\0';
454 double x = left0 + dx/2.;
455 double y = bottom0 + dy/2.;
456 g->DrawString(x,y,c,PI_HorizontalCenter|PI_VerticalCenter);
457 } else if(mTypDisp==3) {
458 //..... carres de tailles fixes (avec gestion de continuite)
459 if (cmap) g->DrawFBox(left0,bottom0,dx+p1dx,dy+p1dy);
460 else g->DrawBox(left0,bottom0,dx+p1dx,dy+p1dy);
461 }
462
463}
464
465// Remise dans les conditions ulterieures pour la suite du graphique.
466GetGraphicAtt().SetMarkerAtt(MkSz,Mk);
467GetGraphicAtt().SetColAtt(fgcoul,bgcoul);
468g->SelFontSzPt(FontSize,FontAtt);
469GetGraphicAtt().SetLineAtt(LineAtt);
470if (cmap) delete cmap;
471
472// Fin du dessin, ecriture de la statistique.
473if(stats) DrawStats(g);
474}
475
476//++
477void PIHisto2D::GetClickInfo(string& info,double x,double y,double x0,double y0,bool fgdiff)
478//
479// Info specifique du drawer pour la position x,y
480//--
481{
482P2DHistoWrapper* h = HistoWrapper();
483if(h == NULL) return;
484
485int_4 i,j;
486i = floor((x-h->XMin())/h->WBinX());
487j = floor((y-h->YMin())/h->WBinY());
488
489if(i>=0 && i<h->NBinX() && j>=0 && j<h->NBinY()) {
490 char str[64];
491 if(fgdiff) {
492 int i0,j0;
493 i0 = floor((x0-h->XMin())/h->WBinX());
494 j0 = floor((y0-h->YMin())/h->WBinY());
495 if(i0>=0 && i0<h->NBinX() && j0>=0 && j0<h->NBinY()) {
496 sprintf(str," DV=%g",(*h)(i,j)-(*h)(i0,j0));
497 info += str;
498 } else {
499 info += " DV=?";
500 }
501 }
502 sprintf(str," V=%g",(*h)(i,j));
503 info += str;
504} else {
505 info += " V=?";
506}
507
508return;
509}
510
511//++
512void PIHisto2D::DrawStats(PIGraphicUC* g)
513//
514// Dessin des informations statistiques de l'histogramme.
515//--
516{
517 if (!mHistoWp) return;
518 if (GetGraphicAtt().GetLineAtt() == PI_NotDefLineAtt) g->SelLine(PI_ThinLine);
519// Reza(12/2008): utilisation de flag et fraction pour selection automatique taille de fonte
520 if (mAFSz) {
521 double fsz = (YMax() - YMin())*mFontSzF;
522 g->SelFontSz(fsz); // au lieu de 1/30*(ymax-ymin)
523 }
524
525 // La hauteur de la cellule
526 PIGrCoord a, d;
527 double cH = (double)g->GetFontHeight(a,d);
528 vector<string> lines;
529 int nlig = mHistoWp->GetStatInfoAsText(lines);
530 if (nlig < 1) return;
531
532 double cellHeight = nlig*1.2 * cH;
533
534 int idxll = 0;
535
536 int kl;
537 // on recherche la ligne la plus longue
538 for(kl=1; kl<nlig; kl++)
539 if ( lines[kl].length() > lines[idxll].length() ) idxll = kl;
540
541 double cellWidth = 1.1 * (double)g->CalcStringWidth(lines[idxll].c_str());
542
543
544 double ofpx = spoX*(XMax()-XMin());
545 double ofpy = spoY*(YMax()-YMin());
546
547 double xu, yu, cw;
548 // Les limites du cadre
549 xu = g->DeltaUCX(XMax(), -cellWidth);
550 yu = g->DeltaUCY(YMax(), -cellHeight);
551 double recw = XMax()-xu;
552 double rech = YMax()-yu;
553 xu += ofpx; yu += ofpy;
554 g->DrawBox(xu, yu, recw, rech);
555
556 // L'ecriture des labels
557 cw = (g->isAxeXDirRtoL()) ? -0.05*cellWidth : -0.95*cellWidth;
558 xu = g->DeltaUCX(XMax(),cw);
559
560 cw = (g->isAxeYDirUpDown()) ? -0.15*cH : -1.15*cH;
561 yu = g->DeltaUCY(YMax(),cw);
562 xu += ofpx; yu += ofpy;
563
564 for(kl=0; kl<nlig; kl++) {
565 g->DrawString(xu, yu, lines[kl].c_str() );
566 cw += -1.15*cH;
567 yu = g->DeltaUCY(YMax(),cw); yu += ofpy;
568 }
569
570
571 // printf("H[%d,%d] Dynamique: [%g,%g] Frac [%g,%g]\n"
572 // ,mHistoWp->NBinX(),mHistoWp->NBinY(),HMin(),HMax(),FMin(),FMax());
573}
574
575//++
576char PIHisto2D::HPrint2(double f)
577//
578// Codage des valeurs en caracteres (fct privee).
579//| f entre [0,1] mappee entre valeur=[0,37]
580//| si <0 alors =0, si >1 alors 1
581//| Display 4 ==> 4<=valeur<5
582//| C ==> 12<=valeur<13
583//| ==> valeur<=0
584//| * ==> valeur>=1
585//| . ==> 0<valeur<1
586//|------------------------------------------
587//| 1 2 3
588//| 01234567890123456789012345678901234567
589//| .+23456789ABCDEFGHIJKLMNOPQRSTUVWXYZ*
590//|------------------------------------------
591//--
592{
593char str[39] = " .+23456789ABCDEFGHIJKLMNOPQRSTUVWXYZ*";
594int i;
595if(f<=0.) i = 0;
596else if(f>=1.) i = 37;
597else { i = (int) (f*36.); i++;}
598if(i<0) i=0; else if (i>=38) i = 37;
599return str[i];
600}
601
602//++
603int PIHisto2D::NPixBin(PIGraphicUC* g)
604//
605// Nombre de pixels ecran dans un bin d'histogramme
606// (fct privee).
607//--
608{
609double dx = mHistoWp->WBinX(),dy = mHistoWp->WBinY();
610double dxg,dyg;
611g->DUC2GrC(dx,dy,dxg,dyg);
612int np = (int) dxg * (int) dyg;
613//printf("PIHisto2D::NPixBin H dx=%g dy=%g, G dx=%g dy=%g, np = %d\n"
614// ,dx,dy,dxg,dyg,np);
615return np;
616}
617
618//++
619int PIHisto2D::DecodeOptionString(vector<string> & opt, bool rmdecopt)
620//
621// Decodage des options
622//--
623{
624 // Decodage des options generales pidrawer
625 int optsz1 = opt.size();
626 if(optsz1<1) return(0);
627 int ndec1 = PIDrawer::DecodeOptionString(opt, rmdecopt);
628 if(optsz1-ndec1<1) return(ndec1); // si tout a ete decode
629
630 // Options generales pidrawer interessant le display Histo2D
631 bool rev;
632 if(GetGraphicAtt().GetColMapId(rev) != CMAP_OTHER) {
633 UseColors(true,GetGraphicAtt().GetColMapId(),rev);
634 } else UseColors(false);
635
636 // Decodage des options propres au display Histo2D
637 vector<string> udopt; // On gardera ici les options non decodees
638 unsigned int k = 0;
639 int ndec = opt.size();
640 bool listopt=false;
641 for( k=0; k<opt.size(); k++ ) {
642 string opts = opt[k];
643 if(opts=="h2help") {
644 string info; GetOptionsHelpInfo(info);
645 size_t q = info.find("PIHisto2D");
646 if(q<info.length()-1) cout<<info.substr(q)<<endl;
647 } else if(opts=="h2list") {
648 listopt=true;
649 } else if(opts=="sta" || opts=="stat" || opts=="stats") {
650 SetStats(true);
651 } else if( opts=="nsta" || opts=="nstat"
652 || opts=="nostat" || opts=="nostats") {
653 SetStats(false);
654 } else if(opts.substr(0,11) == "statposoff=") {
655 double xo=0., yo=0.;
656 sscanf(opts.substr(11).c_str(),"%lf,%lf",&xo, &yo);
657 SetStatPosOffset(xo, yo);
658 } else if(opts.substr(0,8)=="h2scale=") {
659 unsigned short t=TypScale(); double ls=LogScale();
660 if(opts.substr(8,3)=="lin") t=0;
661 else if(opts.substr(8,3)=="log")
662 {t=1; sscanf(opts.c_str(),"h2scale=log,%lf",&ls);}
663 UseScale(t,ls);
664 } else if(opts.substr(0,7)=="h2disp=") {
665 unsigned short t=TypDisplay(); double fpts=FPoints();
666 if(opts.substr(7,3)=="var") t=0;
667 else if(opts.substr(7,3)=="hbk") t=2;
668 else if(opts.substr(7,3)=="img") t=3;
669 else if(opts.substr(7,3)=="pts")
670 {t=1; sscanf(opts.c_str(),"h2disp=pts,%lf",&fpts);}
671 UseDisplay(t,fpts);
672 } else if(opts.substr(0,6)=="h2dyn=") {
673 double hmin=HMin(),hmax=HMax(); size_t q = opts.find(',');
674 sscanf(opts.c_str(),"h2dyn=%lf",&hmin);
675 if(q<opts.length()-1) sscanf(opts.substr(q+1).c_str(),"%lf",&hmax);
676 UseDyn(hmin,hmax);
677 } else if(opts.substr(0,7)=="h2frac=") {
678 double fmin=FMin(),fmax=FMax(); size_t q = opts.find(',');
679 sscanf(opts.c_str(),"h2frac=%lf",&fmin);
680 if(q<opts.length()-1) sscanf(opts.substr(q+1).c_str(),"%lf",&fmax);
681 UseFrac(fmin,fmax);
682 } else {
683 ndec--;
684 // S'il faut supprimer les options decodees
685 if (rmdecopt) udopt.push_back(opts);
686 }
687 }
688
689 // S'il faut supprimer les options decodees, on remplace l'argument opt
690 // par le vecteur des options non decodees.
691 if (rmdecopt) opt = udopt;
692
693 // Decodage des options par le histo-wrapper
694 int ndec2 = 0;
695 if ( ( optsz1-ndec1-ndec > 0) && (mHistoWp) ) {
696 ndec2 = mHistoWp->DecodeOptionString(opt, rmdecopt);
697 }
698
699 // Liste des options si demande
700 if(listopt) Print();
701
702 return(ndec+ndec1+ndec2);
703}
704
705int PIHisto2D::OptionToString(vector<string> & opt) const
706{
707 PIDrawer::OptionToString(opt);
708 char str[256];
709
710 if(stats) opt.push_back("stat"); else opt.push_back("nstat");
711
712 sprintf(str,"statposoff=%f,%f",spoX,spoY);
713 opt.push_back(str);
714
715 if(mTypDisp==0) sprintf(str,"h2disp=var");
716 else if(mTypDisp==1) sprintf(str,"h2disp=pts,%g",mFPoints);
717 else if(mTypDisp==2) sprintf(str,"h2disp=hbk");
718 else if(mTypDisp==3) sprintf(str,"h2disp=img");
719 opt.push_back(str);
720
721 if(mTypScal==0) sprintf(str,"h2scale=lin");
722 else if(mTypScal==1) sprintf(str,"h2disp=log,%g",mLogScale);
723 opt.push_back(str);
724
725 sprintf(str,"h2dyn=%g,%g",mHMin,mHMax);
726 opt.push_back(str);
727
728 sprintf(str,"h2frac=%g,%g",mFracMin,mFracMax);
729 opt.push_back(str);
730
731 if(mRevCmap) opt.push_back("revcmap");
732
733 // Les options du Histo2DWrapper :
734 if(mHistoWp) mHistoWp->OptionToString(opt);
735 return 1;
736}
737
738
739//++
740void PIHisto2D::GetOptionsHelpInfo(string& info)
741//
742// Help relatif au options
743//--
744{
745info += " ---- PIHisto2D options help info (see also ALT-O): \n" ;
746info += "- h2help: get this help text\n";
747info += "- h2list: list choosen options\n";
748info += "- sta,stat,stats: activate statistic display\n";
749info += " nsta,nstat,nostat,nostats: deactivate statistic display\n";
750info += "- h2disp=typ[,fracpts]: choose display type\n";
751info += " typ=var: variable size boxes\n";
752info += " typ=hbk: \"a la hbook2\"\n";
753info += " typ=img: image like (use \"h2col\" for color map)\n";
754info += " typ=pts: point clouds (fracpts=max possible fraction\n";
755info += " of used pixels per bin [0,1])\n";
756info += "- h2scale=lin/log[,logscale]: choose linear or logarithmic scale\n";
757info += "- h2dyn=[hmin][,hmax]: choose histogramme range for display\n";
758info += "- use graphic att. to define color table (ex: grey32,midas_heat,...)\n";
759info += " (see general graphicatt description)\n";
760info += "- use \"revcmap\" to reverse color table\n";
761info += "- h2frac=[fmin][,fmax]: choose sub-range display [0,1]\n";
762info += " ---- HistoWrapper options : \n" ;
763info += " hbincont: select bin content as Y value for display (default) \n";
764info += " hbinerr: select bin error as Y value for display \n";
765info += " hbinent: select bin entries as Y value for display \n";
766info += " hscale=value : multiplicative factor for Y value \n" ;
767info += " hoffset=value : additive coefficient for Y value \n" ;
768info += " hs1: set hscale=1 hoffset=0 (default) \n" ;
769// On recupere ensuite la chaine info de la classe de base
770PIDrawer::GetOptionsHelpInfo(info);
771return;
772}
773
774/////////////////////////////////////////////////////////////////
775// Classe H2WinArg
776/////////////////////////////////////////////////////////////////
777//++
778// Class H2WinArg
779// Lib PIext
780// include pihisto2d.h
781//
782// Fenêtre de dialogue pour le choix des options de tracé pour "PIHisto2D"
783// Classe de fenêtre de dialogue permettant de modifier interactivement
784// Les différents attributs de visualisation pour les *PIImage* .
785//--
786//++
787// Links Parents
788// PIWindow
789//--
790//++
791// Links Voir aussi
792// PIHisto2D
793// PIH2DWdg
794//--
795
796//++
797// Titre Constructeur, méthodes
798//--
799
800PIBaseWdgGen* H2WinArg::mBWdg = NULL;
801PIHisto2D* H2WinArg::mH2DDrw = NULL;
802static H2WinArg* cur_h2winarg = NULL;
803
804void H2WinArg::ShowPIHisto2DTools()
805{
806 if (cur_h2winarg == NULL) cur_h2winarg = new H2WinArg(PIApplicationGetApp());
807 cur_h2winarg->Show();
808}
809
810void H2WinArg::ShowPIHisto2DTools(PIBaseWdgGen* cbw)
811{
812 if (cur_h2winarg == NULL) cur_h2winarg = new H2WinArg(PIApplicationGetApp());
813 mBWdg = cbw;
814 cur_h2winarg->Show();
815}
816
817void H2WinArg::HidePIHisto2DTools()
818{
819 if (cur_h2winarg != NULL) cur_h2winarg->Hide();
820}
821
822void H2WinArg::SetCurrentBaseWdg(PIBaseWdgGen* cbw)
823{
824 mBWdg = cbw;
825}
826
827void H2WinArg::SetCurrentPIHisto2D(PIHisto2D* h2ddrw)
828{
829 mH2DDrw = h2ddrw;
830}
831
832PIBaseWdgGen* H2WinArg::GetCurrentBaseWdg()
833{
834 return(mBWdg);
835}
836
837PIHisto2D* H2WinArg::GetCurrentPIHisto2D()
838{
839 return(mH2DDrw);
840}
841
842//++
843H2WinArg::H2WinArg(PIMsgHandler* par)
844//
845// Creation de la fenetre de gestion des parametres
846// des dessins des histogrammes 2D. Cette fenetre de
847// dialogue est partagee par tous les widget de dessin
848// des histogrammes 2D. Pour faire apparaitre la fenetre
849// tapez ALT-O.
850//--
851//++
852//| - Menu 1: Choix du type de display
853//| Carres variables, nuages de points, caracteres a la hbook2
854//| et carres de tailles fixe (couleur ou niveauz de gris).
855//| - Menu 2: Choix du type d'echelle
856//| Lineaire ou logarithmique
857//| - Menu 3: Choix de la couleur
858//| noir et blanc, niveau de gris et couleurs diverses.
859//| - Champ texte Dyn: Pour donner la dynamique, si min>=max
860//| alors prend le min et le max de l'histogramme
861//| (cf PIHisto2D::UseDyn)
862//| - Champ texte Frac: fraction mini et maxi
863//| (cf PIHisto2D::UseFrac)
864//| - Champ texte LogScal: niveau de scaling pour le choix d'une
865//| echelle logarithmique (cf PIHisto2D::UseScale)
866//--
867//++
868//| - Curseur interactif PerPt: pourcentage de points a dessiner
869//| dans chaque bin (cf PIHisto2D::UseDisplay)
870//| - Bouton Apply: dessiner avec les options affichees
871//| - Bouton Dismiss: fermeture de la fenetre de dialogue.
872//| - Bouton Get: re-prendre les valeurs de display stoquees
873//| pour un histogramme donne.
874//| - Bouton Print: Imprimer les caracteristiques du display
875//| et de l'histogramme.
876//--
877: PIWindow((PIMsgHandler *)par,"H2D-Options",PIWK_dialog,250,260,150,150)
878, mFgCol(false), mCmap(CMAP_GREYINV32), mRevCmap(false)
879, mTypScal(0) , mLogScale(10.)
880, mTypDisp(0) , mFPoints(0.5)
881, mHMin(1.) , mHMax(-1.)
882, mFracMin(0.1), mFracMax(0.9)
883{
884if(dbg) printf("H2WinArg::H2WinArg %p par=%p\n",this,par);
885
886// Taille automatique
887int bsx, bsy;
888PIApplicationPrefCompSize(bsx, bsy); // environ 6 lettres
889int spx = (bsx>=10) ? bsx/10 : 1; // intervalle entre lettres X
890int spy = (bsy>=5) ? bsy/5 : 1; // intervalle entre lettres Y
891int wszx = 5*spx+bsx+int(2.5*bsx); // Taille fenetre en X
892int wszy = 11*spy+int(8.5*bsy); // Taille fenetre en Y
893SetSize(wszx, wszy);
894
895// menu du style de display des bins
896 int cpx = 2*spx, cpy = 2*spy;
897mOPop[0] = new PIOptMenu(this,"optmen-h2d-1",2*bsx,bsy,cpx,cpy);
898mOPop[0]->AppendItem("Carres Var." ,6101);
899mOPop[0]->AppendItem("....." ,6102);
900mOPop[0]->AppendItem(".+12..Z*" ,6103);
901mOPop[0]->AppendItem("Carres Pleins",6104);
902mOPop[0]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
903
904// Menu du choix de la dynamique
905 cpy += bsy+spy;
906mOPop[1] = new PIOptMenu(this,"optmen-h2d-2",2*bsx,bsy,cpx,cpy);
907mOPop[1]->AppendItem("Lineaire",6201);
908mOPop[1]->AppendItem("Log10" ,6202);
909mOPop[1]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
910
911// Menu du choix de la table des couleurs
912 cpy += bsy+spy;
913mOPop[2] = new PIOptMenu(this,"optmen-h2d-3",2*bsx,bsy,cpx,cpy);
914mOPop[2]->AppendItem("Black&White",7000);
915mCasc[0] = new PIMenu(mOPop[2]->Menu(),"PIStd-128Col");
916mCasc[1] = new PIMenu(mOPop[2]->Menu(), "PIUniCol32");
917mCasc[2] = new PIMenu(mOPop[2]->Menu(),"MIDAS-CMap");
918int kcc,nsct1=5,nsct2=9,nsct3=17,nsct4=PIColorMap::NumberStandardColorMaps()-2;
919for(kcc=0; kcc<nsct1; kcc++)
920 mOPop[2]->AppendItem(PIColorMap::GetStandardColorMapName(kcc).c_str(),7001+kcc);
921for(kcc=nsct1; kcc<nsct2; kcc++)
922 mCasc[0]->AppendItem(PIColorMap::GetStandardColorMapName(kcc).c_str(),7001+kcc);
923mOPop[2]->AppendPDMenu(mCasc[0]);
924for(kcc=nsct2; kcc<nsct3; kcc++)
925 mCasc[1]->AppendItem(PIColorMap::GetStandardColorMapName(kcc).c_str(),7001+kcc);
926mOPop[2]->AppendPDMenu(mCasc[1]);
927for(kcc=nsct3; kcc<nsct4; kcc++)
928 mCasc[2]->AppendItem(PIColorMap::GetStandardColorMapName(kcc).c_str(),7001+kcc);
929mOPop[2]->AppendPDMenu(mCasc[2]);
930for(kcc=nsct4; kcc<PIColorMap::NumberStandardColorMaps(); kcc++)
931 mOPop[2]->AppendItem(PIColorMap::GetStandardColorMapName(kcc).c_str(),7001+kcc);
932//mOPop[2]->SetValue(7000);
933mOPop[2]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
934
935// Reverse color map
936 cpy += bsy+spy;
937mCkb = new PICheckBox(this,"Reverse CMap",8001,2*bsx,bsy,cpx,cpy);
938mCkb->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
939
940// Labels et zones de saisie texte
941 cpy += bsy+spy;
942mLab[0] = new PILabel(this," Dyn: ",bsx,bsy,cpx,cpy);
943mLab[0]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
944mText[0] = new PIText(this,"Dynamique",int(2.5*bsx),bsy,cpx+bsx+spx,cpy);
945mText[0]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
946 cpy += bsy+spy;
947mLab[1] = new PILabel(this," Frac: ",bsx,bsy,cpx,cpy);
948mLab[1]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
949mText[1] = new PIText(this,"Fraction",int(2.5*bsx),bsy,cpx+bsx+spx,cpy);
950mText[1]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
951 cpy += bsy+spy;
952mLab[2] = new PILabel(this," LogScal: ",bsx,bsy,cpx,cpy);
953mLab[2]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
954mText[2] = new PIText(this,"LogScale",int(2.5*bsx),bsy,cpx+bsx+spx,cpy);
955mText[2]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
956
957// Labels et curseur mobile
958cpy += bsy+spy;
959mLab[3] = new PILabel(this," PerPt: ",bsx,bsy,cpx,cpy+int(0.25*bsy));
960mLab[3]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
961mPScal = new PIScale(this,"FracPoints",6401,kSDirLtoR
962 ,int(2.5*bsx),int(1.25*bsy),cpx+bsx+spx,cpy);
963mPScal->SetMinMax(0,100);
964mPScal->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
965
966//
967SetText();
968//
969
970// Boutons
971 cpx = 2*bsx+5*spx, cpy = 2*spy;
972mBut[0] = new PIButton(this,"Apply",6001,bsx,bsy,cpx,cpy);
973mBut[0]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
974 cpy += bsy+spy;
975mBut[1] = new PIButton(this,"Dismiss",6002,bsx,bsy,cpx,cpy);
976mBut[1]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
977 cpy += bsy+spy;
978mBut[2] = new PIButton(this,"Get",6003,bsx,bsy,cpx,cpy);
979mBut[2]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
980 cpy += bsy+spy;
981mBut[3] = new PIButton(this,"Print",6004,bsx,bsy,cpx,cpy);
982mBut[3]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
983// FinishCreate();
984}
985
986//++
987H2WinArg::~H2WinArg()
988//
989// Destructeur.
990//--
991{
992int i;
993if(dbg) printf("H2WinArg::~H2WinArg %p\n",this);
994for(i=0;i<3;i++) delete mCasc[i];
995for(i=0;i<3;i++) delete mOPop[i];
996for(i=0;i<4;i++) delete mBut[i];
997for(i=0;i<4;i++) delete mLab[i];
998for(i=0;i<3;i++) delete mText[i];
999delete mCkb;
1000delete mPScal;
1001}
1002
1003//++
1004void H2WinArg::Show()
1005//
1006// Initialisation sur ouverture ALT-O
1007//--
1008{
1009 if(dbg) printf("H2WinArg::Show() mH2DDrw=%p\n",mH2DDrw);
1010 // Pour recuperer les valeurs du Drawer sur lequel on fait ALT-O
1011 PIWindow::Show();
1012 return;
1013}
1014
1015//++
1016void H2WinArg::SetText()
1017//
1018// Gestion des fenetres de saisie de texte et des pop-menus.
1019//--
1020{
1021if(dbg) printf("H2WinArg::SetText()\n");
1022string sdum;
1023char str[256];
1024
1025sprintf(str,"%g %g",mHMin,mHMax);
1026mText[0]->SetText(str);
1027
1028sprintf(str,"%g %g",mFracMin,mFracMax);
1029mText[1]->SetText(str);
1030
1031sprintf(str,"%g",mLogScale);
1032mText[2]->SetText(str);
1033if(mTypScal==1) mText[2]->SetSensitive();
1034 else mText[2]->SetUnSensitive();
1035
1036if(mTypDisp==0) {sdum="Carres Var."; mOPop[0]->SetValueStr(sdum);}
1037else if(mTypDisp==1) {sdum="....."; mOPop[0]->SetValueStr(sdum);}
1038else if(mTypDisp==2) {sdum=".+12..Z*"; mOPop[0]->SetValueStr(sdum);}
1039else if(mTypDisp==3) {sdum="Carres Pleins"; mOPop[0]->SetValueStr(sdum);}
1040
1041if(mTypScal==0) {sdum="Lineaire"; mOPop[1]->SetValueStr(sdum);}
1042else if(mTypScal==1) {sdum="Log10"; mOPop[1]->SetValueStr(sdum);}
1043
1044if(!mFgCol) {mOPop[2]->SetValue(7000);}
1045else {
1046 for(int kk=0;kk<PIColorMap::NumberStandardColorMaps();kk++)
1047 if(mCmap == PIColorMap::GetStandardColorMapId(kk))
1048 {mOPop[2]->SetValue(7001+kk); break;}
1049}
1050mCkb->SetState(mRevCmap);
1051
1052mPScal->SetValue(int(mFPoints*100.));
1053if(mTypDisp==1) mPScal->SetSensitive();
1054 else mPScal->SetUnSensitive();
1055}
1056
1057//++
1058void H2WinArg::Process(PIMessage msg, PIMsgHandler* sender, void*)
1059//
1060// Gestions des messages.
1061//--
1062{
1063if(dbg) printf("H2WinArg::Process(%d-%d , %p ...) \n"
1064 ,(int)UserMsg(msg),(int)ModMsg(msg),sender);
1065
1066// if(!mH2Wdg) return;
1067if(!mBWdg) return;
1068// PIHisto2D* mpih = mH2Wdg->GetPIHisto();
1069PIHisto2D* mpih = mH2DDrw;
1070if(!mpih) return;
1071
1072int opt = UserMsg(msg);
1073
1074 if(opt == 6101) {mTypDisp = 0;}
1075else if(opt == 6102) {mTypDisp = 1;}
1076else if(opt == 6103) {mTypDisp = 2;}
1077else if(opt == 6104) {mTypDisp = 3;}
1078
1079else if(opt == 6201) {mTypScal = 0;}
1080else if(opt == 6202) {mTypScal = 1;}
1081
1082else if(opt == 7000) {mFgCol = false;}
1083else if(opt >= 7001 && opt <8000) {
1084 int k = opt-7001;
1085 mFgCol = true;
1086 mCmap = PIColorMap::GetStandardColorMapId(k);
1087}
1088
1089else if(opt == 8001) mRevCmap = mCkb->GetState();
1090
1091else if(opt == 6401) mFPoints = mPScal->GetValue()/100.;
1092
1093else if(opt==6001) {
1094 sscanf(mText[0]->GetText().c_str(),"%lf %lf",&mHMin,&mHMax);
1095 sscanf(mText[1]->GetText().c_str(),"%lf %lf",&mFracMin,&mFracMax);
1096 sscanf(mText[2]->GetText().c_str(),"%lf",&mLogScale);
1097 mpih->UseColors(mFgCol,mCmap,mRevCmap);
1098 mpih->UseScale(mTypScal,mLogScale);
1099 mpih->UseDisplay(mTypDisp,mFPoints);
1100 mpih->UseDyn(mHMin,mHMax);
1101 mpih->UseFrac(mFracMin,mFracMax);
1102 mBWdg->Refresh(); // On rafraichit le dessin (tout le PIScDrawWdg)
1103}
1104else if(opt==6002) this->Hide();
1105else if (opt==6003) {
1106 mFgCol = mpih->Color(); mCmap = mpih->ColMap();
1107 mRevCmap = mpih->IsColMapRev();
1108 mTypScal = mpih->TypScale(); mLogScale = mpih->LogScale();
1109 mTypDisp = mpih->TypDisplay(); mFPoints = mpih->FPoints();
1110 mHMin = mpih->HMin(); mHMax = mpih->HMax();
1111 mFracMin = mpih->FMin(); mFracMax = mpih->FMax();
1112}
1113else if(opt==6004) mpih->Print(2);
1114
1115SetText();
1116
1117if(dbg) {
1118 printf("H2WinArg::Process opt=%d col=%d,%d,%d scal=%d disp=%d npt=%g\n"
1119 ,opt,(int)mFgCol,(int)mCmap,(int)mRevCmap,mTypScal,mTypDisp,mFPoints);
1120 printf(" min,max= %g,%g frac= %g,%g logsc= %g\n"
1121 ,mHMin,mHMax,mFracMin,mFracMax,mLogScale);
1122}
1123
1124}
Note: See TracBrowser for help on using the repository browser.