11 : m_energy(e), m_et(et), m_isTallest(
false) {
21 for (
size_t i = 0;
i < 4; ++
i) {
23 corners[
i + 4].fZ = corners[
i].fZ +
scale;
25 m_tower->SetVertex(j, corners[j]);
36 m_tower =
new TEveBox(
"EcalRecHitTower");
37 std::vector<TEveVector> towerCorners = corners;
50 m_ls =
new TEveStraightLineSet(
"EcalRecHitLineSet");
55 m_ls->AddLine(c.fX, c.fY, c.fZ, c.fX, c.fY, c.fZ);
56 m_ls->AddLine(c.fX, c.fY, c.fZ, c.fX, c.fY, c.fZ);
57 m_ls->AddLine(c.fX, c.fY, c.fZ, c.fX, c.fY, c.fZ);
58 m_ls->AddLine(c.fX, c.fY, c.fZ, c.fX, c.fY, c.fZ);
61 m_ls->SetMarkerStyle(1);
62 m_ls->AddLine(c.fX, c.fY, c.fZ, c.fX, c.fY, c.fZ);
63 m_ls->AddMarker(0, 0.);
80 for (
unsigned int i = 0;
i < 4; ++
i) {
84 m_tower->SetVertex(
i, data[0], data[1], 0);
85 m_tower->SetVertex(
i + 4, data[0], data[1], scale);
89 float s =
log(1 + val) / maxLogVal;
92 float z = scale * 1.001;
93 setLine(0, c.fX - d, c.fY - d, z, c.fX + d, c.fY - d, z);
94 setLine(1, c.fX + d, c.fY - d, z, c.fX + d, c.fY + d, z);
95 setLine(2, c.fX + d, c.fY + d, z, c.fX - d, c.fY + d, z);
96 setLine(3, c.fX - d, c.fY + d, z, c.fX - d, c.fY - d, z);
100 setLine(4, c.fX - d, c.fY - d, z, c.fX + d, c.fY + d, z);
101 setLine(5, c.fX - d, c.fY + d, z, c.fX + d, c.fY - d, z);
104 TEveStraightLineSet::Marker_t *
m = ((TEveStraightLineSet::Marker_t *)(
m_ls->GetMarkerPlex().Atom(0)));
111 m_ls->StampTransBBox();
118 TEveStraightLineSet::Line_t *
l = ((TEveStraightLineSet::Line_t *)(
m_ls->GetLinePlex().Atom(idx)));
142 m_ls->AddLine(x1, y1, z1, x2, y2, z2);
147 m_ls->AddLine(v1.fX, v1.fY, v1.fZ, v2.fX, v2.fY, v2.fZ);
static std::vector< std::string > checklist log
const edm::EventSetup & c
void setLine(int idx, float x1, float y1, float z1, float x2, float y2, float z2)
void addLine(float x1, float y1, float z1, float x2, float y2, float z2)
void buildTower(const std::vector< TEveVector > &corners, const FWViewContext *vc)
void setupAddElement(TEveElement *el, TEveElement *parent, bool set_color=true) const
FWViewEnergyScale * getEnergyScale() const
void setupEveBox(std::vector< TEveVector > &corners, float scale)
float getScaleFactorLego() const
FWPFLegoRecHit(const std::vector< TEveVector > &corners, TEveElement *comp, FWProxyBuilderBase *pb, const FWViewContext *vc, float e, float et)
void setIsTallest(bool b)
void buildLineSet(const std::vector< TEveVector > &corners, const FWViewContext *vc)
char data[epos_bytes_allocation]
void updateScale(const FWViewContext *vc, float maxLogVal)
TEveStraightLineSet * m_ls