Logo ROOT  
Reference Guide
No Matches
geom_cms.C File Reference

Detailed Description

Shows CMS geometry.

void geom_cms()
gGeoManager = gEve->GetGeometry("http://root.cern.ch/files/cms.root");
auto top = gGeoManager->GetTopVolume()->FindNode("CMSE_1")->GetVolume();
TEveGeoTopNode* trk = new TEveGeoTopNode(gGeoManager, top->FindNode("TRAK_1"));
auto calo = new TEveGeoTopNode(gGeoManager, top->FindNode("CALO_1"));
auto muon = new TEveGeoTopNode(gGeoManager, top->FindNode("MUON_1"));
// EClipType not exported to CINT (see TGLUtil.h):
// 0 - no clip, 1 - clip plane, 2 - clip box
v->SetGuideState(TGLUtil::kAxesEdge, kTRUE, kFALSE, 0);
v->CurrentCamera().RotateRad(-1.2, 0.5);
constexpr Bool_t kFALSE
Definition RtypesCore.h:101
constexpr Bool_t kTRUE
Definition RtypesCore.h:100
@ kMagenta
Definition Rtypes.h:66
R__EXTERN TEveManager * gEve
R__EXTERN TGeoManager * gGeoManager
A wrapper over a TGeoNode, possibly displaced with a global trasformation stored in TEveElement.
Definition TEveGeoNode.h:90
void SetVisLevel(Int_t vl)
void AddGlobalElement(TEveElement *element, TEveElement *parent=nullptr)
Add a global element, i.e.
TGLViewer * GetDefaultGLViewer() const
Get TGLViewer of the default TEveViewer.
static TEveManager * Create(Bool_t map_window=kTRUE, Option_t *opt="FIV")
If global TEveManager* gEve is not set initialize it.
void FullRedraw3D(Bool_t resetCameras=kFALSE, Bool_t dropLogicals=kFALSE)
Perform 3D redraw of all scenes and viewers.
TGeoManager * GetGeometry(const TString &filename)
Get geometry with given filename.
static Bool_t SetCacheFileDir(ROOT::Internal::TStringView cacheDir, Bool_t operateDisconnected=kTRUE, Bool_t forceCacheread=kFALSE)
Definition TFile.h:332
void SetClipType(TGLClip::EType type)
Set current clip active in viewer - 'type' is one of kClipNone kClipPlane or kClipBox.
Definition TGLClip.cxx:580
@ kAxesEdge
Definition TGLUtil.h:952
TGLClipSet * GetClipSet() const
Definition TGLViewer.h:263
void DefaultColors()
Set default volume colors according to A of material.
TGeoNode * FindNode(Bool_t safe_start=kTRUE)
Returns deepest node containing current point.
TGeoVolume * GetTopVolume() const
TGeoVolume * GetVolume() const
Definition TGeoNode.h:99
TGeoNode * FindNode(const char *name) const
search a daughter inside the list of nodes
void geom_cms()
Definition geom_cms.C:80
Matevz Tadel

Definition in file geom_cms.C.