11 #include "cetlib_except/exception.h" 20 #include "nuevdb/EventDisplayBase/EventHolder.h" 21 #include "nuevdb/EventDisplayBase/View2D.h" 31 static const int kQ = 0;
32 static const int kTQ = 1;
45 :
DrawingPad(nm, ti, x1, y1, x2, y2), fWire(wire), fPlane(plane), fFrameHist(0)
48 unsigned int planes = geo->
Nplanes();
52 this->
Pad()->SetLeftMargin(0.050);
53 this->
Pad()->SetRightMargin(0.050);
55 this->
Pad()->SetTopMargin(0.005);
56 this->
Pad()->SetBottomMargin(0.110);
60 if (planes == 2 &&
fPlane > 0) {
61 this->
Pad()->SetTopMargin(0.110);
62 this->
Pad()->SetBottomMargin(0.010);
64 else if (planes > 2) {
66 this->
Pad()->SetTopMargin(0.005);
67 this->
Pad()->SetBottomMargin(0.010);
70 this->
Pad()->SetTopMargin(0.110);
71 this->
Pad()->SetBottomMargin(0.010);
79 this->
Pad()->SetTopMargin(0);
80 this->
Pad()->SetBottomMargin(0.2);
82 if (opts ==
"Q") {
fTQ =
kQ; }
85 fView =
new evdb::View2D();
117 const art::Event*
evt = evdb::EventHolder::Instance()->GetEvent();
150 if (maxHiVal > std::numeric_limits<float>::lowest())
160 static const std::string defaultDrawOptions =
"HIST same";
165 fWireDrawerTool->Draw(defaultDrawOptions.c_str(), maxLowVal, maxHiVal);
261 double qxloraw = cst->
fRawQLow[(size_t)sigType];
262 double qxhiraw = cst->
fRawQHigh[(size_t)sigType];
268 fFrameHist =
new TH1F(
"fFrameHist",
";t [ticks];[ADC]", 2, 0., 1.);
273 fFrameHist =
new TH1F(
"fFrameHist",
";t [ticks];q [ADC]", (
int)tqxhi, tqxlo, tqxhi + tqxlo);
275 default:
throw cet::exception(
"TQPad") << __func__ <<
": unexpected quantity #" <<
fTQ <<
"\n";
IWFHitDrawerPtr fHitDrawerTool
An instance of the tool to draw hits.
std::vector< double > fRawQLow
low edge of ADC values for drawing raw digits
unsigned int fTPC
TPC number to draw, typically set by TWQProjectionView.
unsigned int fPlane
Which plane in the detector.
TH1F * fFrameHist
A dummy histogram to define the axes.
int fDrawRawDataOrCalibWires
0 for raw
IWaveformDrawerPtr fWireDrawerTool
An instance of the tool to draw hits.
The data type to uniquely identify a Plane.
fhicl::ParameterSet fRawDigitDrawerParams
FHICL parameters for the RawDigit waveform display.
Drawing pad for time or charge histograms.
art framework interface to geometry description
evdb::View2D * fView
Superimpose scale on 1D histo.
unsigned int Nplanes(unsigned int tpc=0, unsigned int cstat=0) const
Returns the total number of wire planes in the specified TPC.
RawDataDrawer * RawDataDraw()
unsigned int fCryostat
Cryostat number to draw, typically set by TWQProjectionView.
enum geo::_plane_sigtype SigType_t
fhicl::ParameterSet fWireDrawerParams
FHICL parameters for the wire drawing.
Base class for event display drawing pads.
geo::TPCID CurrentTPC() const
Returns the current TPC as a TPCID.
double TotalClockTicks() const
static int max(int a, int b)
std::vector< double > fRawQHigh
high edge of ADC values for drawing raw digits
IWaveformDrawerPtr fRawDigitDrawerTool
An instance of the tool to draw hits.
int fTQ
0 = plot shows charge only, 1 = plot shows charge vs time for a wire
raw::ChannelID_t PlaneWireToChannel(WireID const &wireid) const
Returns the ID of the TPC channel connected to the specified wire.
T min(sqlite3 *const db, std::string const &table_name, std::string const &column_name)
TPad * fPad
The ROOT graphics pad.
fhicl::ParameterSet fHitDrawerParams
FHICL parameters for the hit drawing.
unsigned int ChannelID_t
Type representing the ID of a readout channel.
LArSoft geometry interface.
TQPad(const char *nm, const char *ti, double x1, double y1, double x2, double y2, const char *opt, unsigned int plane, unsigned int wire)
cet::coded_exception< error, detail::translate > exception