13 #include "TEveStraightLineSet.h"
14 #include "TEveCompound.h"
46 double yAlignmentFrame = 3.49;
47 double alignmentPinToFirstWire;
50 if (ring == 1 || ring == 4) {
51 alignmentPinToFirstWire = 1.065;
52 yAlignmentFrame = 0.0;
56 alignmentPinToFirstWire = 2.85;
59 else if (station == 4 && ring == 1)
60 alignmentPinToFirstWire = 3.04;
62 else if (station == 3 && ring == 1)
63 alignmentPinToFirstWire = 2.84;
66 alignmentPinToFirstWire = 2.87;
68 return (yAlignmentFrame - length) + alignmentPinToFirstWire;
82 if (station == 1 && (ring == 1 || ring == 4))
84 if (station == 1 && ring == 3)
86 if (station == 2 && ring == 1)
88 if (station == 3 && ring == 1)
90 if (station == 4 && ring == 1)
108 const CSCDetId& cscDetId = (*dri).first;
109 unsigned int rawid = cscDetId.
rawId();
113 fwLog(
fwlog::kWarning) <<
"Failed to get geometry of CSC chamber with detid: " << rawid << std::endl;
123 float length = shape[4];
124 float topWidth = shape[2];
125 float bottomWidth = shape[1];
137 TEveStraightLineSet* wireDigiSet =
new TEveStraightLineSet();
138 wireDigiSet->SetLineWidth(3);
141 int wireGroup = (*dit).getWireGroup();
142 float yOfWire = yOfFirstWire + ((wireGroup - 1) * wireSpacing);
143 float wireLength = yOfWire * (topWidth - bottomWidth) / length;
144 wireLength += bottomWidth * 2.0;
146 float localPointLeft[3] = {
static_cast<float>(-wireLength * 0.5), yOfWire,
static_cast<float>(0.0)};
150 float localPointRight[3] = {
151 static_cast<float>(wireLength * 0.5), yOfWire,
static_cast<float>(0.0)
155 float globalPointLeft[3];
156 float globalPointRight[3];
158 geom->
localToGlobal(rawid, localPointLeft, globalPointLeft, localPointRight, globalPointRight);
160 wireDigiSet->AddLine(globalPointLeft[0],
165 globalPointRight[2]);
#define REGISTER_PROXYBUILDER_METHODS()
#define REGISTER_FWPROXYBUILDER(_name_, _type_, _purpose_, _view_)
static const int kAllRPZBits
const FWCSCWireDigiProxyBuilder & operator=(const FWCSCWireDigiProxyBuilder &)=delete
void setupAddElement(TEveElement *el, TEveElement *parent, bool set_color=true) const
void get(const T *&oData) const
constexpr uint32_t rawId() const
get the raw id
double getAverageWireSpacing(const int station, const int ring)
static const int kAll3DBits
const uint16_t range(const Frame &aFrame)
~FWCSCWireDigiProxyBuilder() override
const float * getShapePars(unsigned int id) const
void localToGlobal(unsigned int id, const float *local, float *global, bool translatep=true) const
bool contains(unsigned int id) const
std::pair< const_iterator, const_iterator > Range
std::vector< DigiType >::const_iterator const_iterator
FWCSCWireDigiProxyBuilder()
TEveCompound * createCompound(bool set_color=true, bool propagate_color_to_all_children=false) const
double getYOfFirstWire(const int station, const int ring, const double length)
const FWGeometry * getGeom() const