6#ifndef EVENTDISPLAY_EVENTDISPLAY_H_
7#define EVENTDISPLAY_EVENTDISPLAY_H_
14#include "Framework/EventFile.h"
15#include "TBranchElement.h"
16#include "TEveBrowser.h"
17#include "TEveElement.h"
18#include "TEveEventManager.h"
19#include "TEveManager.h"
20#include "TEveViewer.h"
25#include "TGTextEntry.h"
30namespace eventdisplay {
39 Display(TEveManager* manager,
bool verbose);
51 delete text_box_clusters_coll_name_;
52 delete text_box_sim_thresh_;
53 delete text_box_ecal_rec_hits_coll_name_;
54 delete text_box_hcal_rec_hits_coll_name_;
55 delete text_box_tracker_hits_coll_name_;
56 delete text_box_ecal_score_plane_branch_;
121 std::string
getText(TGTextEntry* box)
const {
return box->GetText(); }
126 template <
typename EventObjectType>
127 void draw(
const std::string& name) {
132 std::cout <<
"[ Display ] : Loaded '" << name
133 <<
"' into memory as a EVE object." << std::endl;
136 std::cerr <<
"[ Display ] : Unable to draw an event object." << std::endl;
137 std::cerr <<
"[" << e.
name() <<
"] : " << e.
message() <<
"\n"
138 <<
" at " << e.
module() <<
":" << e.
line() <<
" in "
169 TGTextEntry* text_box_clusters_coll_name_;
170 TGTextEntry* text_box_sim_thresh_;
171 TGTextEntry* text_box_ecal_rec_hits_coll_name_;
172 TGTextEntry* text_box_hcal_rec_hits_coll_name_;
173 TGTextEntry* text_box_tracker_hits_coll_name_;
174 TGTextEntry* text_box_ecal_score_plane_branch_;
Header file for EveDetectorGeometry Class.
Class implementing an event buffer system for storing event data.
TEveManager * manager_
event display manager
std::unique_ptr< framework::EventFile > the_file_
Handle to input file we will be reading.
Display(TEveManager *manager, bool verbose)
Constructor Builds window frame and and control panel.
std::string clusters_coll_name_
name of ecal clusters collection in event tree
bool setSimThresh()
Sets threshold energy from a SimParticle to be drawn from text box.
virtual ~Display()
Destructor Deletes hanging pointers from constructor and closes the TFile.
void getTrackerHitsCollInput()
Gets trackerHits collection name from text box.
Objects objects_
drawing methods for event objects
void getHcalRecHitsCollInput()
Gets hcalRecHits collection name from text box.
void nextEvent()
Goes forward one event unless the current event number equals the maximum event number.
std::string hcal_rec_hits_coll_name_
name of hcalRecHits collection in event tree
bool setFile(const TString file)
Opens input file and attempts to obtain the necessary information from it.
framework::Event the_event_
Event bus for reading from input file.
void draw(const std::string &name)
Templated draw method.
void getEcalSimParticlesCollInput()
Gets ECAL Sim Particles Branch name from text box.
void getClustersCollInput()
Gets clusters collection name from text box.
std::string getText(TGTextEntry *box) const
Get the text from the input text box.
EveDetectorGeometry * the_detector_
drawing methods for the detector geometry
void colorClusters()
Colors cluster objects and redraws.
std::string tracker_hits_coll_name_
name of recoil hitss collection in event tree
void getEcalRecHitsCollInput()
Gets ecalRecHits collection name from text box.
std::string ecal_rec_hits_coll_name_
name of ecalRecHits collection in event tree
std::string ecal_sim_particles_coll_name_
name of ecal sim particles collection in
Class that constructs the detector components for the event display.
Drawing methods for event objects.
void draw(T o)
Not implemented.
Implements an event buffer system for storing event data.
const T & getObject(const std::string &collectionName, const std::string &passName) const
Get an general object from the event bus.
Standard base exception class with some useful output information.
const std::string & function() const
Get the function name where the exception occurred.
int line() const
Get the source line number where the exception occurred.
const std::string & message() const
Get the message of the exception.
const std::string & name() const
Get the name of the exception.
const std::string & module() const
Get the source filename where the exception occurred.