CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Classes | Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | Private Attributes
FWGeometry Class Reference

#include <FWGeometry.h>

Classes

struct  GeomDetInfo
 
struct  Range
 
class  VersionInfo
 

Public Types

enum  Detector {
  Tracker = 1, Muon = 2, Ecal = 3, Hcal = 4,
  Calo = 5
}
 
typedef std::vector
< FWGeometry::GeomDetInfo
IdToInfo
 
typedef std::vector
< FWGeometry::GeomDetInfo >
::const_iterator 
IdToInfoItr
 
enum  SubDetector {
  PixelBarrel = 1, PixelEndcap = 2, TIB = 3, TID = 4,
  TOB = 5, TEC = 6, CSC = 7, DT = 8,
  RPCBarrel = 9, RPCEndcap = 10, GEM = 11, ME0 = 12
}
 

Public Member Functions

void clear (void)
 
bool contains (unsigned int id) const
 
IdToInfoItr find (unsigned int) const
 
 FWGeometry (void)
 
const float * getCorners (unsigned int id) const
 
TEveGeoShape * getEveShape (unsigned int id) const
 
std::vector< unsigned int > getMatchedIds (Detector det, SubDetector subdet) const
 
const TGeoMatrix * getMatrix (unsigned int id) const
 
const float * getParameters (unsigned int id) const
 
TGeoShape * getShape (unsigned int id) const
 
TGeoShape * getShape (const GeomDetInfo &info) const
 
const float * getShapePars (unsigned int id) const
 
void initMap (const FWRecoGeom::InfoMap &map)
 
void loadMap (const char *fileName)
 
void localToGlobal (unsigned int id, const float *local, float *global, bool translatep=true) const
 
void localToGlobal (unsigned int id, const float *local1, float *global1, const float *local2, float *global2, bool translatep=true) const
 
void localToGlobal (const GeomDetInfo &info, const float *local, float *global, bool translatep=true) const
 
bool match_id (const GeomDetInfo &o, unsigned int mask) const
 
const VersionInfoversionInfo () const
 
 ~FWGeometry (void)
 

Static Public Member Functions

static TFile * findFile (const char *fileName)
 

Static Public Attributes

static const int kDetOffset = 28
 
static const int kSubdetOffset = 25
 

Private Attributes

IdToInfo m_idToInfo
 
std::map< unsigned int,
TGeoMatrix * > 
m_idToMatrix
 
std::string m_prodTag
 
VersionInfo m_versionInfo
 

Detailed Description

Definition at line 24 of file FWGeometry.h.

Member Typedef Documentation

Definition at line 106 of file FWGeometry.h.

typedef std::vector<FWGeometry::GeomDetInfo>::const_iterator FWGeometry::IdToInfoItr

Definition at line 107 of file FWGeometry.h.

Member Enumeration Documentation

Enumerator
Tracker 
Muon 
Ecal 
Hcal 
Calo 

Definition at line 30 of file FWGeometry.h.

Enumerator
PixelBarrel 
PixelEndcap 
TIB 
TID 
TOB 
TEC 
CSC 
DT 
RPCBarrel 
RPCEndcap 
GEM 
ME0 

Definition at line 31 of file FWGeometry.h.

Constructor & Destructor Documentation

FWGeometry::FWGeometry ( void  )

Definition at line 19 of file FWGeometry.cc.

FWGeometry::~FWGeometry ( void  )

Definition at line 22 of file FWGeometry.cc.

Member Function Documentation

void FWGeometry::clear ( void  )
inline

Definition at line 113 of file FWGeometry.h.

References m_idToInfo, and m_idToMatrix.

Referenced by Vispa.Views.WidgetView.WidgetView::closeEvent(), Vispa.Share.FindAlgorithm.FindAlgorithm::findUsingFindDialog(), and Vispa.Views.WidgetView.WidgetView::setDataObjects().

113 { m_idToInfo.clear(); m_idToMatrix.clear(); }
std::map< unsigned int, TGeoMatrix * > m_idToMatrix
Definition: FWGeometry.h:122
IdToInfo m_idToInfo
Definition: FWGeometry.h:124
bool FWGeometry::contains ( unsigned int  id) const
inline
FWGeometry::IdToInfoItr FWGeometry::find ( unsigned int  id) const
TFile * FWGeometry::findFile ( const char *  fileName)
static

Definition at line 26 of file FWGeometry.cc.

Referenced by FWGeometryTableViewManager::setGeoManagerFromFile().

const float * FWGeometry::getCorners ( unsigned int  id) const
TEveGeoShape * FWGeometry::getEveShape ( unsigned int  id) const
std::vector< unsigned int > FWGeometry::getMatchedIds ( Detector  det,
SubDetector  subdet 
) const

Definition at line 197 of file FWGeometry.cc.

const TGeoMatrix * FWGeometry::getMatrix ( unsigned int  id) const

Definition at line 169 of file FWGeometry.cc.

const float * FWGeometry::getParameters ( unsigned int  id) const
TGeoShape * FWGeometry::getShape ( unsigned int  id) const

Definition at line 212 of file FWGeometry.cc.

Referenced by FWSiStripClusterProxyBuilder::build().

TGeoShape * FWGeometry::getShape ( const GeomDetInfo info) const

Definition at line 227 of file FWGeometry.cc.

const float * FWGeometry::getShapePars ( unsigned int  id) const
void FWGeometry::initMap ( const FWRecoGeom::InfoMap map)

Definition at line 143 of file FWGeometry.cc.

void FWGeometry::loadMap ( const char *  fileName)

Definition at line 52 of file FWGeometry.cc.

void FWGeometry::localToGlobal ( unsigned int  id,
const float *  local,
float *  global,
bool  translatep = true 
) const
void FWGeometry::localToGlobal ( unsigned int  id,
const float *  local1,
float *  global1,
const float *  local2,
float *  global2,
bool  translatep = true 
) const

Definition at line 342 of file FWGeometry.cc.

void FWGeometry::localToGlobal ( const GeomDetInfo info,
const float *  local,
float *  global,
bool  translatep = true 
) const

Definition at line 366 of file FWGeometry.cc.

bool FWGeometry::match_id ( const GeomDetInfo o,
unsigned int  mask 
) const
inline

Definition at line 101 of file FWGeometry.h.

References FWGeometry::GeomDetInfo::id, kDetOffset, and kSubdetOffset.

101  {
102  unsigned int id = o.id;
103  return ((((( id >> kDetOffset ) & 0xF ) << 4) | (( id >> kSubdetOffset ) & 0x7 )) == mask );
104  }
static const int kSubdetOffset
Definition: FWGeometry.h:28
static const int kDetOffset
Definition: FWGeometry.h:27
const VersionInfo& FWGeometry::versionInfo ( ) const
inline

Definition at line 117 of file FWGeometry.h.

References m_versionInfo.

117 { return m_versionInfo; }
VersionInfo m_versionInfo
Definition: FWGeometry.h:128

Member Data Documentation

const int FWGeometry::kDetOffset = 28
static

Definition at line 27 of file FWGeometry.h.

Referenced by match_id().

const int FWGeometry::kSubdetOffset = 25
static

Definition at line 28 of file FWGeometry.h.

Referenced by match_id().

IdToInfo FWGeometry::m_idToInfo
private

Definition at line 124 of file FWGeometry.h.

Referenced by clear(), and contains().

std::map<unsigned int, TGeoMatrix*> FWGeometry::m_idToMatrix
mutableprivate

Definition at line 122 of file FWGeometry.h.

Referenced by clear().

std::string FWGeometry::m_prodTag
private

Definition at line 126 of file FWGeometry.h.

VersionInfo FWGeometry::m_versionInfo
private

Definition at line 128 of file FWGeometry.h.

Referenced by versionInfo().