8#include "ROOT/REveManager.hxx"
9#include "ROOT/REveDataClasses.hxx"
10#include <ROOT/REveScene.hxx>
11#include <ROOT/REveViewer.hxx>
12#include <ROOT/REveGeoShape.hxx>
31 for (
int i = 1; i <=
N; ++i)
33 double pt =
r.Uniform(0.5, 10);
34 double eta =
r.Uniform(-2.55, 2.55);
45 px, py, pz,
std::sqrt(px*px + py*py + pz*pz + 80*80),
48 int pdg = 11 * (
r.Integer(2) > 0 ? 1 : -1);
56 auto tbl =
new REX::REveDataTable();
58 tbl->SetCollection(col);
61 auto c =
new REX::REveDataColumn(
"pt");
63 c->SetExpressionAndType(
"std::abs(i.Pt())", REX::REveDataColumn::FT_Double);
66 auto c =
new REX::REveDataColumn(
"phi");
68 c->SetExpressionAndType(
"i.Phi()", REX::REveDataColumn::FT_Double);
73 auto c =
new REX::REveDataColumn(
"eta");
75 c->SetExpressionAndType(
"i.Eta()", REX::REveDataColumn::FT_Double);
79 auto scene =
eveMng->SpawnNewScene(
"Table",
"Table");
80 scene->AddElement(tbl);
81 auto view =
eveMng->SpawnNewViewer(
"Table",
"Table");
82 view->AddScene(scene);
87 eveMng = REX::REveManager::Create();
89 REX::REveElement* defaultViewer = (*
eveMng->GetViewers()->BeginChildren());
90 defaultViewer->SetRnrSelf(
false);
94 auto col =
new REX::REveDataCollection();
104 col->AddItem(&p, pname.
Data(),
"");
107 col->SetFilterExpr(
"i.Pt() > 1 && std::abs(i.Eta()) < 1");
109 eveMng->GetWorld()->AddElement(col);
R__EXTERN TRandom * gRandom
Description of the dynamic properties of a particle.
This is the base class for the ROOT Random number generators.
const char * Data() const
void Form(const char *fmt,...)
Formats a string using a printf style format descriptor.
constexpr Double_t TwoPi()
std::vector< TParticle > ext_col
REX::REveManager * eveMng
void makeTableScene(REX::REveDataCollection *col)