A drawing pad for an XZ or ZY. More...
#include "/cvmfs/nova-development.opensciencegrid.org/novasoft/releases/N21-03-08/EventDisplay/TZProjPad.h"
Public Member Functions | |
TZProjPad (const char *nm, const char *ti, double x1, double y1, double x2, double y2, const char *opt) | |
~TZProjPad () | |
void | Draw (const char *opt=0, bool *rezoom=0) |
void | GetWrange (int *i1, int *i2) const |
void | GetZrange (int *i1, int *i2) const |
void | GetWrangeCm (float *i1, float *i2) const |
void | GetZrangeCm (float *i1, float *i2) const |
void | GetZBoundCm (float *i1, float *i2) const |
void | GetWBoundCm (float *i1, float *i2) const |
void | SetZrange (int i1, int i2) |
void | SetWrange (int i1, int i2) |
void | SetZrangeCm (float i1, float i2) |
void | SetWrangeCm (float i1, float i2) |
TPad * | Pad () |
HeaderDrawer * | HeaderDraw () |
GeometryDrawer * | GeometryDraw () |
SimulationDrawer * | SimulationDraw () |
RawDataDrawer * | RawDataDraw () |
RecoBaseDrawer * | RecoBaseDraw () |
Public Attributes | |
unsigned int | fLastRun |
Last run number shown. More... | |
unsigned int | fLastEvt |
Last event number shown. More... | |
int | fLastSlice |
Last slice number shown. More... | |
int | fLastZoom |
Last zoom option applied. More... | |
int | fDetId |
Detector display is configured for. More... | |
int | fXorY |
Which view? 0 = X vs. Z, 1 = Y vs. Z. More... | |
TH2F * | fHisto |
Histogram to draw objects on. More... | |
evdb::View2D * | fView |
Collection of graphics objects to render. More... | |
Protected Attributes | |
TPad * | fPad |
The ROOT graphics pad. More... | |
HeaderDrawer * | fHeaderDraw |
Drawer for event header info. More... | |
GeometryDrawer * | fGeometryDraw |
Drawer for detector geometry. More... | |
SimulationDrawer * | fSimulationDraw |
Drawer for simulation objects. More... | |
RawDataDrawer * | fRawDataDraw |
Drawer for raw data. More... | |
RecoBaseDrawer * | fRecoBaseDraw |
Drawer for recobase objects. More... | |
Private Member Functions | |
void | AutoZoom () |
void | AutoZoomTruth (const art::Event *evt) |
void | AutoZoomSlice (const art::Event *evt) |
void | AutoZoomBox (const art::Event *evt) |
void | AutoZoomHelper (double xmin, double xmax, double ymin, double ymax, double zmin, double zmax, double safety) |
void | ShowFull () |
void | ShowPartial () |
void | LayoutHisto () |
A drawing pad for an XZ or ZY.
Definition at line 32 of file TZProjPad.h.
evd::TZProjPad::TZProjPad | ( | const char * | nm, |
const char * | ti, | ||
double | x1, | ||
double | x2, | ||
double | y1, | ||
double | y2, | ||
const char * | opt | ||
) |
Create a pad showing a single X-Z or Y-Z projection of the detector
nm | : Name of the pad |
ti | : Title of the pad |
x1 | : Location of left edge of pad (0-1) |
x2 | : Location of right edge of pad (0-1) |
y1 | : Location of bottom edge of pad (0-1) |
y2 | : Location of top edge of pad (0-1) |
opt | : Options. Include 'x', 'y' for xz or yz projections |
Definition at line 66 of file TZProjPad.cxx.
References geo::GeometryBase::DetId(), fDetId, fHisto, fView, fXorY, evd::kX, evd::kY, LayoutHisto(), evd::DrawingPad::Pad(), and string.
evd::TZProjPad::~TZProjPad | ( | ) |
Definition at line 108 of file TZProjPad.cxx.
|
private |
Automatically zoom the view to a size just larger than the events. Also ensures that the aspect ratio is the same for the XZ and YZ projections.
Definition at line 224 of file TZProjPad.cxx.
References AutoZoomHelper(), evd::RawDataDrawer::GetLimits(), evd::DrawingPad::RawDataDraw(), xmax, make_mec_shifts_plots::xmin, ymax, ymin, and make_true_q0q3_plots::zmax.
Referenced by Draw().
|
private |
Definition at line 273 of file TZProjPad.cxx.
References ana::assert(), AutoZoomHelper(), evd::SliceNavigator::GetBox(), xmax, make_mec_shifts_plots::xmin, ymax, ymin, and make_true_q0q3_plots::zmax.
Referenced by Draw().
|
private |
Definition at line 288 of file TZProjPad.cxx.
References dz, fHisto, fXorY, std::max(), xmax, and ymax.
Referenced by AutoZoom(), AutoZoomBox(), AutoZoomSlice(), and AutoZoomTruth().
|
private |
Definition at line 260 of file TZProjPad.cxx.
References ana::assert(), AutoZoomHelper(), evd::SliceNavigator::GetBounds(), xmax, make_mec_shifts_plots::xmin, ymax, ymin, and make_true_q0q3_plots::zmax.
Referenced by Draw().
|
private |
Definition at line 237 of file TZProjPad.cxx.
References ana::assert(), AutoZoomHelper(), rb::CellHit::Cell(), evd::SimulationDrawer::GetLimits(), art::DataViewImpl::getManyByType(), MECModelEnuComparisons::i, calib::j, rb::CellHit::Plane(), evd::DrawingPad::SimulationDraw(), xmax, make_mec_shifts_plots::xmin, ymax, ymin, and make_true_q0q3_plots::zmax.
Referenced by Draw().
void evd::TZProjPad::Draw | ( | const char * | opt = 0 , |
bool * | rezoom = 0 |
||
) |
Definition at line 116 of file TZProjPad.cxx.
References AutoZoom(), AutoZoomBox(), AutoZoomSlice(), AutoZoomTruth(), evdb::View2D::Clear(), evdb::View2D::Draw(), art::EventID::event(), evt, fHisto, fLastEvt, fLastRun, fLastSlice, fLastZoom, evd::SimulationDrawer::FLSHit2D(), evd::GeometryDrawingOptions::fOutline, evd::DrawingPad::fPad, fView, fXorY, evd::GeometryDrawingOptions::fZoom, evd::DrawingPad::GeometryDraw(), evdb::EventHolder::GetEvent(), galleryMaker::grid, art::Event::id(), evdb::EventHolder::Instance(), evd::GeometryDrawingOptions::kOUTLINE_GRID, evd::GeometryDrawingOptions::kZOOM_HITS, evd::GeometryDrawingOptions::kZOOM_PARTIAL, evd::GeometryDrawingOptions::kZOOM_SLICE, evd::GeometryDrawingOptions::kZOOM_SLICEBOX, evd::GeometryDrawingOptions::kZOOM_TRUTH, LayoutHisto(), evd::SimulationDrawer::MCTruthTrajectories2D(), evd::SimulationDrawer::MCTruthVectors2D(), evd::SimulationDrawer::MCTruthVertices2D(), evd::DrawingPad::RawDataDraw(), evd::DrawingPad::RecoBaseDraw(), art::Event::run(), ShowFull(), ShowPartial(), evd::DrawingPad::SimulationDraw(), and APDHVSetting::temp.
Referenced by evd::XZYZProjectionsView::Draw(), and evd::XZYZProjectionsView::XZYZProjectionsView().
|
inherited |
Provide access to the drawer for the detector geometry
Definition at line 73 of file DrawingPad.cxx.
References evd::DrawingPad::fGeometryDraw.
Referenced by evd::Display3DPad::Draw(), Draw(), and evd::DrawingPad::Pad().
void evd::TZProjPad::GetWBoundCm | ( | float * | i1, |
float * | i2 | ||
) | const |
Definition at line 396 of file TZProjPad.cxx.
References allInOneTrainingPlots::axis, and fHisto.
Referenced by evd::XZYZProjectionsView::FixAspectRatio().
void evd::TZProjPad::GetWrangeCm | ( | float * | i1, |
float * | i2 | ||
) | const |
Definition at line 369 of file TZProjPad.cxx.
References allInOneTrainingPlots::axis, and fHisto.
Referenced by evd::XZYZProjectionsView::FixAspectRatio().
void evd::TZProjPad::GetZBoundCm | ( | float * | i1, |
float * | i2 | ||
) | const |
Definition at line 387 of file TZProjPad.cxx.
References allInOneTrainingPlots::axis, and fHisto.
Referenced by evd::XZYZProjectionsView::FixAspectRatio().
Definition at line 362 of file TZProjPad.cxx.
References fHisto.
Referenced by evd::XZYZProjectionsView::RangeChanged().
void evd::TZProjPad::GetZrangeCm | ( | float * | i1, |
float * | i2 | ||
) | const |
Definition at line 378 of file TZProjPad.cxx.
References allInOneTrainingPlots::axis, and fHisto.
Referenced by evd::XZYZProjectionsView::FixAspectRatio().
|
inherited |
Provide access to the drawer for the event header
Definition at line 64 of file DrawingPad.cxx.
References evd::DrawingPad::fHeaderDraw.
Referenced by evd::HeaderPad::Draw(), evd::Display3DPad::Draw(), and evd::DrawingPad::Pad().
|
private |
Definition at line 436 of file TZProjPad.cxx.
References geo::GeometryBase::DetHalfHeight(), geo::GeometryBase::DetHalfWidth(), geo::GeometryBase::DetId(), geo::GeometryBase::DetLength(), fDetId, evd::GeometryDrawingOptions::fFlip, fHisto, evd::GeometryDrawingOptions::fLabel, fXorY, evd::GeometryDrawingOptions::kFLIP_X, evd::GeometryDrawingOptions::kFLIP_Z, evd::GeometryDrawingOptions::kLABEL_COMPASS, novadaq::cnv::kUNKNOWN_DET, evd::kZsf, and evd::GeoTransform::Z().
Referenced by Draw(), and TZProjPad().
|
inlineinherited |
Definition at line 27 of file DrawingPad.h.
References evd::DrawingPad::fPad, evd::DrawingPad::GeometryDraw(), evd::DrawingPad::HeaderDraw(), evd::DrawingPad::RawDataDraw(), evd::DrawingPad::RecoBaseDraw(), and evd::DrawingPad::SimulationDraw().
Referenced by evd::HardwarePad::Config(), evd::HeaderPad::Draw(), evd::MCBriefPad::Draw(), evd::TQPad::Draw(), evd::Display3DPad::Draw(), evd::XZYZProjectionsView::FixAspectRatio(), evd::HardwarePad::HardwarePad(), evd::MCBriefPad::MCBriefPad(), evd::XZYZProjectionsView::RangeChanged(), evd::XZYZProjectionsView::SetAspectRatio(), evd::TQPad::TQPad(), TZProjPad(), and evd::XZYZProjectionsView::XZYZProjectionsView().
|
inherited |
Provide access to the drawer for the RawData classes
Definition at line 91 of file DrawingPad.cxx.
References evd::DrawingPad::fRawDataDraw.
Referenced by AutoZoom(), evd::TQPad::Draw(), evd::HardwarePad::Draw(), evd::Display3DPad::Draw(), Draw(), and evd::DrawingPad::Pad().
|
inherited |
Provide access to the drawer for RecoBase classes
Definition at line 101 of file DrawingPad.cxx.
References evd::DrawingPad::fRecoBaseDraw.
Referenced by evd::TQPad::Draw(), evd::Display3DPad::Draw(), Draw(), and evd::DrawingPad::Pad().
void evd::TZProjPad::SetWrangeCm | ( | float | i1, |
float | i2 | ||
) |
Definition at line 428 of file TZProjPad.cxx.
References allInOneTrainingPlots::axis, and fHisto.
Referenced by evd::XZYZProjectionsView::FixAspectRatio().
Definition at line 406 of file TZProjPad.cxx.
References fHisto.
Referenced by evd::XZYZProjectionsView::RangeChanged().
void evd::TZProjPad::SetZrangeCm | ( | float | i1, |
float | i2 | ||
) |
Definition at line 413 of file TZProjPad.cxx.
References allInOneTrainingPlots::axis, and fHisto.
Referenced by evd::XZYZProjectionsView::FixAspectRatio().
|
private |
Definition at line 334 of file TZProjPad.cxx.
References geo::GeometryBase::DetHalfHeight(), geo::GeometryBase::DetHalfWidth(), geo::GeometryBase::DetLength(), fHisto, fXorY, MECModelEnuComparisons::g, evd::kZsf, xmax, make_mec_shifts_plots::xmin, evd::GeoTransform::XYZ(), ymax, ymin, and make_true_q0q3_plots::zmax.
Referenced by Draw().
|
private |
Definition at line 312 of file TZProjPad.cxx.
References geo::GeometryBase::DetHalfHeight(), geo::GeometryBase::DetHalfWidth(), geo::GeometryBase::DetLength(), fHisto, fXorY, evd::GeometryDrawingOptions::fZRange, MECModelEnuComparisons::g, evd::kZsf, xmax, make_mec_shifts_plots::xmin, evd::GeoTransform::XYZ(), ymax, ymin, and make_true_q0q3_plots::zmax.
Referenced by Draw().
|
inherited |
Provide access to the drawer for the Simulation classes
Definition at line 82 of file DrawingPad.cxx.
References evd::DrawingPad::fSimulationDraw.
Referenced by AutoZoomTruth(), evd::MCBriefPad::Draw(), evd::TQPad::Draw(), evd::Display3DPad::Draw(), Draw(), and evd::DrawingPad::Pad().
int evd::TZProjPad::fDetId |
Detector display is configured for.
Definition at line 71 of file TZProjPad.h.
Referenced by LayoutHisto(), and TZProjPad().
|
protectedinherited |
Drawer for detector geometry.
Definition at line 39 of file DrawingPad.h.
Referenced by evd::DrawingPad::GeometryDraw(), and evd::DrawingPad::~DrawingPad().
|
protectedinherited |
Drawer for event header info.
Definition at line 38 of file DrawingPad.h.
Referenced by evd::DrawingPad::HeaderDraw(), and evd::DrawingPad::~DrawingPad().
TH2F* evd::TZProjPad::fHisto |
Histogram to draw objects on.
Definition at line 73 of file TZProjPad.h.
Referenced by AutoZoomHelper(), Draw(), GetWBoundCm(), GetWrange(), GetWrangeCm(), GetZBoundCm(), GetZrange(), GetZrangeCm(), LayoutHisto(), evd::XZYZProjectionsView::SetAspectRatio(), SetWrange(), SetWrangeCm(), SetZrange(), SetZrangeCm(), ShowFull(), ShowPartial(), TZProjPad(), and ~TZProjPad().
unsigned int evd::TZProjPad::fLastEvt |
unsigned int evd::TZProjPad::fLastRun |
int evd::TZProjPad::fLastSlice |
int evd::TZProjPad::fLastZoom |
|
protectedinherited |
The ROOT graphics pad.
Definition at line 37 of file DrawingPad.h.
Referenced by evd::MCBriefPad::Draw(), evd::HardwarePad::Draw(), evd::Display3DPad::Draw(), Draw(), evd::DrawingPad::DrawingPad(), evd::DrawingPad::Pad(), and evd::DrawingPad::~DrawingPad().
|
protectedinherited |
Drawer for raw data.
Definition at line 41 of file DrawingPad.h.
Referenced by evd::DrawingPad::RawDataDraw(), and evd::DrawingPad::~DrawingPad().
|
protectedinherited |
Drawer for recobase objects.
Definition at line 42 of file DrawingPad.h.
Referenced by evd::DrawingPad::RecoBaseDraw(), and evd::DrawingPad::~DrawingPad().
|
protectedinherited |
Drawer for simulation objects.
Definition at line 40 of file DrawingPad.h.
Referenced by evd::DrawingPad::SimulationDraw(), and evd::DrawingPad::~DrawingPad().
evdb::View2D* evd::TZProjPad::fView |
Collection of graphics objects to render.
Definition at line 74 of file TZProjPad.h.
Referenced by Draw(), TZProjPad(), and ~TZProjPad().
int evd::TZProjPad::fXorY |
Which view? 0 = X vs. Z, 1 = Y vs. Z.
Definition at line 72 of file TZProjPad.h.
Referenced by AutoZoomHelper(), Draw(), LayoutHisto(), ShowFull(), ShowPartial(), and TZProjPad().