CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
SiPixelFrameConverter.h
Go to the documentation of this file.
1 #ifndef SiPixelObjects_SiPixelFrameConverter_H
2 #define SiPixelObjects_SiPixelFrameConverter_H
3 
12 
13 #include <cstdint>
14 
16 public:
18 
19  // using PixelFEDCabling = sipixelobjects::PixelFEDCabling;
20 
22 
23  bool hasDetUnit(uint32_t radId) const;
24 
25  sipixelobjects::PixelROC const* toRoc(int link, int roc) const;
26 
28  using namespace sipixelobjects;
29  auto roc = toRoc(cabling.link, cabling.roc);
30  if (!roc)
31  return 2;
32  LocalPixel::DcolPxid local = {cabling.dcol, cabling.pxid};
33  if (!local.valid())
34  return 3;
35 
36  GlobalPixel global = roc->toGlobal(LocalPixel(local));
37  detector.rawId = roc->rawId();
38  detector.row = global.row;
39  detector.col = global.col;
40 
41  return 0;
42  }
43 
44  int toCabling(sipixelobjects::ElectronicIndex& cabling, const sipixelobjects::DetectorIndex& detector) const;
45 
46 private:
47  int theFedId;
51 };
52 #endif
SiPixelFrameConverter(const SiPixelFedCabling *map, int fedId)
identify pixel inside single ROC
Definition: LocalPixel.h:7
global coordinates (row and column in DetUnit, as in PixelDigi)
Definition: GlobalPixel.h:6
SiPixelFedCablingTree const * theTree
double collumn and pixel ID in double collumn representation
Definition: LocalPixel.h:19
int toCabling(sipixelobjects::ElectronicIndex &cabling, const sipixelobjects::DetectorIndex &detector) const
const SiPixelFedCabling * theMap
sipixelobjects::PixelFEDCabling PixelFEDCabling
sipixelobjects::PixelROC const * toRoc(int link, int roc) const
bool hasDetUnit(uint32_t radId) const
int toDetector(const sipixelobjects::ElectronicIndex &cabling, sipixelobjects::DetectorIndex &detector) const
const PixelFEDCabling * theFed