Commit 9b97b230 authored by Daniel Hynds's avatar Daniel Hynds
Browse files

added mc particle class identical to allpix-squared output writer

parent d2939b83
......@@ -23,6 +23,7 @@ ROOT_GENERATE_DICTIONARY(CorryvreckanObjectsDictionary
${CMAKE_CURRENT_SOURCE_DIR}/SpidrSignal.h
${CMAKE_CURRENT_SOURCE_DIR}/TestBeamObject.h
${CMAKE_CURRENT_SOURCE_DIR}/Track.h
${CMAKE_CURRENT_SOURCE_DIR}/MCParticle.h
MODULE
CorryvreckanObjects
)
......
#ifndef MCPARTICLE_H
#define MCPARTICLE_H 1
#include "TestBeamObject.h"
#include <Math/Point3D.h>
namespace corryvreckan {
class MCParticle : public TestBeamObject {
public:
// Constructors and destructors
MCParticle() = default;
MCParticle(int particle_id, ROOT::Math::XYZPoint local_start_point, ROOT::Math::XYZPoint local_end_point){
m_particle_id = particle_id;
m_local_start_point = local_start_point;
m_local_end_point = local_end_point;
}
// Member variables
int m_particle_id;
ROOT::Math::XYZPoint m_local_start_point;
ROOT::Math::XYZPoint m_local_end_point;
// Member functions
int getID(){return m_particle_id;}
ROOT::Math::XYZPoint getLocalStart(){return m_local_start_point;}
ROOT::Math::XYZPoint getLocalEnd(){return m_local_end_point;}
// ROOT I/O class definition - update version number when you change this class!
ClassDef(MCParticle, 1)
};
// Vector type declaration
using MCParticles = std::vector<MCParticle*>;
} // namespace corryvreckan
#endif // MCPARTICLE_H
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment