本文整理汇总了C++中KVACQParam::GetLabel方法的典型用法代码示例。如果您正苦于以下问题:C++ KVACQParam::GetLabel方法的具体用法?C++ KVACQParam::GetLabel怎么用?C++ KVACQParam::GetLabel使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类KVACQParam
的用法示例。
在下文中一共展示了KVACQParam::GetLabel方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: SetCalibrators
void KVVAMOSDetector::SetCalibrators()
{
// Setup the calibrators for this detector. Call once name
// has been set.
// The calibrators are KVFunctionCal.
// By default the all the calibration functions are first-degree
// polynomial function and the range [Xmin,Xmax]=[0,4096].
// Here the calibrator are not ready (KVFunctionCal::GetStatus()).
// You have to give the parameters and change the status
// (see KVFunctionCal::SetParameter(...) and KVFunctionCal::SetStatus(...))
TIter nextpar(GetACQParamList());
KVACQParam* par = NULL;
Double_t maxch = 16384.; // 14 bits
TString calibtype("ERROR");
while ((par = (KVACQParam*)nextpar())) {
Bool_t isTparam = kFALSE;
if (par->IsType("E")) {
calibtype = "channel->MeV";
} else if (par->IsType("Q")) {
calibtype = "channel->Volt";
maxch = 4096.; // 12 bits
} else if (par->GetType()[0] == 'T') {
isTparam = kTRUE;
calibtype = "channel->ns";
} else continue;
calibtype.Append(" ");
calibtype.Append(par->GetName());
TF1* func = new TF1(calibtype.Data(), "pol1", 0., maxch);
KVFunctionCal* c = new KVFunctionCal(this, func);
c->SetType(calibtype.Data());
c->SetLabel(par->GetLabel());
c->SetNumber(par->GetNumber());
c->SetUniqueID(par->GetUniqueID());
c->SetACQParam(par);
c->SetStatus(kFALSE);
if (!AddCalibrator(c)) delete c;
else if (isTparam) {
if (!fTlist) fTlist = new TList;
fTlist->Add(par);
if (!fT0list) fT0list = new TList;
fT0list->Add(new KVNamedParameter(par->GetName(), 0.));
}
}
// Define and set to zero the T0 values for time of flight measurment
// from this detector. The time of flight acq parameters are associated
// to gVamos
if (gVamos) {
TIter next_vacq(gVamos->GetVACQParams());
while ((par = (KVACQParam*)next_vacq())) {
if ((par->GetType()[0] == 'T') && IsStartForT(par->GetName() + 1)) {
if (!fTlist) fTlist = new TList;
fTlist->Add(par);
if (!fT0list) fT0list = new TList;
fT0list->Add(new KVNamedParameter(par->GetName(), 0.));
}
}
}
}