Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
show_extract.C
Go to the documentation of this file.
1/// \file
2/// \ingroup tutorial_eve
3/// Helper script for showing of extracted / simplified geometries.
4/// By default shows a simplified ALICE geometry.
5///
6/// \image html eve_show_extract.png
7/// \macro_code
8///
9/// \author Matevz Tadel
10
11void show_extract(const char* file="http://root.cern.ch/files/alice_ESDgeometry.root")
12{
14
16
17 TIter next(gDirectory->GetListOfKeys());
18 TKey* key;
19 TString xxx("TEveGeoShapeExtract");
20
21 while ((key = (TKey*) next()))
22 {
23 if (xxx == key->GetClassName())
24 {
25 auto gse = (TEveGeoShapeExtract*) key->ReadObj();
26 auto gs = TEveGeoShape::ImportShapeExtract(gse, 0);
28 }
29 }
30
32}
const Bool_t kTRUE
Definition RtypesCore.h:91
#define gDirectory
Definition TDirectory.h:290
R__EXTERN TEveManager * gEve
Globally positioned TGeoShape with rendering attributes and an optional list of daughter shape-extrac...
static TEveGeoShape * ImportShapeExtract(TEveGeoShapeExtract *gse, TEveElement *parent=0)
Import a shape extract 'gse' under element 'parent'.
void AddGlobalElement(TEveElement *element, TEveElement *parent=0)
Add a global element, i.e.
static TEveManager * Create(Bool_t map_window=kTRUE, Option_t *opt="FIV")
If global TEveManager* gEve is not set initialize it.
void Redraw3D(Bool_t resetCameras=kFALSE, Bool_t dropLogicals=kFALSE)
static TFile * Open(const char *name, Option_t *option="", const char *ftitle="", Int_t compress=ROOT::RCompressionSetting::EDefaults::kUseCompiledDefault, Int_t netopt=0)
Create / open a file.
Definition TFile.cxx:3997
Book space in a file, create I/O buffers, to fill them, (un)compress them.
Definition TKey.h:28
virtual const char * GetClassName() const
Definition TKey.h:76
virtual TObject * ReadObj()
To read a TObject* from the file.
Definition TKey.cxx:750
Basic string class.
Definition TString.h:136
Definition file.py:1