Skip to content
Snippets Groups Projects
  • Rene Brun's avatar
    3df690f1
    From Andrei & Mihaela: · 3df690f1
    Rene Brun authored
    I managed together with Mihaela to split out all navigation functionality out of TGeoManager into a new class TGeoNavigator (attached diff, .h and .cxx). The changes are fully backward compatible and did not require modifying the streamer of TGeoManager. We have tested with:
    - /roottest/root/io/geo - the reference changes a bit (name of a class)
    - aliroot with G3
    - /test/stressGeometry
    
    New feature: one has a default navigator for a geometry but may add several others for parallel navigation:
    
    TGeoNavigator *navig = new TGeoNavigator(gGeoManager);
    Int_t inav = gGeoManager->AddNavigator(navig);
    gGeoManager->SetCurrentNavigator(inav);
    .... and then switch back to the default navigator:
    gGeoManager->SetCurrentNavigator(0);
    
    One may also derive from TGeoNavigator and implement its own navigation (I doubt that this will ever happen but you never know...)
    
    
    git-svn-id: http://root.cern.ch/svn/root/trunk@18989 27541ba8-7e3a-0410-8455-c3a389f83636
    3df690f1
    History
    From Andrei & Mihaela:
    Rene Brun authored
    I managed together with Mihaela to split out all navigation functionality out of TGeoManager into a new class TGeoNavigator (attached diff, .h and .cxx). The changes are fully backward compatible and did not require modifying the streamer of TGeoManager. We have tested with:
    - /roottest/root/io/geo - the reference changes a bit (name of a class)
    - aliroot with G3
    - /test/stressGeometry
    
    New feature: one has a default navigator for a geometry but may add several others for parallel navigation:
    
    TGeoNavigator *navig = new TGeoNavigator(gGeoManager);
    Int_t inav = gGeoManager->AddNavigator(navig);
    gGeoManager->SetCurrentNavigator(inav);
    .... and then switch back to the default navigator:
    gGeoManager->SetCurrentNavigator(0);
    
    One may also derive from TGeoNavigator and implement its own navigation (I doubt that this will ever happen but you never know...)
    
    
    git-svn-id: http://root.cern.ch/svn/root/trunk@18989 27541ba8-7e3a-0410-8455-c3a389f83636
Module.mk 2.86 KiB
# Module.mk for geom module
# Copyright (c) 2000 Rene Brun and Fons Rademakers
#
# Author: Fons Rademakers, 29/2/2000

MODDIR       := geom
MODDIRS      := $(MODDIR)/src
MODDIRI      := $(MODDIR)/inc

GEOMDIR      := $(MODDIR)
GEOMDIRS     := $(GEOMDIR)/src
GEOMDIRI     := $(GEOMDIR)/inc

##### libGeom #####
GEOML1       := $(MODDIRI)/LinkDef1.h
GEOML2       := $(MODDIRI)/LinkDef2.h
GEOMDS1      := $(MODDIRS)/G__Geom1.cxx
GEOMDS2      := $(MODDIRS)/G__Geom2.cxx
GEOMDO1      := $(GEOMDS1:.cxx=.o)
GEOMDO2      := $(GEOMDS2:.cxx=.o)
GEOMDS       := $(GEOMDS1) $(GEOMDS2)
GEOMDO       := $(GEOMDO1) $(GEOMDO2)
GEOMDH       := $(GEOMDS:.cxx=.h)

GEOMH1       := TGeoAtt.h TGeoBoolNode.h \
                TGeoMedium.h TGeoMaterial.h \
                TGeoMatrix.h TGeoVolume.h TGeoNode.h \
                TGeoVoxelFinder.h TGeoShape.h TGeoBBox.h \
                TGeoPara.h TGeoTube.h TGeoTorus.h TGeoSphere.h \
                TGeoEltu.h TGeoHype.h TGeoCone.h TGeoPcon.h \
                TGeoPgon.h TGeoArb8.h TGeoTrd1.h TGeoTrd2.h \
                TGeoManager.h TGeoCompositeShape.h TGeoShapeAssembly.h \
                TGeoScaledShape.h TVirtualGeoPainter.h TVirtualGeoTrack.h \
		TGeoPolygon.h TGeoXtru.h TGeoPhysicalNode.h \
                TGeoHelix.h TGeoParaboloid.h TGeoElement.h TGeoHalfSpace.h \
                TGeoBuilder.h TGeoNavigator.h
GEOMH2       := TGeoPatternFinder.h TGeoCache.h
GEOMH1       := $(patsubst %,$(MODDIRI)/%,$(GEOMH1))
GEOMH2       := $(patsubst %,$(MODDIRI)/%,$(GEOMH2))
GEOMH        := $(GEOMH1) $(GEOMH2)
GEOMS        := $(filter-out $(MODDIRS)/G__%,$(wildcard $(MODDIRS)/*.cxx))
GEOMO        := $(GEOMS:.cxx=.o)

GEOMDEP      := $(GEOMO:.o=.d) $(GEOMDO:.o=.d)

GEOMLIB      := $(LPATH)/libGeom.$(SOEXT)
GEOMMAP      := $(GEOMLIB:.$(SOEXT)=.rootmap)

# used in the main Makefile
ALLHDRS     += $(patsubst $(MODDIRI)/%.h,include/%.h,$(GEOMH))
ALLLIBS     += $(GEOMLIB)
ALLMAPS     += $(GEOMMAP)

# include all dependency files
INCLUDEFILES += $(GEOMDEP)

##### local rules #####
include/%.h:    $(GEOMDIRI)/%.h
		cp $< $@

$(GEOMLIB):     $(GEOMO) $(GEOMDO) $(ORDER_) $(MAINLIBS) $(GEOMLIBDEP)
		@$(MAKELIB) $(PLATFORM) $(LD) "$(LDFLAGS)" \
		   "$(SOFLAGS)" libGeom.$(SOEXT) $@ "$(GEOMO) $(GEOMDO)" \
		   "$(GEOMLIBEXTRA)"

$(GEOMDS1):     $(GEOMH1) $(GEOML1) $(ROOTCINTTMPEXE)
		@echo "Generating dictionary $@..."
		$(ROOTCINTTMP) -f $@ -c $(GEOMH1) $(GEOML1)

$(GEOMDS2):     $(GEOMH2) $(GEOML2) $(ROOTCINTTMPEXE)
		@echo "Generating dictionary $@..."
		$(ROOTCINTTMP) -f $@ -c $(GEOMH2) $(GEOML2)

$(GEOMMAP):     $(RLIBMAP) $(MAKEFILEDEP) $(GEOML1) $(GEOML2)
		$(RLIBMAP) -o $(GEOMMAP) -l $(GEOMLIB) \
		   -d $(GEOMLIBDEPM) -c $(GEOML1) $(GEOML2)

all-geom:       $(GEOMLIB) $(GEOMMAP)

clean-geom:
		@rm -f $(GEOMO) $(GEOMDO)

clean::         clean-geom

distclean-geom: clean-geom
		@rm -f $(GEOMDEP) $(GEOMDS) $(GEOMDH) $(GEOMLIB) $(GEOMMAP)

distclean::     distclean-geom