From 84aff7a46e8b57dfc49ce3563126eabc8d5884d9 Mon Sep 17 00:00:00 2001 From: mtadel Date: Thu, 17 Jan 2008 17:21:33 +0000 Subject: [PATCH] Remove EVE/Reve/ sub-module. Modify EVE/Alieve sub-module and all macros to use eve/ module from ROOT instead of Reve. --- EVE/Alieve/AliEVEHOMERManager.cxx | 4 +- EVE/Alieve/AliEVEHOMERManager.h | 4 +- EVE/Alieve/AliEVEHOMERManagerEditor.cxx | 3 - EVE/Alieve/AliEVEHOMERSource.cxx | 7 +- EVE/Alieve/AliEVEHOMERSource.h | 5 +- EVE/Alieve/AliEVEHOMERSourceList.cxx | 5 +- EVE/Alieve/AliEVEHOMERSourceList.h | 5 +- EVE/Alieve/EventAlieve.cxx | 64 +- EVE/Alieve/EventAlieve.h | 4 +- EVE/Alieve/ITSDigitsInfo.cxx | 12 +- EVE/Alieve/ITSDigitsInfo.h | 4 +- EVE/Alieve/ITSModule.cxx | 44 +- EVE/Alieve/ITSModule.h | 16 +- EVE/Alieve/ITSModuleStepper.cxx | 70 +- EVE/Alieve/ITSModuleStepper.h | 27 +- EVE/Alieve/ITSModuleStepperEditor.cxx | 10 +- EVE/Alieve/ITSModuleStepperEditor.h | 7 +- EVE/Alieve/ITSScaledModule.cxx | 20 +- EVE/Alieve/ITSScaledModule.h | 4 +- EVE/Alieve/ITSScaledModuleEditor.cxx | 6 +- EVE/Alieve/ITSScaledModuleEditor.h | 11 +- EVE/Alieve/JetPlane.cxx | 2 +- EVE/Alieve/JetPlane.h | 14 +- EVE/Alieve/JetPlaneEditor.cxx | 18 +- EVE/Alieve/JetPlaneEditor.h | 11 +- EVE/Alieve/JetPlaneGL.cxx | 11 +- EVE/Alieve/KineTools.cxx | 54 +- EVE/Alieve/KineTools.h | 13 +- EVE/Alieve/LinkDef.h | 16 +- EVE/Alieve/MUONChamber.cxx | 47 +- EVE/Alieve/MUONChamber.h | 16 +- EVE/Alieve/MUONChamberData.cxx | 2 - EVE/Alieve/MUONChamberData.h | 2 +- EVE/Alieve/MUONChamberEditor.cxx | 12 +- EVE/Alieve/MUONChamberEditor.h | 14 +- EVE/Alieve/MUONChamberGL.cxx | 35 +- EVE/Alieve/MUONChamberGL.h | 10 +- EVE/Alieve/MUONData.cxx | 4 +- EVE/Alieve/MUONData.h | 4 +- EVE/Alieve/MUONTrack.cxx | 20 +- EVE/Alieve/MUONTrack.h | 16 +- EVE/Alieve/PMDModule.cxx | 6 +- EVE/Alieve/PMDModule.h | 6 +- EVE/Alieve/PMDModuleEditor.cxx | 6 +- EVE/Alieve/T0Module.cxx | 69 +- EVE/Alieve/T0Module.h | 4 +- EVE/Alieve/TOFDigitsInfo.cxx | 12 +- EVE/Alieve/TOFDigitsInfo.h | 4 +- EVE/Alieve/TOFDigitsInfoEditor.cxx | 2 - EVE/Alieve/TOFSector.cxx | 34 +- EVE/Alieve/TOFSector.h | 14 +- EVE/Alieve/TOFSectorEditor.cxx | 12 +- EVE/Alieve/TOFSectorEditor.h | 14 +- EVE/Alieve/TOFStrip.cxx | 24 +- EVE/Alieve/TOFStrip.h | 14 +- EVE/Alieve/TOFStripEditor.cxx | 2 - EVE/Alieve/TPCData.cxx | 4 +- EVE/Alieve/TPCData.h | 4 +- EVE/Alieve/TPCLoader.cxx | 48 +- EVE/Alieve/TPCLoader.h | 6 +- EVE/Alieve/TPCLoaderEditor.cxx | 14 +- EVE/Alieve/TPCLoaderEditor.h | 10 +- EVE/Alieve/TPCSector2D.cxx | 16 +- EVE/Alieve/TPCSector2DEditor.cxx | 2 - EVE/Alieve/TPCSector2DGL.cxx | 4 +- EVE/Alieve/TPCSector3D.cxx | 8 +- EVE/Alieve/TPCSector3D.h | 8 +- EVE/Alieve/TPCSector3DEditor.cxx | 10 +- EVE/Alieve/TPCSector3DEditor.h | 12 +- EVE/Alieve/TPCSector3DGL.cxx | 18 +- EVE/Alieve/TPCSector3DGL.h | 6 +- EVE/Alieve/TPCSectorData.cxx | 4 +- EVE/Alieve/TPCSectorData.h | 4 +- EVE/Alieve/TPCSectorViz.cxx | 6 +- EVE/Alieve/TPCSectorViz.h | 10 +- EVE/Alieve/TPCSectorVizEditor.cxx | 18 +- EVE/Alieve/TPCSectorVizEditor.h | 18 +- EVE/Alieve/TRDData.cxx | 150 +- EVE/Alieve/TRDData.h | 12 +- EVE/Alieve/TRDLoader.cxx | 46 +- EVE/Alieve/TRDLoader.h | 28 +- EVE/Alieve/TRDLoaderImp.cxx | 16 +- EVE/Alieve/TRDLoaderManager.cxx | 22 +- EVE/Alieve/TRDLoaderManager.h | 8 +- EVE/Alieve/TRDModule.cxx | 13 +- EVE/Alieve/TRDModuleImp.cxx | 27 +- EVE/Alieve/TRDModuleImp.h | 15 +- EVE/Alieve/TrackFitter.cxx | 68 +- EVE/Alieve/TrackFitter.h | 21 +- EVE/Alieve/TrackFitterEditor.cxx | 2 - EVE/Alieve/VSDCreator.cxx | 387 +-- EVE/Alieve/VSDCreator.h | 10 +- EVE/Alieve/alieve_main/alieve_main.cxx | 46 +- .../{ => blacklisted-classes}/Cascade.cxx | 0 .../{ => blacklisted-classes}/Cascade.h | 0 .../CascadeEditors.cxx | 0 .../CascadeEditors.h | 0 EVE/Alieve/{ => blacklisted-classes}/V0.cxx | 0 EVE/Alieve/{ => blacklisted-classes}/V0.h | 0 .../{ => blacklisted-classes}/V0Editors.cxx | 0 .../{ => blacklisted-classes}/V0Editors.h | 0 EVE/Reve/.SKEL-ged.cxx | 58 - EVE/Reve/.SKEL-ged.h | 43 - EVE/Reve/.SKEL-gedsubed.cxx | 98 - EVE/Reve/.SKEL-gedsubed.h | 63 - EVE/Reve/.SKEL-gl.cxx | 47 - EVE/Reve/.SKEL-gl.h | 42 - EVE/Reve/.SKEL.cxx | 16 - EVE/Reve/.SKEL.h | 29 - EVE/Reve/BoxSet.cxx | 239 -- EVE/Reve/BoxSet.h | 77 - EVE/Reve/BoxSetGL.cxx | 344 --- EVE/Reve/BoxSetGL.h | 50 - EVE/Reve/ChangeLog | 2638 ----------------- EVE/Reve/DigitSet.cxx | 294 -- EVE/Reve/DigitSet.h | 132 - EVE/Reve/DigitSetEditor.cxx | 181 -- EVE/Reve/DigitSetEditor.h | 56 - EVE/Reve/EventBase.cxx | 37 - EVE/Reve/EventBase.h | 38 - EVE/Reve/FrameBox.cxx | 149 - EVE/Reve/FrameBox.h | 85 - EVE/Reve/FrameBoxGL.cxx | 92 - EVE/Reve/FrameBoxGL.h | 31 - EVE/Reve/GLTextNS.cxx | 700 ----- EVE/Reve/GLTextNS.h | 149 - EVE/Reve/GLUtilNS.cxx | 200 -- EVE/Reve/GLUtilNS.h | 70 - EVE/Reve/GeoNode.cxx | 536 ---- EVE/Reve/GeoNode.h | 159 - EVE/Reve/GeoNodeEditor.cxx | 202 -- EVE/Reve/GeoNodeEditor.h | 79 - EVE/Reve/GridStepper.cxx | 87 - EVE/Reve/GridStepper.h | 55 - EVE/Reve/GridStepperEditor.cxx | 186 -- EVE/Reve/GridStepperEditor.h | 70 - EVE/Reve/Line.cxx | 31 - EVE/Reve/Line.h | 47 - EVE/Reve/LineEditor.cxx | 71 - EVE/Reve/LineEditor.h | 42 - EVE/Reve/LineGL.cxx | 57 - EVE/Reve/LineGL.h | 42 - EVE/Reve/LinkDef.h | 211 -- EVE/Reve/MCHelixLine.hi | 315 -- EVE/Reve/Makefile | 33 - EVE/Reve/NLTBases.cxx | 87 - EVE/Reve/NLTBases.h | 81 - EVE/Reve/NLTPointSetGL.cxx | 21 - EVE/Reve/NLTPointSetGL.h | 32 - EVE/Reve/NLTPolygonSet.cxx | 459 --- EVE/Reve/NLTPolygonSet.h | 124 - EVE/Reve/NLTPolygonSetEditor.cxx | 96 - EVE/Reve/NLTPolygonSetEditor.h | 39 - EVE/Reve/NLTPolygonSetGL.cxx | 142 - EVE/Reve/NLTPolygonSetGL.h | 25 - EVE/Reve/NLTProjections.cxx | 268 -- EVE/Reve/NLTProjections.h | 115 - EVE/Reve/NLTProjector.cxx | 244 -- EVE/Reve/NLTProjector.h | 75 - EVE/Reve/NLTProjectorEditor.cxx | 327 -- EVE/Reve/NLTProjectorEditor.h | 71 - EVE/Reve/NLTProjectorGL.cxx | 298 -- EVE/Reve/NLTProjectorGL.h | 62 - EVE/Reve/NLTTrack.cxx | 239 -- EVE/Reve/NLTTrack.h | 70 - EVE/Reve/NLTTrackGL.cxx | 102 - EVE/Reve/NLTTrackGL.h | 37 - EVE/Reve/PODs.cxx | 76 - EVE/Reve/PODs.h | 355 --- EVE/Reve/Pad.cxx | 30 - EVE/Reve/Pad.h | 31 - EVE/Reve/Plex.cxx | 86 - EVE/Reve/Plex.h | 141 - EVE/Reve/PointSet.cxx | 614 ---- EVE/Reve/PointSet.h | 162 - EVE/Reve/PointSetArrayEditor.cxx | 78 - EVE/Reve/PointSetArrayEditor.h | 43 - EVE/Reve/QuadSet.cxx | 602 ---- EVE/Reve/QuadSet.h | 181 -- EVE/Reve/QuadSetGL.cxx | 591 ---- EVE/Reve/QuadSetGL.h | 64 - EVE/Reve/RGBAPalette.cxx | 235 -- EVE/Reve/RGBAPalette.h | 198 -- EVE/Reve/RGBAPaletteEditor.cxx | 237 -- EVE/Reve/RGBAPaletteEditor.h | 85 - EVE/Reve/RGBrowser.cxx | 559 ---- EVE/Reve/RGBrowser.h | 86 - EVE/Reve/RGEditor.cxx | 104 - EVE/Reve/RGEditor.h | 40 - EVE/Reve/RGValuators.cxx | 401 --- EVE/Reve/RGValuators.h | 193 -- EVE/Reve/RMacro.cxx | 102 - EVE/Reve/RMacro.h | 31 - EVE/Reve/RenderElement.cxx | 813 ----- EVE/Reve/RenderElement.h | 254 -- EVE/Reve/RenderElementEditor.cxx | 145 - EVE/Reve/RenderElementEditor.h | 49 - EVE/Reve/Reve.cxx | 348 --- EVE/Reve/Reve.h | 165 -- EVE/Reve/ReveManager.cxx | 489 --- EVE/Reve/ReveManager.h | 176 -- EVE/Reve/Scene.cxx | 112 - EVE/Reve/Scene.h | 76 - EVE/Reve/SceneInfo.cxx | 66 - EVE/Reve/SceneInfo.h | 48 - EVE/Reve/StraightLineSet.cxx | 166 -- EVE/Reve/StraightLineSet.h | 138 - EVE/Reve/StraightLineSetEditor.cxx | 76 - EVE/Reve/StraightLineSetEditor.h | 44 - EVE/Reve/StraightLineSetGL.cxx | 172 -- EVE/Reve/StraightLineSetGL.h | 45 - EVE/Reve/TGClassBrowser.cxx | 124 - EVE/Reve/TGClassBrowser.h | 33 - EVE/Reve/TGCommandPlugin.cxx | 127 - EVE/Reve/TGCommandPlugin.h | 36 - EVE/Reve/TGFileBrowser.cxx | 805 ----- EVE/Reve/TGFileBrowser.h | 91 - EVE/Reve/TGNewBrowser.cxx | 810 ----- EVE/Reve/TGNewBrowser.h | 108 - EVE/Reve/TGeoShapeExtract.cxx | 67 - EVE/Reve/TGeoShapeExtract.h | 54 - EVE/Reve/TTreeTools.cxx | 109 - EVE/Reve/TTreeTools.h | 121 - EVE/Reve/Track.cxx | 1563 ---------- EVE/Reve/Track.h | 311 -- EVE/Reve/TrackEditors.cxx | 478 --- EVE/Reve/TrackEditors.h | 134 - EVE/Reve/TrackGL.cxx | 101 - EVE/Reve/TrackGL.h | 41 - EVE/Reve/TrackRnrStyleEditor.cxx | 381 --- EVE/Reve/TrackRnrStyleEditor.h | 110 - EVE/Reve/TriangleSet.cxx | 199 -- EVE/Reve/TriangleSet.h | 90 - EVE/Reve/TriangleSetEditor.cxx | 50 - EVE/Reve/TriangleSetEditor.h | 39 - EVE/Reve/TriangleSetGL.cxx | 111 - EVE/Reve/TriangleSetGL.h | 41 - EVE/Reve/VSD.cxx | 206 -- EVE/Reve/VSD.h | 70 - EVE/Reve/VSDEvent.cxx | 104 - EVE/Reve/VSDEvent.h | 74 - EVE/Reve/VSDSelector.cxx | 374 --- EVE/Reve/VSDSelector.h | 52 - EVE/Reve/Viewer.cxx | 177 -- EVE/Reve/Viewer.h | 78 - EVE/Reve/ZTrans.cxx | 777 ----- EVE/Reve/ZTrans.h | 178 -- EVE/Reve/ZTransEditor.cxx | 232 -- EVE/Reve/ZTransEditor.h | 75 - EVE/Reve/reve_main/reve_main.cxx | 13 - EVE/alice-data/gentle_geo.root | Bin 9586 -> 9645 bytes EVE/alice-macros/MUON_display.C | 70 +- EVE/alice-macros/MUON_geom.C | 19 +- EVE/alice-macros/MUON_geomAll.C | 8 +- EVE/alice-macros/MUON_trigger_info.C | 2 +- EVE/alice-macros/NLT_test.C | 22 +- EVE/alice-macros/NLT_trackcount_init.C | 64 +- EVE/alice-macros/acorde_hits.C | 22 +- EVE/alice-macros/clusters_from_index.C | 12 +- EVE/alice-macros/clusters_from_label.C | 12 +- EVE/alice-macros/emcal_digits.C | 28 +- EVE/alice-macros/emcal_hits.C | 16 +- EVE/alice-macros/esd_Cascade.C | 20 +- EVE/alice-macros/esd_V0.C | 26 +- EVE/alice-macros/esd_V0_points.C | 11 +- EVE/alice-macros/esd_spd_tracklets.C | 8 +- EVE/alice-macros/esd_tracks.C | 114 +- EVE/alice-macros/fmd_hits.C | 12 +- EVE/alice-macros/geom_acorde.C | 24 +- EVE/alice-macros/geom_all.C | 11 +- EVE/alice-macros/geom_ddip.C | 10 +- EVE/alice-macros/geom_emcal.C | 11 +- EVE/alice-macros/geom_fmd.C | 25 +- EVE/alice-macros/geom_gentle.C | 6 +- EVE/alice-macros/geom_hmpid.C | 14 +- EVE/alice-macros/geom_its.C | 11 +- EVE/alice-macros/geom_phos.C | 14 +- EVE/alice-macros/geom_pmd.C | 10 +- EVE/alice-macros/geom_simple.C | 11 +- EVE/alice-macros/geom_t0.C | 20 +- EVE/alice-macros/geom_tpc.C | 11 +- EVE/alice-macros/geom_trd_tof.C | 9 +- EVE/alice-macros/geom_vzero.C | 20 +- EVE/alice-macros/hits_from_label.C | 23 +- EVE/alice-macros/hmpid_clusters.C | 24 +- EVE/alice-macros/init_trd.C | 16 +- EVE/alice-macros/its_clusters.C | 24 +- EVE/alice-macros/its_digits.C | 100 +- EVE/alice-macros/its_hits.C | 16 +- EVE/alice-macros/its_hits_layer_split.C | 15 +- EVE/alice-macros/its_module_stepper.C | 10 +- EVE/alice-macros/its_raw.C | 100 +- EVE/alice-macros/jetplane.C | 57 +- EVE/alice-macros/kine_tracks.C | 66 +- EVE/alice-macros/phos_clusters.C | 14 +- EVE/alice-macros/pmd_digits.C | 25 +- EVE/alice-macros/pmd_hits.C | 12 +- EVE/alice-macros/pmd_raw.C | 23 +- EVE/alice-macros/primary_vertex.C | 65 +- EVE/alice-macros/primary_vertex_tracks.C | 16 +- EVE/alice-macros/region_marker.C | 10 +- EVE/alice-macros/t0_digits.C | 16 +- EVE/alice-macros/t0_hits.C | 18 +- EVE/alice-macros/tof_digits.C | 12 +- EVE/alice-macros/tof_digits_sector.C | 12 +- EVE/alice-macros/tof_digits_strips.C | 20 +- EVE/alice-macros/tof_hits.C | 16 +- EVE/alice-macros/tpc_calib_viewer.C | 2 +- EVE/alice-macros/tpc_clusters.C | 24 +- EVE/alice-macros/tpc_digits.C | 52 +- EVE/alice-macros/tpc_hits.C | 18 +- EVE/alice-macros/tpc_hits_charge_split.C | 10 +- EVE/alice-macros/tpc_hits_eta_split.C | 10 +- EVE/alice-macros/trd_hits.C | 16 +- EVE/alice-macros/trd_hits_z_split.C | 8 +- EVE/alice-macros/vzero_digits.C | 18 +- EVE/alice-macros/vzero_hits.C | 12 +- EVE/binalieve.pkg | 4 +- EVE/binreve.pkg | 17 - EVE/hlt-macros/command_queue.C | 22 +- EVE/hlt-macros/homer_display.C | 56 +- EVE/hlt-macros/rootlogon.C | 2 +- EVE/icons/fontdefault.txf | Bin 3220 -> 0 bytes EVE/icons/fonthelvetica34.txf | Bin 9364 -> 0 bytes EVE/icons/pointset.xpm | 25 - EVE/icons/rnr00_t.xpm | 23 - EVE/icons/rnr01_t.xpm | 23 - EVE/icons/rnr10_t.xpm | 23 - EVE/icons/rnr11_t.xpm | 23 - EVE/icons/scene.xpm | 24 - EVE/icons/track.xpm | 61 - EVE/icons/viewer.xpm | 108 - EVE/libReve.pkg | 8 - EVE/macros/alieve_create_vsd.C | 2 +- EVE/macros/alieve_init.C | 30 +- EVE/macros/alieve_loadlibs.C | 2 +- EVE/macros/isegv.C | 2 +- EVE/macros/reve_lineset_test.C | 25 - EVE/macros/reve_load_vsd.C | 7 - EVE/macros/reve_quad_test.C | 200 -- EVE/macros/reve_sa_init.C | 21 - EVE/macros/trackcount_init.C | 32 +- EVE/test-macros/broken_torus.tring | 1003 ------- EVE/test-macros/nasashuttle.3ds | Bin 219441 -> 0 bytes EVE/test-macros/tpc_digi_test.C | 4 +- EVE/test-macros/tpc_gui.C | 8 +- EVE/test-macros/tpc_gui_hack.C | 12 +- EVE/test-macros/tpc_raw_test.C | 4 +- EVE/test-macros/tpc_sector_raw_test.C | 12 +- EVE/test-macros/triangleset.C | 51 - EVE/test-macros/view3ds.C | 577 ---- 351 files changed, 1756 insertions(+), 32631 deletions(-) rename EVE/Alieve/{ => blacklisted-classes}/Cascade.cxx (100%) rename EVE/Alieve/{ => blacklisted-classes}/Cascade.h (100%) rename EVE/Alieve/{ => blacklisted-classes}/CascadeEditors.cxx (100%) rename EVE/Alieve/{ => blacklisted-classes}/CascadeEditors.h (100%) rename EVE/Alieve/{ => blacklisted-classes}/V0.cxx (100%) rename EVE/Alieve/{ => blacklisted-classes}/V0.h (100%) rename EVE/Alieve/{ => blacklisted-classes}/V0Editors.cxx (100%) rename EVE/Alieve/{ => blacklisted-classes}/V0Editors.h (100%) delete mode 100644 EVE/Reve/.SKEL-ged.cxx delete mode 100644 EVE/Reve/.SKEL-ged.h delete mode 100644 EVE/Reve/.SKEL-gedsubed.cxx delete mode 100644 EVE/Reve/.SKEL-gedsubed.h delete mode 100644 EVE/Reve/.SKEL-gl.cxx delete mode 100644 EVE/Reve/.SKEL-gl.h delete mode 100644 EVE/Reve/.SKEL.cxx delete mode 100644 EVE/Reve/.SKEL.h delete mode 100644 EVE/Reve/BoxSet.cxx delete mode 100644 EVE/Reve/BoxSet.h delete mode 100644 EVE/Reve/BoxSetGL.cxx delete mode 100644 EVE/Reve/BoxSetGL.h delete mode 100644 EVE/Reve/ChangeLog delete mode 100644 EVE/Reve/DigitSet.cxx delete mode 100644 EVE/Reve/DigitSet.h delete mode 100644 EVE/Reve/DigitSetEditor.cxx delete mode 100644 EVE/Reve/DigitSetEditor.h delete mode 100644 EVE/Reve/EventBase.cxx delete mode 100644 EVE/Reve/EventBase.h delete mode 100644 EVE/Reve/FrameBox.cxx delete mode 100644 EVE/Reve/FrameBox.h delete mode 100644 EVE/Reve/FrameBoxGL.cxx delete mode 100644 EVE/Reve/FrameBoxGL.h delete mode 100644 EVE/Reve/GLTextNS.cxx delete mode 100644 EVE/Reve/GLTextNS.h delete mode 100644 EVE/Reve/GLUtilNS.cxx delete mode 100644 EVE/Reve/GLUtilNS.h delete mode 100644 EVE/Reve/GeoNode.cxx delete mode 100644 EVE/Reve/GeoNode.h delete mode 100644 EVE/Reve/GeoNodeEditor.cxx delete mode 100644 EVE/Reve/GeoNodeEditor.h delete mode 100644 EVE/Reve/GridStepper.cxx delete mode 100644 EVE/Reve/GridStepper.h delete mode 100644 EVE/Reve/GridStepperEditor.cxx delete mode 100644 EVE/Reve/GridStepperEditor.h delete mode 100644 EVE/Reve/Line.cxx delete mode 100644 EVE/Reve/Line.h delete mode 100644 EVE/Reve/LineEditor.cxx delete mode 100644 EVE/Reve/LineEditor.h delete mode 100644 EVE/Reve/LineGL.cxx delete mode 100644 EVE/Reve/LineGL.h delete mode 100644 EVE/Reve/LinkDef.h delete mode 100644 EVE/Reve/MCHelixLine.hi delete mode 100644 EVE/Reve/Makefile delete mode 100644 EVE/Reve/NLTBases.cxx delete mode 100644 EVE/Reve/NLTBases.h delete mode 100644 EVE/Reve/NLTPointSetGL.cxx delete mode 100644 EVE/Reve/NLTPointSetGL.h delete mode 100644 EVE/Reve/NLTPolygonSet.cxx delete mode 100644 EVE/Reve/NLTPolygonSet.h delete mode 100644 EVE/Reve/NLTPolygonSetEditor.cxx delete mode 100644 EVE/Reve/NLTPolygonSetEditor.h delete mode 100644 EVE/Reve/NLTPolygonSetGL.cxx delete mode 100644 EVE/Reve/NLTPolygonSetGL.h delete mode 100644 EVE/Reve/NLTProjections.cxx delete mode 100644 EVE/Reve/NLTProjections.h delete mode 100644 EVE/Reve/NLTProjector.cxx delete mode 100644 EVE/Reve/NLTProjector.h delete mode 100644 EVE/Reve/NLTProjectorEditor.cxx delete mode 100644 EVE/Reve/NLTProjectorEditor.h delete mode 100644 EVE/Reve/NLTProjectorGL.cxx delete mode 100644 EVE/Reve/NLTProjectorGL.h delete mode 100644 EVE/Reve/NLTTrack.cxx delete mode 100644 EVE/Reve/NLTTrack.h delete mode 100644 EVE/Reve/NLTTrackGL.cxx delete mode 100644 EVE/Reve/NLTTrackGL.h delete mode 100644 EVE/Reve/PODs.cxx delete mode 100644 EVE/Reve/PODs.h delete mode 100644 EVE/Reve/Pad.cxx delete mode 100644 EVE/Reve/Pad.h delete mode 100644 EVE/Reve/Plex.cxx delete mode 100644 EVE/Reve/Plex.h delete mode 100644 EVE/Reve/PointSet.cxx delete mode 100644 EVE/Reve/PointSet.h delete mode 100644 EVE/Reve/PointSetArrayEditor.cxx delete mode 100644 EVE/Reve/PointSetArrayEditor.h delete mode 100644 EVE/Reve/QuadSet.cxx delete mode 100644 EVE/Reve/QuadSet.h delete mode 100644 EVE/Reve/QuadSetGL.cxx delete mode 100644 EVE/Reve/QuadSetGL.h delete mode 100644 EVE/Reve/RGBAPalette.cxx delete mode 100644 EVE/Reve/RGBAPalette.h delete mode 100644 EVE/Reve/RGBAPaletteEditor.cxx delete mode 100644 EVE/Reve/RGBAPaletteEditor.h delete mode 100644 EVE/Reve/RGBrowser.cxx delete mode 100644 EVE/Reve/RGBrowser.h delete mode 100644 EVE/Reve/RGEditor.cxx delete mode 100644 EVE/Reve/RGEditor.h delete mode 100644 EVE/Reve/RGValuators.cxx delete mode 100644 EVE/Reve/RGValuators.h delete mode 100644 EVE/Reve/RMacro.cxx delete mode 100644 EVE/Reve/RMacro.h delete mode 100644 EVE/Reve/RenderElement.cxx delete mode 100644 EVE/Reve/RenderElement.h delete mode 100644 EVE/Reve/RenderElementEditor.cxx delete mode 100644 EVE/Reve/RenderElementEditor.h delete mode 100644 EVE/Reve/Reve.cxx delete mode 100644 EVE/Reve/Reve.h delete mode 100644 EVE/Reve/ReveManager.cxx delete mode 100644 EVE/Reve/ReveManager.h delete mode 100644 EVE/Reve/Scene.cxx delete mode 100644 EVE/Reve/Scene.h delete mode 100644 EVE/Reve/SceneInfo.cxx delete mode 100644 EVE/Reve/SceneInfo.h delete mode 100644 EVE/Reve/StraightLineSet.cxx delete mode 100644 EVE/Reve/StraightLineSet.h delete mode 100644 EVE/Reve/StraightLineSetEditor.cxx delete mode 100644 EVE/Reve/StraightLineSetEditor.h delete mode 100644 EVE/Reve/StraightLineSetGL.cxx delete mode 100644 EVE/Reve/StraightLineSetGL.h delete mode 100644 EVE/Reve/TGClassBrowser.cxx delete mode 100644 EVE/Reve/TGClassBrowser.h delete mode 100644 EVE/Reve/TGCommandPlugin.cxx delete mode 100644 EVE/Reve/TGCommandPlugin.h delete mode 100644 EVE/Reve/TGFileBrowser.cxx delete mode 100644 EVE/Reve/TGFileBrowser.h delete mode 100644 EVE/Reve/TGNewBrowser.cxx delete mode 100644 EVE/Reve/TGNewBrowser.h delete mode 100644 EVE/Reve/TGeoShapeExtract.cxx delete mode 100644 EVE/Reve/TGeoShapeExtract.h delete mode 100644 EVE/Reve/TTreeTools.cxx delete mode 100644 EVE/Reve/TTreeTools.h delete mode 100644 EVE/Reve/Track.cxx delete mode 100644 EVE/Reve/Track.h delete mode 100644 EVE/Reve/TrackEditors.cxx delete mode 100644 EVE/Reve/TrackEditors.h delete mode 100644 EVE/Reve/TrackGL.cxx delete mode 100644 EVE/Reve/TrackGL.h delete mode 100644 EVE/Reve/TrackRnrStyleEditor.cxx delete mode 100644 EVE/Reve/TrackRnrStyleEditor.h delete mode 100644 EVE/Reve/TriangleSet.cxx delete mode 100644 EVE/Reve/TriangleSet.h delete mode 100644 EVE/Reve/TriangleSetEditor.cxx delete mode 100644 EVE/Reve/TriangleSetEditor.h delete mode 100644 EVE/Reve/TriangleSetGL.cxx delete mode 100644 EVE/Reve/TriangleSetGL.h delete mode 100644 EVE/Reve/VSD.cxx delete mode 100644 EVE/Reve/VSD.h delete mode 100644 EVE/Reve/VSDEvent.cxx delete mode 100644 EVE/Reve/VSDEvent.h delete mode 100644 EVE/Reve/VSDSelector.cxx delete mode 100644 EVE/Reve/VSDSelector.h delete mode 100644 EVE/Reve/Viewer.cxx delete mode 100644 EVE/Reve/Viewer.h delete mode 100644 EVE/Reve/ZTrans.cxx delete mode 100644 EVE/Reve/ZTrans.h delete mode 100644 EVE/Reve/ZTransEditor.cxx delete mode 100644 EVE/Reve/ZTransEditor.h delete mode 100644 EVE/Reve/reve_main/reve_main.cxx delete mode 100644 EVE/binreve.pkg delete mode 100644 EVE/icons/fontdefault.txf delete mode 100644 EVE/icons/fonthelvetica34.txf delete mode 100644 EVE/icons/pointset.xpm delete mode 100644 EVE/icons/rnr00_t.xpm delete mode 100644 EVE/icons/rnr01_t.xpm delete mode 100644 EVE/icons/rnr10_t.xpm delete mode 100644 EVE/icons/rnr11_t.xpm delete mode 100644 EVE/icons/scene.xpm delete mode 100644 EVE/icons/track.xpm delete mode 100644 EVE/icons/viewer.xpm delete mode 100644 EVE/libReve.pkg delete mode 100644 EVE/macros/reve_lineset_test.C delete mode 100644 EVE/macros/reve_load_vsd.C delete mode 100644 EVE/macros/reve_quad_test.C delete mode 100644 EVE/macros/reve_sa_init.C delete mode 100644 EVE/test-macros/broken_torus.tring delete mode 100644 EVE/test-macros/nasashuttle.3ds delete mode 100644 EVE/test-macros/triangleset.C delete mode 100644 EVE/test-macros/view3ds.C diff --git a/EVE/Alieve/AliEVEHOMERManager.cxx b/EVE/Alieve/AliEVEHOMERManager.cxx index 3b3e698948b..a2097a54b10 100644 --- a/EVE/Alieve/AliEVEHOMERManager.cxx +++ b/EVE/Alieve/AliEVEHOMERManager.cxx @@ -71,7 +71,7 @@ ClassImp(AliEVEHOMERManager) //################################################################################## AliEVEHOMERManager::AliEVEHOMERManager( TString xmlFile ) : - Reve::RenderElementList("AliEVEHOMERManager"), + TEveElementList("AliEVEHOMERManager"), fLibManager(new AliHLTHOMERLibManager), fXMLFile(xmlFile), @@ -95,7 +95,7 @@ AliEVEHOMERManager::AliEVEHOMERManager( TString xmlFile ) : //################################################################################## AliEVEHOMERManager::AliEVEHOMERManager( const AliEVEHOMERManager& m) : - Reve::RenderElementList(m.GetName(), m.GetTitle()) + TEveElementList(m.GetName(), m.GetTitle()) { // see header file for class documentation diff --git a/EVE/Alieve/AliEVEHOMERManager.h b/EVE/Alieve/AliEVEHOMERManager.h index 9f2c44db080..7351f66d9a1 100644 --- a/EVE/Alieve/AliEVEHOMERManager.h +++ b/EVE/Alieve/AliEVEHOMERManager.h @@ -11,7 +11,7 @@ @brief Manager for HOMER in offline */ -#include +#include #include "TString.h" #include "TDOMParser.h" @@ -36,7 +36,7 @@ class AliHLTHOMERLibManager; * @ingroup alihlt_homer */ -class AliEVEHOMERManager : public Reve::RenderElementList +class AliEVEHOMERManager : public TEveElementList { public: diff --git a/EVE/Alieve/AliEVEHOMERManagerEditor.cxx b/EVE/Alieve/AliEVEHOMERManagerEditor.cxx index be09bf64829..041a3409ac8 100644 --- a/EVE/Alieve/AliEVEHOMERManagerEditor.cxx +++ b/EVE/Alieve/AliEVEHOMERManagerEditor.cxx @@ -11,9 +11,6 @@ #include #include #include - -using namespace Reve; - //______________________________________________________________________ // AliEVEHOMERManagerEditor // diff --git a/EVE/Alieve/AliEVEHOMERSource.cxx b/EVE/Alieve/AliEVEHOMERSource.cxx index 3ea36603d23..6730284bfdc 100644 --- a/EVE/Alieve/AliEVEHOMERSource.cxx +++ b/EVE/Alieve/AliEVEHOMERSource.cxx @@ -2,9 +2,6 @@ #include "AliEVEHOMERSource.h" -using namespace Reve; -//using namespace Alieve; - //______________________________________________________________________ // AliEVEHOMERSource // @@ -12,13 +9,13 @@ using namespace Reve; ClassImp(AliEVEHOMERSource) AliEVEHOMERSource::AliEVEHOMERSource(const Text_t* n, const Text_t* t) : - Reve::RenderElement(), + TEveElement(), TNamed(n, t), fSource(0) {} AliEVEHOMERSource::AliEVEHOMERSource(AliHLTHOMERSourceDesc* src, const Text_t* n, const Text_t* t) : - Reve::RenderElement(), + TEveElement(), TNamed(n, t), fSource(src) {} diff --git a/EVE/Alieve/AliEVEHOMERSource.h b/EVE/Alieve/AliEVEHOMERSource.h index 9d7e2835d57..7c155a3f3f6 100644 --- a/EVE/Alieve/AliEVEHOMERSource.h +++ b/EVE/Alieve/AliEVEHOMERSource.h @@ -3,14 +3,13 @@ #ifndef ALIEVE_AliEVEHOMERSource_H #define ALIEVE_AliEVEHOMERSource_H -#include -#include +#include #include class AliHLTHOMERSourceDesc; -class AliEVEHOMERSource : public Reve::RenderElement, +class AliEVEHOMERSource : public TEveElement, public TNamed { private: diff --git a/EVE/Alieve/AliEVEHOMERSourceList.cxx b/EVE/Alieve/AliEVEHOMERSourceList.cxx index d4b78191405..4086a217887 100644 --- a/EVE/Alieve/AliEVEHOMERSourceList.cxx +++ b/EVE/Alieve/AliEVEHOMERSourceList.cxx @@ -2,9 +2,6 @@ #include "AliEVEHOMERSourceList.h" -using namespace Reve; -//using namespace Alieve; - //______________________________________________________________________ // AliEVEHOMERSourceList // @@ -12,7 +9,7 @@ using namespace Reve; ClassImp(AliEVEHOMERSourceList) AliEVEHOMERSourceList::AliEVEHOMERSourceList(const Text_t* n, const Text_t* t) : - Reve::RenderElementList(n, t) + TEveElementList(n, t) { } diff --git a/EVE/Alieve/AliEVEHOMERSourceList.h b/EVE/Alieve/AliEVEHOMERSourceList.h index 6386c6b029a..94e96e85663 100644 --- a/EVE/Alieve/AliEVEHOMERSourceList.h +++ b/EVE/Alieve/AliEVEHOMERSourceList.h @@ -3,12 +3,11 @@ #ifndef ALIEVE_AliEVEHOMERSourceList_H #define ALIEVE_AliEVEHOMERSourceList_H -#include -#include +#include #include -class AliEVEHOMERSourceList : public Reve::RenderElementList +class AliEVEHOMERSourceList : public TEveElementList { private: AliEVEHOMERSourceList(const AliEVEHOMERSourceList&); // Not implemented diff --git a/EVE/Alieve/EventAlieve.cxx b/EVE/Alieve/EventAlieve.cxx index a4ed34803c0..13dbfbdd22d 100644 --- a/EVE/Alieve/EventAlieve.cxx +++ b/EVE/Alieve/EventAlieve.cxx @@ -1,8 +1,8 @@ // $Header$ #include "EventAlieve.h" -#include -#include +#include +#include #include #include @@ -19,8 +19,6 @@ #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -46,7 +44,7 @@ AliMagF* Alieve::Event::fgMagField = 0; Event::Event() : - EventBase(), + TEveEventManager(), fPath (), fEventId (0), fRunLoader (0), @@ -55,7 +53,7 @@ Event::Event() : {} Event::Event(TString path, Int_t ev) : - EventBase("AliEVE Event"), + TEveEventManager("AliEVE Event"), fPath (path), fEventId(-1), fRunLoader (0), @@ -70,16 +68,16 @@ Event::Event(TString path, Int_t ev) : void Event::Open() { - static const Exc_t eH("Event::Open "); + static const TEveException eH("Event::Open "); gSystem->ExpandPathName(fPath); - if(fPath[0] != '/') + if (fPath[0] != '/') fPath = Form("%s/%s", gSystem->WorkingDirectory(), fPath.Data()); Int_t runNo = -1; TString ga_path(Form("%s/galice.root", fPath.Data())); - if(gSystem->AccessPathName(ga_path, kReadPermission) == kFALSE) + if (gSystem->AccessPathName(ga_path, kReadPermission) == kFALSE) { fRunLoader = AliRunLoader::Open(ga_path); if (fRunLoader) @@ -112,7 +110,7 @@ void Event::Open() } if (fRunLoader == 0) { - if(fgAssertRunLoader) + if (fgAssertRunLoader) throw(eH + "Bootstraping of run-loader failed. Its precence was requested."); else Warning(eH, "Bootstraping of run-loader failed."); @@ -120,10 +118,10 @@ void Event::Open() TString esd_path(Form("%s/AliESDs.root", fPath.Data())); - if(gSystem->AccessPathName(esd_path, kReadPermission) == kFALSE) + if (gSystem->AccessPathName(esd_path, kReadPermission) == kFALSE) { fESDFile = new TFile(esd_path); - if(fESDFile->IsZombie() == kFALSE) + if (fESDFile->IsZombie() == kFALSE) { fESD = new AliESDEvent(); fESDTree = (TTree*) fESDFile->Get("esdTree"); @@ -134,7 +132,7 @@ void Event::Open() // Check if ESDfriends exists and attach the branch TString p = Form("%s/AliESDfriends.root", fPath.Data()); - if(gSystem->AccessPathName(p, kReadPermission) == kFALSE) + if (gSystem->AccessPathName(p, kReadPermission) == kFALSE) { fESDfriendExists = kTRUE; fESDTree->SetBranchStatus ("ESDfriend*", 1); @@ -184,22 +182,22 @@ void Event::Open() void Event::GotoEvent(Int_t event) { - static const Exc_t eH("Event::GotoEvent "); + static const TEveException eH("Event::GotoEvent "); Int_t maxEvent = 0; - if(fRunLoader) + if (fRunLoader) maxEvent = fRunLoader->GetNumberOfEvents() - 1; - else if(fESDTree) + else if (fESDTree) maxEvent = fESDTree->GetEntries() - 1; else throw(eH + "neither RunLoader nor ESD loaded."); - if(event < 0 || event > maxEvent) + if (event < 0 || event > maxEvent) throw(eH + Form("event %d not present, available range [%d, %d].", event, 0, maxEvent)); - ReveManager::RedrawDisabler rd(gReve); - gReve->Redraw3D(kFALSE, kTRUE); // Enforce drop of all logicals. + TEveManager::TRedrawDisabler rd(gEve); + gEve->Redraw3D(kFALSE, kTRUE); // Enforce drop of all logicals. // !!! MT this is somewhat brutal; at least optionally, one could be // a bit gentler, checking for objs owning their external refs and having @@ -209,13 +207,13 @@ void Event::GotoEvent(Int_t event) SetName(Form("Event %d", fEventId)); UpdateItems(); - if(fRunLoader) { - if(fRunLoader->GetEvent(fEventId) != 0) + if (fRunLoader) { + if (fRunLoader->GetEvent(fEventId) != 0) throw(eH + "failed getting required event."); } - if(fESDTree) { - if(fESDTree->GetEntry(fEventId) <= 0) + if (fESDTree) { + if (fESDTree->GetEntry(fEventId) <= 0) throw(eH + "failed getting required event from ESD."); if (fESDfriendExists) @@ -244,33 +242,33 @@ void Event::Close() AliRunLoader* Event::AssertRunLoader() { - static const Exc_t eH("Event::AssertRunLoader "); + static const TEveException eH("Event::AssertRunLoader "); - if(gEvent == 0) + if (gEvent == 0) throw(eH + "ALICE event not ready."); - if(gEvent->fRunLoader == 0) + if (gEvent->fRunLoader == 0) throw(eH + "AliRunLoader not initialised."); return gEvent->fRunLoader; } AliESDEvent* Event::AssertESD() { - static const Exc_t eH("Event::AssertESD "); + static const TEveException eH("Event::AssertESD "); - if(gEvent == 0) + if (gEvent == 0) throw(eH + "ALICE event not ready."); - if(gEvent->fESD == 0) + if (gEvent->fESD == 0) throw(eH + "AliESD not initialised."); return gEvent->fESD; } AliESDfriend* Event::AssertESDfriend() { - static const Exc_t eH("Event::AssertESDfriend "); + static const TEveException eH("Event::AssertESDfriend "); - if(gEvent == 0) + if (gEvent == 0) throw(eH + "ALICE event not ready."); - if(gEvent->fESDfriend == 0) + if (gEvent->fESDfriend == 0) throw(eH + "AliESDfriend not initialised."); return gEvent->fESDfriend; } @@ -289,7 +287,7 @@ AliMagF* Event::AssertMagField() TGeoManager* Event::AssertGeometry() { - static const Exc_t eH("Event::AssertGeometry "); + static const TEveException eH("Event::AssertGeometry "); if (AliGeomManager::GetGeometry() == 0) { diff --git a/EVE/Alieve/EventAlieve.h b/EVE/Alieve/EventAlieve.h index cb1d1959874..3fdc6b0cd2f 100644 --- a/EVE/Alieve/EventAlieve.h +++ b/EVE/Alieve/EventAlieve.h @@ -3,7 +3,7 @@ #ifndef ALIEVE_Event_H #define ALIEVE_Event_H -#include +#include class AliRunLoader; class AliESDEvent; @@ -17,7 +17,7 @@ class TGeoManager; namespace Alieve { -class Event : public Reve::EventBase +class Event : public TEveEventManager { private: Event(const Event&); // Not implemented diff --git a/EVE/Alieve/ITSDigitsInfo.cxx b/EVE/Alieve/ITSDigitsInfo.cxx index 057e3e6383e..418d6968e21 100644 --- a/EVE/Alieve/ITSDigitsInfo.cxx +++ b/EVE/Alieve/ITSDigitsInfo.cxx @@ -7,8 +7,8 @@ #include #include -#include -#include +#include +#include #include "ITSDigitsInfo.h" #include @@ -19,8 +19,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; using namespace std; @@ -43,7 +41,7 @@ ClassImp(ITSDigitsInfo) ITSDigitsInfo::ITSDigitsInfo() : TObject(), - ReferenceCount(), + TEveRefCnt(), fSPDmap(), fSDDmap(), fSSDmap(), fTree (0), fGeom (0), @@ -54,7 +52,7 @@ ITSDigitsInfo::ITSDigitsInfo() : void ITSDigitsInfo::InitInternals() { - static const Exc_t eH("ITSDigitsInfo::InitInternals "); + static const TEveException eH("ITSDigitsInfo::InitInternals "); fGeom = new AliITSgeom(); fGeom->ReadNewFile("$REVESYS/alice-data/ITSgeometry.det"); @@ -357,7 +355,7 @@ void ITSDigitsInfo::GetModuleIDs(ITSModuleSelection* sel, std::vector& i TVector3 v; Double_t x[9]; Int_t lay, lad, det; - ZTrans mx; + TEveTrans mx; for(Int_t id = idx0; idGetModuleId(id, lay, lad, det); if(sel->fLayer==lay || sel->fLayer==-1) diff --git a/EVE/Alieve/ITSDigitsInfo.h b/EVE/Alieve/ITSDigitsInfo.h index 2e93affe398..ee309575292 100644 --- a/EVE/Alieve/ITSDigitsInfo.h +++ b/EVE/Alieve/ITSDigitsInfo.h @@ -3,7 +3,7 @@ #ifndef ALIEVE_ITSDigitsInfo_H #define ALIEVE_ITSDigitsInfo_H -#include +#include #include #include @@ -43,7 +43,7 @@ public: /**************************************************************************/ // ITSDigitsInfo /**************************************************************************/ -class ITSDigitsInfo : public TObject, public Reve::ReferenceCount +class ITSDigitsInfo : public TObject, public TEveRefCnt { ITSDigitsInfo(const ITSDigitsInfo&); // Not implemented ITSDigitsInfo& operator=(const ITSDigitsInfo&); // Not implemented diff --git a/EVE/Alieve/ITSModule.cxx b/EVE/Alieve/ITSModule.cxx index d3c46fb9230..a3367a078f0 100644 --- a/EVE/Alieve/ITSModule.cxx +++ b/EVE/Alieve/ITSModule.cxx @@ -5,20 +5,18 @@ #include #include - -using namespace Reve; using namespace Alieve; Bool_t ITSModule::fgStaticInitDone = kFALSE; -FrameBox* ITSModule::fgSPDFrameBox = 0; -FrameBox* ITSModule::fgSDDFrameBox = 0; -FrameBox* ITSModule::fgSSDFrameBox = 0; +TEveFrameBox* ITSModule::fgSPDFrameBox = 0; +TEveFrameBox* ITSModule::fgSDDFrameBox = 0; +TEveFrameBox* ITSModule::fgSSDFrameBox = 0; -RGBAPalette* ITSModule::fgSPDPalette = 0; -RGBAPalette* ITSModule::fgSDDPalette = 0; -RGBAPalette* ITSModule::fgSSDPalette = 0; +TEveRGBAPalette* ITSModule::fgSPDPalette = 0; +TEveRGBAPalette* ITSModule::fgSDDPalette = 0; +TEveRGBAPalette* ITSModule::fgSSDPalette = 0; //__________________________________________________________________________ // ITSModule @@ -30,7 +28,7 @@ ClassImp(ITSModule) /**************************************************************************/ ITSModule::ITSModule(const Text_t* n, const Text_t* t) : - QuadSet(n, t), + TEveQuadSet(n, t), fInfo(0), fID(-1), fDetID(-1), fLayer(-1), fLadder(-1), fDet(-1), @@ -38,7 +36,7 @@ ITSModule::ITSModule(const Text_t* n, const Text_t* t) : {} ITSModule::ITSModule(Int_t gid, ITSDigitsInfo* info) : - QuadSet(Form("ITS module %d", gid)), + TEveQuadSet(Form("ITS module %d", gid)), fInfo (0), fID(-1), fDetID(-1), fLayer(-1), fLadder(-1), fDet(-1), @@ -64,12 +62,12 @@ void ITSModule::InitStatics(ITSDigitsInfo* info) Float_t dx = info->fSegSPD->Dx()*0.00005; Float_t dz = 3.50; - fgSPDFrameBox = new FrameBox(); + fgSPDFrameBox = new TEveFrameBox(); fgSPDFrameBox->SetAAQuadXZ(-dx, 0, -dz, 2*dx, 2*dz); fgSPDFrameBox->SetFrameColor((Color_t) 31); fgSPDFrameBox->SetFrameFill(kTRUE); fgSPDFrameBox->IncRefCount(); - fgSPDPalette = new RGBAPalette(info->fSPDMinVal,info->fSPDMaxVal); + fgSPDPalette = new TEveRGBAPalette(info->fSPDMinVal,info->fSPDMaxVal); fgSPDPalette->IncRefCount(); } @@ -77,12 +75,12 @@ void ITSModule::InitStatics(ITSDigitsInfo* info) Float_t dx = info->fSegSDD->Dx()*0.0001; Float_t dz = info->fSegSDD->Dz()*0.00005; - fgSDDFrameBox = new FrameBox(); + fgSDDFrameBox = new TEveFrameBox(); fgSDDFrameBox->SetAAQuadXZ(-dx, 0, -dz, 2*dx, 2*dz); fgSDDFrameBox->SetFrameColor((Color_t) 32); fgSDDFrameBox->SetFrameFill(kTRUE); fgSDDFrameBox->IncRefCount(); - fgSDDPalette = new RGBAPalette(info->fSDDMinVal,info->fSDDMaxVal); + fgSDDPalette = new TEveRGBAPalette(info->fSDDMinVal,info->fSDDMaxVal); fgSDDPalette->SetLimits(0, info->fSDDHighLim); // Set proper ADC range. fgSDDPalette->IncRefCount(); } @@ -91,12 +89,12 @@ void ITSModule::InitStatics(ITSDigitsInfo* info) Float_t dx = info->fSegSSD->Dx()*0.00005; Float_t dz = info->fSegSSD->Dz()*0.00005; - fgSSDFrameBox = new FrameBox(); + fgSSDFrameBox = new TEveFrameBox(); fgSSDFrameBox->SetAAQuadXZ(-dx, 0, -dz, 2*dx, 2*dz); fgSSDFrameBox->SetFrameColor((Color_t) 33); fgSSDFrameBox->SetFrameFill(kTRUE); fgSSDFrameBox->IncRefCount(); - fgSSDPalette = new RGBAPalette(info->fSSDMinVal,info->fSSDMaxVal); + fgSSDPalette = new TEveRGBAPalette(info->fSSDMinVal,info->fSSDMaxVal); fgSSDPalette->SetLimits(0, info->fSSDHighLim); // Set proper ADC range. fgSSDPalette->IncRefCount(); } @@ -117,7 +115,7 @@ void ITSModule::SetDigitsInfo(ITSDigitsInfo* info) void ITSModule::SetID(Int_t gid, Bool_t trans) { - static const Exc_t eH("ITSModule::SetID "); + static const TEveException eH("ITSModule::SetID "); if(fInfo == 0) throw(eH + "ITSDigitsInfo not set."); @@ -246,7 +244,7 @@ void ITSModule::LoadQuads() { // Here we still use 'z' for the name of axial coordinates. // The transforamtion matrix aplied rotates y -> z. - // We need this as QuadSet offers optimized treatment for + // We need this as TEveQuadSet offers optimized treatment for // quads in the x-y plane. // printf("its module load quads \n"); @@ -263,7 +261,7 @@ void ITSModule::LoadQuads() case 0: { // SPD AliITSsegmentationSPD* seg = fInfo->fSegSPD; - Reset(QT_RectangleXZFixedY, kFALSE, 32); + Reset(kQT_RectangleXZFixedY, kFALSE, 32); for (Int_t k=0; kfSegSDD; - Reset(QT_RectangleXZFixedY, kFALSE, 32); + Reset(kQT_RectangleXZFixedY, kFALSE, 32); for (Int_t k=0; kfSegSSD; - Reset(QT_LineXZFixedY, kFALSE, 32); + Reset(kQT_LineXZFixedY, kFALSE, 32); Float_t ap, an; // positive/negative angles -> offsets seg->Angles(ap, an); @@ -370,9 +368,9 @@ void ITSModule::SetTrans() void ITSModule::DigitSelected(Int_t idx) { - // Override control-click from QuadSet + // Override control-click from TEveQuadSet - DigitBase* qb = GetDigit(idx); + DigitBase_t* qb = GetDigit(idx); TObject* obj = qb->fId.GetObject(); AliITSdigit* d = dynamic_cast(obj); printf("ITSModule::QuadSelected "); Print(); diff --git a/EVE/Alieve/ITSModule.h b/EVE/Alieve/ITSModule.h index 23774a5e8a7..c366c516b1d 100644 --- a/EVE/Alieve/ITSModule.h +++ b/EVE/Alieve/ITSModule.h @@ -1,13 +1,13 @@ #ifndef ALIEVE_ITSModule_H #define ALIEVE_ITSModule_H -#include +#include #include namespace Alieve { -class ITSModule : public Reve::QuadSet +class ITSModule : public TEveQuadSet { ITSModule(const ITSModule&); // Not implemented ITSModule& operator=(const ITSModule&); // Not implemented @@ -50,13 +50,13 @@ public: virtual void Print(Option_t* opt="") const; - static Reve::FrameBox* fgSPDFrameBox; - static Reve::FrameBox* fgSDDFrameBox; - static Reve::FrameBox* fgSSDFrameBox; + static TEveFrameBox* fgSPDFrameBox; + static TEveFrameBox* fgSDDFrameBox; + static TEveFrameBox* fgSSDFrameBox; - static Reve::RGBAPalette* fgSPDPalette; - static Reve::RGBAPalette* fgSDDPalette; - static Reve::RGBAPalette* fgSSDPalette; + static TEveRGBAPalette* fgSPDPalette; + static TEveRGBAPalette* fgSDDPalette; + static TEveRGBAPalette* fgSSDPalette; ClassDef(ITSModule, 1); }; diff --git a/EVE/Alieve/ITSModuleStepper.cxx b/EVE/Alieve/ITSModuleStepper.cxx index c7fd4f96f76..0a7f1ebd853 100644 --- a/EVE/Alieve/ITSModuleStepper.cxx +++ b/EVE/Alieve/ITSModuleStepper.cxx @@ -4,11 +4,11 @@ #include "ITSDigitsInfo.h" #include "ITSScaledModule.h" -#include "Reve/ReveManager.h" -#include "Reve/RGEditor.h" -#include "Reve/GridStepper.h" -#include "Reve/GLTextNS.h" -#include "Reve/ZTrans.h" +#include +#include +#include +#include +#include #include @@ -23,8 +23,6 @@ // #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -34,7 +32,7 @@ using namespace Alieve; ClassImp(ITSModuleStepper) ITSModuleStepper::ITSModuleStepper(ITSDigitsInfo* di) : - RenderElementList("ITS 2DStore", "ITSModuleStepper", kTRUE), + TEveElementList("ITS 2DStore", "ITSModuleStepper", kTRUE), fPosition(0), @@ -64,14 +62,14 @@ ITSModuleStepper::ITSModuleStepper(ITSDigitsInfo* di) : fWActiveCol(45), fFontCol(8) { - // override member from base RenderElementList + // override member from base TEveElementList fChildClass = ITSScaledModule::Class(); SetMainColorPtr(&fWCol); fDigitsInfo->IncRefCount(); - fStepper = new GridStepper(); + fStepper = new TEveGridStepper(); fStepper->SetNs(5, 4); fScaleInfo = new DigitScaleInfo(); @@ -87,12 +85,12 @@ ITSModuleStepper::ITSModuleStepper(ITSDigitsInfo* di) : fText->SetGLTextAngles(0, 0, 0); fText->SetTextSize(fTextSize); - gReve->GetGLViewer()->AddOverlayElement(this); + gEve->GetGLViewer()->AddOverlayElement(this); } ITSModuleStepper::~ITSModuleStepper() { - gReve->GetGLViewer()->RemoveOverlayElement(this); + gEve->GetGLViewer()->RemoveOverlayElement(this); fScaleInfo->DecRefCount(); fDigitsInfo->DecRefCount(); @@ -107,11 +105,11 @@ ITSModuleStepper::~ITSModuleStepper() void ITSModuleStepper::Capacity() { - Int_t N = fStepper->Nx*fStepper->Ny; - if(N != GetNChildren()) + Int_t N = fStepper->GetNx()*fStepper->GetNy(); + if (N != GetNChildren()) { DestroyElements(); - for(Int_t m=0; mDisableRedraw(); + gEve->DisableRedraw(); Capacity(); UInt_t idx = fPosition; @@ -218,7 +216,7 @@ void ITSModuleStepper::Apply() { ITSScaledModule* mod = dynamic_cast(*childit); mod->SetID(fIDs[idx], kFALSE); - ZTrans& tr = mod->RefHMTrans(); + TEveTrans& tr = mod->RefHMTrans(); tr.UnitTrans(); tr.RotateLF(3,2,TMath::PiOver2()); tr.RotateLF(1,3,TMath::PiOver2()); @@ -231,20 +229,20 @@ void ITSModuleStepper::Apply() mz = -2*fp[2]; // fit width first - Double_t sx = fStepper->Dx; - Double_t sy = (mx*fStepper->Dx)/mz; - if(sy > fStepper->Dy) + Double_t sx = fStepper->GetDx(); + Double_t sy = (mx*fStepper->GetDx())/mz; + if(sy > fStepper->GetDy()) { // printf("fit width \n"); - sy = fStepper->Dy; - sx = (mz*fStepper->Dx)/mx; + sy = fStepper->GetDy(); + sx = (mz*fStepper->GetDx())/mx; } Float_t scale = (fExpandCell*sx)/mz; tr.Scale(scale, scale, scale); Float_t p[3]; fStepper->GetPosition(p); - tr.SetPos(p[0]+0.5*fStepper->Dx, p[1]+0.5*fStepper->Dy, p[2]+0.5*fStepper->Dz); + tr.SetPos(p[0]+0.5*fStepper->GetDx(), p[1]+0.5*fStepper->GetDy(), p[2]+0.5*fStepper->GetDz()); if(mod->GetSubDetID() == 2) mod->SetName(Form("SSD %d", idx)); @@ -265,7 +263,7 @@ void ITSModuleStepper::Apply() fStepper->Reset(); ElementChanged(); - gReve->EnableRedraw(); + gEve->EnableRedraw(); } /**************************************************************************/ @@ -370,10 +368,10 @@ void ITSModuleStepper::RenderFrame(Float_t dx, Float_t dy, Int_t id) glPushAttrib(GL_ENABLE_BIT | GL_POLYGON_BIT); glPolygonMode(GL_FRONT_AND_BACK, GL_LINE); UChar_t color[4]; - if(fWActive == id) - ColorFromIdx(fWActiveCol, color); + if (fWActive == id) + TEveUtil::ColorFromIdx(fWActiveCol, color); else - ColorFromIdx(fWCol, color); + TEveUtil:: ColorFromIdx(fWCol, color); glColor4ubv(color); glBegin(GL_QUADS); @@ -389,10 +387,10 @@ void ITSModuleStepper::RenderSymbol(Float_t dx, Float_t dy, Int_t id) glLoadName(id); UChar_t color[4]; - if(fWActive == id) - ColorFromIdx(fWActiveCol, color); + if (fWActive == id) + TEveUtil::ColorFromIdx(fWActiveCol, color); else - ColorFromIdx(fWCol, color); + TEveUtil::ColorFromIdx(fWCol, color); glColor4ubv(color); Float_t xs = dx/4, ys = dy/4; @@ -461,7 +459,7 @@ void ITSModuleStepper::RenderPalette(Float_t dx, Float_t x, Float_t y) glLoadIdentity(); glTranslatef(1 -x- dx, -1+y*4, 0); ITSModule* qs = dynamic_cast(*BeginChildren()); - RGBAPalette* p = qs->GetPalette(); + TEveRGBAPalette* p = qs->GetPalette(); glBegin(GL_QUAD_STRIP); glColor4ubv(p->ColorFromValue(p->GetMinVal())); glVertex2f(0, 0); @@ -592,7 +590,7 @@ void ITSModuleStepper::RenderMenu() //______________________________________________________________________ void ITSModuleStepper::RenderCellIDs() { - fText->SetTextSize(fStepper->Dy*0.1); + fText->SetTextSize(fStepper->GetDy()*0.1); fText->SetTextColor(fFontCol); Double_t x, y, z; Double_t sx, sy, sz; @@ -602,11 +600,11 @@ void ITSModuleStepper::RenderCellIDs() if(idx < fIDs.size()) { ITSScaledModule* mod = dynamic_cast(*childit); - ZTrans& tr = mod->RefHMTrans(); + TEveTrans& tr = mod->RefHMTrans(); TString name = Form("%d",mod->GetID()); tr.GetPos(x,y,z); - x += fStepper->Dx*0.5; - y -= fStepper->Dy*0.5; + x += fStepper->GetDx()*0.5; + y -= fStepper->GetDy()*0.5; z += 0.4; // !!! MT hack - cross check with overlay rendering. Float_t llx, lly, llz, urx, ury, urz; fText->BBox(name, llx, lly, llz, urx, ury, urz); @@ -683,7 +681,7 @@ Bool_t ITSModuleStepper::Handle(TGLRnrCtx & /*rnrCtx*/, break; } case 7: - gReve->GetEditor()->DisplayRenderElement(*BeginChildren()); + gEve->GetEditor()->DisplayElement(*BeginChildren()); break; case 8: diff --git a/EVE/Alieve/ITSModuleStepper.h b/EVE/Alieve/ITSModuleStepper.h index 17fa615a2e7..babfc34edb6 100644 --- a/EVE/Alieve/ITSModuleStepper.h +++ b/EVE/Alieve/ITSModuleStepper.h @@ -6,8 +6,8 @@ #include #include -#include -#include +#include +#include #include @@ -19,7 +19,7 @@ namespace Alieve { class ITSDigitsInfo; class DigitScaleInfo; -class ITSModuleStepper : public Reve::RenderElementList, +class ITSModuleStepper : public TEveElementList, public TGLOverlayElement { friend class ITSModuleStepperGL; @@ -40,7 +40,7 @@ protected: DigitScaleInfo* fScaleInfo; Int_t fSubDet; - Reve::GridStepper* fStepper; + TEveGridStepper* fStepper; TGLAxis* fAxis; TGLText* fText; Float_t fTextSize; @@ -74,9 +74,9 @@ protected: void RenderCellIDs(); // module ID navigation - Int_t Nxy(){ return fStepper->Nx*fStepper->Ny; } - void AddToList( Int_t modID ){ fIDs.push_back(modID);} - void ResetList(){ fIDs.clear();} + Int_t Nxy() const { return fStepper->GetNx()*fStepper->GetNy(); } + void AddToList(Int_t modID) { fIDs.push_back(modID);} + void ResetList() { fIDs.clear();} void SetFirst(Int_t first); public: @@ -95,8 +95,8 @@ public: virtual void Render(TGLRnrCtx& rnrCtx); // stepper - Reve::GridStepper* GetStepper(){return fStepper;} - void SetStepper(Reve::GridStepper* s){ fStepper = s; Apply();} + TEveGridStepper* GetStepper() { return fStepper; } + void SetStepper(TEveGridStepper* s) { fStepper = s; Apply(); } Int_t GetCurrentPage(); Int_t GetPages(); @@ -107,12 +107,11 @@ public: void Apply(); void Capacity(); - // getters/setters - Color_t GetWColor(){ return fWCol; }; - void SetWColor(Color_t c){ fWCol = c; } - TGLText* GetFont(){ return fText; } - void SetGLText(TGLText* t) {fText = t;} + Color_t GetWColor() { return fWCol; } + void SetWColor(Color_t c) { fWCol = c; } + TGLText* GetFont() { return fText; } + void SetGLText(TGLText* t) { fText = t; } ClassDef(ITSModuleStepper, 0); }; diff --git a/EVE/Alieve/ITSModuleStepperEditor.cxx b/EVE/Alieve/ITSModuleStepperEditor.cxx index 3568e466c85..f4608e1671b 100644 --- a/EVE/Alieve/ITSModuleStepperEditor.cxx +++ b/EVE/Alieve/ITSModuleStepperEditor.cxx @@ -2,8 +2,8 @@ #include "ITSModuleStepperEditor.h" #include -#include -#include +#include +#include #include #include @@ -13,8 +13,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -32,7 +30,7 @@ ITSModuleStepperEditor::ITSModuleStepperEditor(const TGWindow *p, Int_t width, I { MakeTitle("ITSModuleStepper"); - fStepper = new GridStepperSubEditor(this); + fStepper = new TEveGridStepperSubEditor(this); fStepper->Connect("Changed()", "Alieve::ITSModuleStepperEditor", this, "UpdateStore()"); AddFrame(fStepper, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 2, 0, 0, 0)); } @@ -54,5 +52,5 @@ void ITSModuleStepperEditor::UpdateStore() { fM->Apply(); Update(); - gReve->Redraw3D(kTRUE); + gEve->Redraw3D(kTRUE); } diff --git a/EVE/Alieve/ITSModuleStepperEditor.h b/EVE/Alieve/ITSModuleStepperEditor.h index bcc6311eda9..05bb764869e 100644 --- a/EVE/Alieve/ITSModuleStepperEditor.h +++ b/EVE/Alieve/ITSModuleStepperEditor.h @@ -9,10 +9,7 @@ class TGCheckButton; class TGNumberEntry; class TGColorSelect; -namespace Reve -{ -class GridStepperSubEditor; -} +class TEveGridStepperSubEditor; namespace Alieve { @@ -27,7 +24,7 @@ private: protected: ITSModuleStepper* fM; // fModel dynamic-casted to ITSModuleStepperEditor - Reve::GridStepperSubEditor* fStepper; + TEveGridStepperSubEditor* fStepper; public: ITSModuleStepperEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, UInt_t options = kChildFrame, Pixel_t back=GetDefaultFrameBackground()); diff --git a/EVE/Alieve/ITSScaledModule.cxx b/EVE/Alieve/ITSScaledModule.cxx index 2243c4e5367..5fc538931d4 100644 --- a/EVE/Alieve/ITSScaledModule.cxx +++ b/EVE/Alieve/ITSScaledModule.cxx @@ -5,8 +5,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -26,7 +24,7 @@ void DigitScaleInfo::ScaleChanged(Int_t s) fScale = s; ITSScaledModule* sm; - std::list::iterator i = fBackRefs.begin(); + std::list::iterator i = fBackRefs.begin(); while (i != fBackRefs.end()) { sm = dynamic_cast(*i); @@ -41,7 +39,7 @@ void DigitScaleInfo::StatTypeChanged(Int_t t) fSyncPalette = kTRUE; ITSScaledModule* sm; - std::list::iterator i = fBackRefs.begin(); + std::list::iterator i = fBackRefs.begin(); while (i != fBackRefs.end()) { sm = dynamic_cast(*i); @@ -106,7 +104,7 @@ void ITSScaledModule::LoadQuads() { // Here we still use 'z' for the name of axial coordinates. // The transforamtion matrix aplied rotates y -> z. - // We need this as QuadSet offers optimized treatment for + // We need this as TEveQuadSet offers optimized treatment for // quads in the x-y plane. TClonesArray *digits; @@ -127,7 +125,7 @@ void ITSScaledModule::LoadQuads() case 0: { // SPD - Reset(QT_RectangleXZFixedY, kFALSE, 32); + Reset(kQT_RectangleXZFixedY, kFALSE, 32); fNCz = fInfo->fSPDScaleZ[scale]; fNCx = fInfo->fSPDScaleX[scale]; @@ -181,7 +179,7 @@ void ITSScaledModule::LoadQuads() case 1: { // SDD - Reset(QT_RectangleXZFixedY, kFALSE, 32); + Reset(kQT_RectangleXZFixedY, kFALSE, 32); fNCz = fInfo->fSDDScaleZ[scale]; fNCx = fInfo->fSDDScaleX[scale]; @@ -236,7 +234,7 @@ void ITSScaledModule::LoadQuads() case 2: { // SSD - Reset(QT_LineXZFixedY, kFALSE, 32); + Reset(kQT_LineXZFixedY, kFALSE, 32); AliITSsegmentationSSD* seg = fInfo->fSegSSD; Float_t ap, an; // positive/negative angles -> offsets @@ -325,7 +323,7 @@ void ITSScaledModule::SetQuadValues() v = Nint(Sqrt(sd->sqr_sum) / sd->N); break; } - DigitBase* qb = GetDigit(i); + DigitBase_t* qb = GetDigit(i); qb->fValue = v; } } @@ -381,10 +379,10 @@ void ITSScaledModule::GetScaleData(Int_t& cnx, Int_t& cnz, Int_t& total) void ITSScaledModule::DigitSelected(Int_t idx) { - // Override control-click from QuadSet + // Override control-click from TEveQuadSet printf("ITSScaledModule::DigitSelected "); Print(); - DigitBase* qb = GetDigit(idx); + DigitBase_t* qb = GetDigit(idx); TObject* obj = qb->fId.GetObject(); ScaledDigit* sd = dynamic_cast(obj); TClonesArray *digits = fInfo->GetDigits(fID, fDetID); diff --git a/EVE/Alieve/ITSScaledModule.h b/EVE/Alieve/ITSScaledModule.h index 9def2f29295..ec5e986b821 100644 --- a/EVE/Alieve/ITSScaledModule.h +++ b/EVE/Alieve/ITSScaledModule.h @@ -3,7 +3,7 @@ #ifndef ALIEVE_ITSScaledModule_H #define ALIEVE_ITSScaledModule_H -#include +#include #include #include @@ -14,7 +14,7 @@ namespace Alieve { // DigitScaleInfo /**************************************************************************/ -class DigitScaleInfo : public TQObject, public Reve::ReferenceBackPtr +class DigitScaleInfo : public TQObject, public TEveRefBackPtr { public: enum StatType_e { ST_Occup, ST_Average, ST_Rms }; diff --git a/EVE/Alieve/ITSScaledModuleEditor.cxx b/EVE/Alieve/ITSScaledModuleEditor.cxx index 09fb8a12e93..59f4507483d 100644 --- a/EVE/Alieve/ITSScaledModuleEditor.cxx +++ b/EVE/Alieve/ITSScaledModuleEditor.cxx @@ -2,8 +2,8 @@ #include "ITSScaledModuleEditor.h" #include -#include -#include +#include +#include #include #include @@ -16,8 +16,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ diff --git a/EVE/Alieve/ITSScaledModuleEditor.h b/EVE/Alieve/ITSScaledModuleEditor.h index 9dcf19b4093..53972cad96f 100644 --- a/EVE/Alieve/ITSScaledModuleEditor.h +++ b/EVE/Alieve/ITSScaledModuleEditor.h @@ -4,18 +4,15 @@ #define ALIEVE_ITSScaledModuleEditor_H #include -#include +#include class TGNumberEntry; class TGColorSelect; class TGComboBox; -namespace Reve -{ -class RGValuator; -class RGDoubleValuator; -class RGBAPalette; -} +class TEveGValuator; +class TEveGDoubleValuator; +class TEveRGBAPalette; namespace Alieve { diff --git a/EVE/Alieve/JetPlane.cxx b/EVE/Alieve/JetPlane.cxx index fb41da5c9a5..a0a6adcf7db 100644 --- a/EVE/Alieve/JetPlane.cxx +++ b/EVE/Alieve/JetPlane.cxx @@ -24,7 +24,7 @@ Bool_t JetPlane::fgOneChgMass = kFALSE; ClassImp(JetPlane) JetPlane::JetPlane(Int_t iev) : - RenderElementList(Form("JetPlane %i",iev), Form("%i",iev)), + TEveElementList(Form("JetPlane %i",iev), Form("%i",iev)), fMinEta (-1.5 ), fMaxEta ( 1.5 ), diff --git a/EVE/Alieve/JetPlane.h b/EVE/Alieve/JetPlane.h index d6347a39905..5b631403652 100644 --- a/EVE/Alieve/JetPlane.h +++ b/EVE/Alieve/JetPlane.h @@ -3,9 +3,9 @@ #ifndef ALIEVE_JetPlane_H #define ALIEVE_JetPlane_H -#include -#include -#include +#include +#include +#include #include #include @@ -17,7 +17,7 @@ namespace Alieve { -class JetPlane : public Reve::RenderElementList, +class JetPlane : public TEveElementList, public TAtt3D, public TAttBBox { @@ -42,7 +42,7 @@ protected: Color_t fGridColor; - Reve::ZTrans fHMTrans; + TEveTrans fHMTrans; std::vector fJets; std::vector fTracks; @@ -109,12 +109,12 @@ public: virtual Bool_t CanEditMainColor() { return kTRUE; } virtual Bool_t CanEditMainHMTrans() { return kTRUE; } - virtual Reve::ZTrans* PtrMainHMTrans() { return &fHMTrans; } + virtual TEveTrans* PtrMainHMTrans() { return &fHMTrans; } virtual void ComputeBBox(); virtual void Paint(Option_t* option = ""); - Reve::ZTrans& RefHMTrans() { return fHMTrans; } + TEveTrans& RefHMTrans() { return fHMTrans; } void SetTransMatrix(Double_t* carr) { fHMTrans.SetFrom(carr); } void SetTransMatrix(const TGeoMatrix& mat) { fHMTrans.SetFrom(mat); } diff --git a/EVE/Alieve/JetPlaneEditor.cxx b/EVE/Alieve/JetPlaneEditor.cxx index a3f0c25a375..53b44160fa0 100644 --- a/EVE/Alieve/JetPlaneEditor.cxx +++ b/EVE/Alieve/JetPlaneEditor.cxx @@ -2,7 +2,7 @@ #include "JetPlaneEditor.h" #include -#include +#include #include #include @@ -14,8 +14,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -55,7 +53,7 @@ JetPlaneEditor::JetPlaneEditor(const TGWindow *p, Int_t width, Int_t height, AddFrame(fRnrTracks, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); fRnrTracks->Connect("Clicked()", "Alieve::JetPlaneEditor", this, "DoRnrTracks()"); - fEnergyScale = new RGValuator(this, "Length scale:", 110, 0); + fEnergyScale = new TEveGValuator(this, "Length scale:", 110, 0); fEnergyScale->SetLabelWidth(labelW); fEnergyScale->SetNELength(6); fEnergyScale->Build(); @@ -64,7 +62,7 @@ JetPlaneEditor::JetPlaneEditor(const TGWindow *p, Int_t width, Int_t height, fEnergyScale->Connect("ValueSet(Double_t)", "Alieve::JetPlaneEditor", this, "DoEnergyScale()"); AddFrame(fEnergyScale, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - fEnergyColorScale = new RGValuator(this, "Color scale:", 110, 0); + fEnergyColorScale = new TEveGValuator(this, "Color scale:", 110, 0); fEnergyColorScale->SetLabelWidth(labelW); fEnergyColorScale->SetNELength(6); fEnergyColorScale->Build(); @@ -73,14 +71,14 @@ JetPlaneEditor::JetPlaneEditor(const TGWindow *p, Int_t width, Int_t height, fEnergyColorScale->Connect("ValueSet(Double_t)", "Alieve::JetPlaneEditor", this, "DoEnergyColorScale()"); AddFrame(fEnergyColorScale, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - fOneSelection = new TGRadioButton(this, "&One Track/Jet"); - fTwoSelection = new TGRadioButton(this, "&Two Track/Jet"); + fOneSelection = new TGRadioButton(this, "&One TEveTrack/Jet"); + fTwoSelection = new TGRadioButton(this, "&Two TEveTrack/Jet"); AddFrame(fOneSelection, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); AddFrame(fTwoSelection, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); fOneSelection->Connect("Clicked()", "Alieve::JetPlaneEditor", this, "DoOneSelection()"); fTwoSelection->Connect("Clicked()", "Alieve::JetPlaneEditor", this, "DoTwoSelection()"); - // fInformationSetup = new TGTextButton(this, "Track/Jet Print"); + // fInformationSetup = new TGTextButton(this, "TEveTrack/Jet Print"); // AddFrame(fInformationSetup, new TGLayoutHints(kLHintsTop | kLHintsLeft, 2, 0, 2, 2)); // fInformationSetup->Connect("Clicked()", "Alieve::JetPlaneEditor", this, "DoStaticDataWindow()"); } @@ -217,7 +215,7 @@ JetPlaneEditor::StaticDataWindow::StaticDataWindow(const TGWindow *p, const TGWi fL3 = new TGLayoutHints(kLHintsTop | kLHintsLeft, 5, 5, 5, 5); - TGCompositeFrame *tf = fTab->AddTab("One Track/Jet"); + TGCompositeFrame *tf = fTab->AddTab("One TEveTrack/Jet"); // fF1 = new TGCompositeFrame(tf, 60, 20, kVerticalFrame); // fF1->AddFrame(new TGTextButton(fF1, "&Test button", 0), fL3); @@ -253,7 +251,7 @@ JetPlaneEditor::StaticDataWindow::StaticDataWindow(const TGWindow *p, const TGWi MapSubwindows(); Resize(); - SetWindowName("Track/Jet Common Setup"); + SetWindowName("TEveTrack/Jet Common Setup"); } JetPlaneEditor::StaticDataWindow::~StaticDataWindow() diff --git a/EVE/Alieve/JetPlaneEditor.h b/EVE/Alieve/JetPlaneEditor.h index 018a35c4128..ac5d2f50e47 100644 --- a/EVE/Alieve/JetPlaneEditor.h +++ b/EVE/Alieve/JetPlaneEditor.h @@ -11,14 +11,11 @@ class TGCheckButton; class TGNumberEntry; class TGColorSelect; -namespace Reve -{ - class RGValuator; -} +class TEveGValuator; namespace Alieve { -// class RGValuator; +// class TEveGValuator; class JetPlane; @@ -35,8 +32,8 @@ protected: // TGSomeWidget* fXYZZ; TGCheckButton* fRnrJets; TGCheckButton* fRnrTracks; - Reve::RGValuator* fEnergyScale; - Reve::RGValuator* fEnergyColorScale; + TEveGValuator* fEnergyScale; + TEveGValuator* fEnergyColorScale; TGButton *fOneSelection, *fTwoSelection; TGButton *fInformationSetup; diff --git a/EVE/Alieve/JetPlaneGL.cxx b/EVE/Alieve/JetPlaneGL.cxx index bf9703fb748..b229ce6f0ee 100644 --- a/EVE/Alieve/JetPlaneGL.cxx +++ b/EVE/Alieve/JetPlaneGL.cxx @@ -2,7 +2,6 @@ #include "JetPlaneGL.h" #include -#include #include #include @@ -14,8 +13,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -96,7 +93,7 @@ void JetPlaneGL::DirectDraw(TGLRnrCtx & /*rnrCtx*/) const // Show axis tick marks and labels { - GLUtilNS::GL_Capability_Switch lights_off(GL_LIGHTING, false); + TGLCapabilitySwitch lights_off(GL_LIGHTING, false); TGLAxis ap; ap.SetLineColor(fM->fGridColor); @@ -265,7 +262,7 @@ void JetPlaneGL::ProcessSelection(TGLRnrCtx & /*rnrCtx*/, TGLSelectRecord & rec) if (rec.GetN() == 3) { AliAODTrack v = fM->fTracks[rec.GetItem(2)]; - printf("Track 4-momentum: %f, %f, %f, %f \n", v.Px(),v.Py(),v.Pz(),v.Pt() ); + printf("TEveTrack 4-momentum: %f, %f, %f, %f \n", v.Px(),v.Py(),v.Pz(),v.Pt() ); printf("Eta-Phi values: %f, %f\n", v.Eta(), v.Phi()); } } @@ -311,8 +308,8 @@ void JetPlaneGL::ProcessSelection(TGLRnrCtx & /*rnrCtx*/, TGLSelectRecord & rec) track2State = 1; } - printf("Jet: %i, Track: %i \n", jet1State, track1State); - printf("Jet: %i, Track: %i \n\n", jet2State, track2State); + printf("Jet: %i, TEveTrack: %i \n", jet1State, track1State); + printf("Jet: %i, TEveTrack: %i \n\n", jet2State, track2State); if(jet1State && jet2State) { diff --git a/EVE/Alieve/KineTools.cxx b/EVE/Alieve/KineTools.cxx index cd201c50e0d..e8771176bb4 100644 --- a/EVE/Alieve/KineTools.cxx +++ b/EVE/Alieve/KineTools.cxx @@ -10,8 +10,8 @@ #include #include -#include "Reve/Track.h" -#include "Reve/RenderElement.h" +#include +#include #include #include @@ -19,8 +19,6 @@ //______________________________________________________________________ // KineTools // - -using namespace Reve; using namespace Alieve; using namespace std; @@ -31,25 +29,25 @@ KineTools::KineTools() /**************************************************************************/ -void KineTools::SetDaughterPathMarks(RenderElement* cont, AliStack* stack, Bool_t recurse) +void KineTools::SetDaughterPathMarks(TEveElement* cont, AliStack* stack, Bool_t recurse) { // Import daughters birth points. - RenderElement::List_i iter = cont->BeginChildren(); + TEveElement::List_i iter = cont->BeginChildren(); while(iter != cont->EndChildren()) { - Track* track = dynamic_cast(*iter); + TEveTrack* track = dynamic_cast(*iter); TParticle* p = stack->Particle(track->GetLabel()); if(p->GetNDaughters()) { Int_t d0 = p->GetDaughter(0), d1 = p->GetDaughter(1); for(int d=d0; d>0 && d<=d1; ++d) { TParticle* dp = stack->Particle(d); - Reve::PathMark* pm = new PathMark(PathMark::Daughter); - pm->V.Set(dp->Vx(), dp->Vy(), dp->Vz()); - pm->P.Set(dp->Px(), dp->Py(), dp->Pz()); - pm->time = dp->T(); + TEvePathMark* pm = new TEvePathMark(TEvePathMark::kDaughter); + pm->fV.Set(dp->Vx(), dp->Vy(), dp->Vz()); + pm->fP.Set(dp->Px(), dp->Py(), dp->Pz()); + pm->fTime = dp->T(); track->AddPathMark(pm); } if (recurse) @@ -64,16 +62,16 @@ void KineTools::SetDaughterPathMarks(RenderElement* cont, AliStack* stack, Bool_ namespace { struct cmp_pathmark { - bool operator()(PathMark* const & a, PathMark* const & b) - { return a->time < b->time; } + bool operator()(TEvePathMark* const & a, TEvePathMark* const & b) + { return a->fTime < b->fTime; } }; -void slurp_tracks(map& tracks, RenderElement* cont, Bool_t recurse) +void slurp_tracks(map& tracks, TEveElement* cont, Bool_t recurse) { - RenderElement::List_i citer = cont->BeginChildren(); + TEveElement::List_i citer = cont->BeginChildren(); while(citer != cont->EndChildren()) { - Track* track = dynamic_cast(*citer); + TEveTrack* track = dynamic_cast(*citer); tracks[track->GetLabel()] = track; if (recurse) slurp_tracks(tracks, track, recurse); @@ -83,14 +81,14 @@ void slurp_tracks(map& tracks, RenderElement* cont, Bool_t recurs } -void KineTools::SetTrackReferences(RenderElement* cont, TTree* treeTR, Bool_t recurse) +void KineTools::SetTrackReferences(TEveElement* cont, TTree* treeTR, Bool_t recurse) { // set decay and reference points - static const Exc_t eH("KineTools::ImportPathMarks"); + static const TEveException eH("KineTools::ImportPathMarks"); // Fill map - map tracks; + map tracks; slurp_tracks(tracks, cont, recurse); Int_t nPrimaries = (Int_t) treeTR->GetEntries(); @@ -110,7 +108,7 @@ void KineTools::SetTrackReferences(RenderElement* cont, TTree* treeTR, Bool_t re el->GetEntry(iPrimPart); Int_t last_label = -1; - map::iterator iter = tracks.end(); + map::iterator iter = tracks.end(); Int_t Nent = arr->GetEntriesFast(); for (Int_t iTrackRef = 0; iTrackRef < Nent; iTrackRef++) { @@ -127,11 +125,11 @@ void KineTools::SetTrackReferences(RenderElement* cont, TTree* treeTR, Bool_t re } if (iter != tracks.end()) { - PathMark* pm = new PathMark(isRef ? PathMark::Reference : PathMark::Decay); - pm->V.Set(atr->X(),atr->Y(), atr->Z()); - pm->P.Set(atr->Px(),atr->Py(), atr->Pz()); - pm->time = atr->GetTime(); - Track* track = iter->second; + TEvePathMark* pm = new TEvePathMark(isRef ? TEvePathMark::kReference : TEvePathMark::kDecay); + pm->fV.Set(atr->X(),atr->Y(), atr->Z()); + pm->fP.Set(atr->Px(),atr->Py(), atr->Pz()); + pm->fTime = atr->GetTime(); + TEveTrack* track = iter->second; track->AddPathMark(pm); } } // loop track refs @@ -140,16 +138,16 @@ void KineTools::SetTrackReferences(RenderElement* cont, TTree* treeTR, Bool_t re } // end loop through top branches } -void KineTools::SortPathMarks(RenderElement* cont, Bool_t recurse) +void KineTools::SortPathMarks(TEveElement* cont, Bool_t recurse) { // Sort path-marks for all tracks by time. // Fill map - map tracks; + map tracks; slurp_tracks(tracks, cont, recurse); // sort - for(map::iterator j=tracks.begin(); j!=tracks.end(); ++j) + for(map::iterator j=tracks.begin(); j!=tracks.end(); ++j) { j->second->SortPathMarksByTime(); } diff --git a/EVE/Alieve/KineTools.h b/EVE/Alieve/KineTools.h index dc951d3288b..f76c86dd0b0 100644 --- a/EVE/Alieve/KineTools.h +++ b/EVE/Alieve/KineTools.h @@ -6,17 +6,16 @@ #ifndef ALIEVE_KineTools_H #define ALIEVE_KineTools_H -#include +#include #include class TTree; class AliStack; -namespace Reve { - class TrackList; -} +class TEveTrackList; namespace Alieve { + class KineTools { private: @@ -30,9 +29,9 @@ public: virtual ~KineTools(){} // data from TreeTR - void SetDaughterPathMarks(Reve::RenderElement* cont, AliStack* stack, Bool_t recurse=kFALSE); - void SetTrackReferences (Reve::RenderElement* cont, TTree* treeTR=0, Bool_t recurse=kFALSE); - void SortPathMarks (Reve::RenderElement* cont, Bool_t recurse=kFALSE); + void SetDaughterPathMarks(TEveElement* cont, AliStack* stack, Bool_t recurse=kFALSE); + void SetTrackReferences (TEveElement* cont, TTree* treeTR=0, Bool_t recurse=kFALSE); + void SortPathMarks (TEveElement* cont, Bool_t recurse=kFALSE); ClassDef(KineTools, 1); }; // endclass KineTools diff --git a/EVE/Alieve/LinkDef.h b/EVE/Alieve/LinkDef.h index eb722fb11e1..27bcd9f0437 100644 --- a/EVE/Alieve/LinkDef.h +++ b/EVE/Alieve/LinkDef.h @@ -25,15 +25,19 @@ // compound classes //================================ +// Removed. Messy code, tons of violations and incompatible with TEve +// classes. Author Ludovic Gaudichet left ALICE. +// Should be thoroughly revised. + // Cascade -#pragma link C++ class Alieve::Cascade+; -#pragma link C++ class Alieve::CascadeList+; -#pragma link C++ class Alieve::CascadeListEditor+; +//#pragma link C++ class Alieve::Cascade+; +//#pragma link C++ class Alieve::CascadeList+; +//#pragma link C++ class Alieve::CascadeListEditor+; // V0 -#pragma link C++ class Alieve::V0+; -#pragma link C++ class Alieve::V0List+; -#pragma link C++ class Alieve::V0ListEditor+; +//#pragma link C++ class Alieve::V0+; +//#pragma link C++ class Alieve::V0List+; +//#pragma link C++ class Alieve::V0ListEditor+; // Fit #pragma link C++ class Alieve::TrackFitter+; diff --git a/EVE/Alieve/MUONChamber.cxx b/EVE/Alieve/MUONChamber.cxx index b44abcc42ce..af8db6b3773 100644 --- a/EVE/Alieve/MUONChamber.cxx +++ b/EVE/Alieve/MUONChamber.cxx @@ -12,7 +12,6 @@ #include #include -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -23,7 +22,7 @@ ClassImp(MUONChamber) //______________________________________________________________________ MUONChamber::MUONChamber(Int_t id, const Text_t* n, const Text_t* t) : -Reve::RenderElement(fFrameColor), +TEveElement(fFrameColor), TNamed(n,t), fMUONData(0), fFrameColor((Color_t)2), @@ -186,7 +185,7 @@ void MUONChamber::SetupColor(Int_t val, UChar_t* pixel) const Int_t nCol = gStyle->GetNumberOfColors(); Int_t cBin = (Int_t) TMath::Nint(nCol*(val - fThreshold)/div); - ColorFromIdx(gStyle->GetColorPalette(TMath::Min(nCol - 1, cBin)), pixel); + TEveUtil::ColorFromIdx(gStyle->GetColorPalette(TMath::Min(nCol - 1, cBin)), pixel); } @@ -262,15 +261,15 @@ MUONChamberData* MUONChamber::GetChamberData() const void MUONChamber::UpdateQuads() { - fQuadSet1.Quads().clear(); - fQuadSet2.Quads().clear(); + fQuadSet1.Reset(TEveQuadSet::kQT_RectangleXY, kTRUE, 32); + fQuadSet2.Reset(TEveQuadSet::kQT_RectangleXY, kTRUE, 32); fPointSet1.Reset(); fPointSet2.Reset(); MUONChamberData* data = GetChamberData(); Float_t *buffer; - Float_t x0, y0, x1, y1, z, clsq; + Float_t x0, y0, z, w, h, clsq; Int_t charge, cathode, nDigits, nClusters, nHits, oldSize, ic1, ic2; Double_t clsX, clsY, clsZ; Float_t hitX, hitY, hitZ; @@ -289,8 +288,8 @@ void MUONChamber::UpdateQuads() x0 = buffer[0]-buffer[2]; y0 = buffer[1]-buffer[3]; - x1 = buffer[0]+buffer[2]; - y1 = buffer[1]+buffer[3]; + w = 2*buffer[2]; + h = 2*buffer[3]; z = buffer[4]; charge = (Int_t)buffer[5]; cathode = (Int_t)buffer[6]; @@ -299,39 +298,15 @@ void MUONChamber::UpdateQuads() if (cathode == 0) { - fQuadSet1.Quads().push_back(Reve::Quad()); - - fQuadSet1.Quads().back().ColorFromIdx(ColorIndex(charge)); - //ColorFromArray(charge,(UChar_t*)&fQuadSet1.fQuads.back().color); - - //UChar_t* c = (UChar_t*)&fQuadSet1.fQuads.back().color; - //printf("%d %d %d %d \n",c[0],c[1],c[2],c[3]); - - Float_t* p = fQuadSet1.Quads().back().vertices; - - p[0] = x0; p[1] = y0; p[2] = z; p += 3; - p[0] = x1; p[1] = y0; p[2] = z; p += 3; - p[0] = x1; p[1] = y1; p[2] = z; p += 3; - p[0] = x0; p[1] = y1; p[2] = z; p += 3; + fQuadSet1.AddQuad(x0, y0, z, w, h); + fQuadSet1.QuadColor(ColorIndex(charge)); } if (cathode == 1) { - fQuadSet2.Quads().push_back(Reve::Quad()); - - fQuadSet2.Quads().back().ColorFromIdx(ColorIndex(charge)); - //ColorFromArray(charge,(UChar_t*)&fQuadSet2.fQuads.back().color); - - //UChar_t* c = (UChar_t*)&fQuadSet2.fQuads.back().color; - //printf("%d %d %d %d \n",c[0],c[1],c[2],c[3]); - - Float_t* p = fQuadSet2.Quads().back().vertices; - - p[0] = x0; p[1] = y0; p[2] = z; p += 3; - p[0] = x1; p[1] = y0; p[2] = z; p += 3; - p[0] = x1; p[1] = y1; p[2] = z; p += 3; - p[0] = x0; p[1] = y1; p[2] = z; p += 3; + fQuadSet2.AddQuad(x0, y0, z, w, h); + fQuadSet2.QuadColor(ColorIndex(charge)); } diff --git a/EVE/Alieve/MUONChamber.h b/EVE/Alieve/MUONChamber.h index 730bb0925bf..355597993d3 100644 --- a/EVE/Alieve/MUONChamber.h +++ b/EVE/Alieve/MUONChamber.h @@ -1,9 +1,9 @@ #ifndef ALIEVE_MUONChamber_H #define ALIEVE_MUONChamber_H -#include -#include -#include +#include +#include +#include #include #include @@ -16,7 +16,7 @@ class MUONChamberData; class MUONChamberEditor; class MUONChamberGL; -class MUONChamber : public Reve::RenderElement, +class MUONChamber : public TEveElement, public TNamed, public TAtt3D, public TAttBBox @@ -37,10 +37,10 @@ class MUONChamber : public Reve::RenderElement, Color_t fFrameColor; // main coloring UInt_t fRTS; //! Rendering Time Stamp Int_t fChamberID; // number of the chamber, 0 to 13 - Reve::OldQuadSet fQuadSet1; // 1st cathode plane digits - Reve::OldQuadSet fQuadSet2; // 2nd cathode plane digits - Reve::PointSet fPointSet1; // reconstructed points (1st cathode) - Reve::PointSet fPointSet2; // simulation hits + TEveQuadSet fQuadSet1; // 1st cathode plane digits + TEveQuadSet fQuadSet2; // 2nd cathode plane digits + TEvePointSet fPointSet1; // reconstructed points (1st cathode) + TEvePointSet fPointSet2; // simulation hits Short_t fThreshold; // digit amplitude threshold Int_t fMaxVal; // digit amplitude maximum value Int_t fClusterSize; // cluster point size diff --git a/EVE/Alieve/MUONChamberData.cxx b/EVE/Alieve/MUONChamberData.cxx index bd4a6c94e98..551236f50d6 100644 --- a/EVE/Alieve/MUONChamberData.cxx +++ b/EVE/Alieve/MUONChamberData.cxx @@ -21,8 +21,6 @@ /// MUONChamberData: geometry and digits /// /////////////////////////////////////////////////////////////////////////////// - -using namespace Reve; using namespace Alieve; ClassImp(MUONChamberData) diff --git a/EVE/Alieve/MUONChamberData.h b/EVE/Alieve/MUONChamberData.h index aa78d387c2e..4ddfcc6f76b 100644 --- a/EVE/Alieve/MUONChamberData.h +++ b/EVE/Alieve/MUONChamberData.h @@ -1,7 +1,7 @@ #ifndef ALIEVE_MUONChamberData_H #define ALIEVE_MUONChamberData_H -#include +#include #include diff --git a/EVE/Alieve/MUONChamberEditor.cxx b/EVE/Alieve/MUONChamberEditor.cxx index a6ebe20a362..4e93f808f2e 100644 --- a/EVE/Alieve/MUONChamberEditor.cxx +++ b/EVE/Alieve/MUONChamberEditor.cxx @@ -2,7 +2,7 @@ #include -#include +#include #include #include @@ -13,8 +13,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -41,7 +39,7 @@ MUONChamberEditor::MUONChamberEditor(const TGWindow *p, Int_t labelW = 60; - fThreshold = new RGValuator(this, "ADC min", 200, 0); + fThreshold = new TEveGValuator(this, "ADC min", 200, 0); fThreshold->SetNELength(4); fThreshold->SetLabelWidth(labelW); fThreshold->Build(); @@ -51,7 +49,7 @@ MUONChamberEditor::MUONChamberEditor(const TGWindow *p, "Alieve::MUONChamberEditor", this, "DoThreshold()"); AddFrame(fThreshold, new TGLayoutHints(kLHintsTop, 1, 1, 2, 1)); - fMaxVal = new RGValuator(this,"ADC max", 200, 0); + fMaxVal = new TEveGValuator(this,"ADC max", 200, 0); fMaxVal->SetNELength(4); fMaxVal->SetLabelWidth(labelW); fMaxVal->Build(); @@ -61,7 +59,7 @@ MUONChamberEditor::MUONChamberEditor(const TGWindow *p, "Alieve::MUONChamberEditor", this, "DoMaxVal()"); AddFrame(fMaxVal, new TGLayoutHints(kLHintsTop, 1, 1, 2, 1)); - fClusterSize = new RGValuator(this,"Cls size", 200, 0); + fClusterSize = new TEveGValuator(this,"Cls size", 200, 0); fClusterSize->SetLabelWidth(labelW); fClusterSize->SetShowSlider(kFALSE); fClusterSize->SetNELength(4); @@ -72,7 +70,7 @@ MUONChamberEditor::MUONChamberEditor(const TGWindow *p, "Alieve::MUONChamberEditor", this, "DoClusterSize()"); AddFrame(fClusterSize, new TGLayoutHints(kLHintsTop, 1, 1, 2, 1)); - fHitSize = new RGValuator(this,"Hit size", 200, 0); + fHitSize = new TEveGValuator(this,"TEveHit size", 200, 0); fHitSize->SetLabelWidth(labelW); fHitSize->SetShowSlider(kFALSE); fHitSize->SetNELength(4); diff --git a/EVE/Alieve/MUONChamberEditor.h b/EVE/Alieve/MUONChamberEditor.h index 4086a1f14fe..2273183e33b 100644 --- a/EVE/Alieve/MUONChamberEditor.h +++ b/EVE/Alieve/MUONChamberEditor.h @@ -9,11 +9,7 @@ class TGColorSelect; class TGDoubleHSlider; class TGHSlider; -namespace Reve { - -class RGValuator; - -} +class TEveGValuator; namespace Alieve { @@ -29,10 +25,10 @@ class MUONChamberEditor : public TGedFrame MUONChamber* fM; // fModel dynamic-casted to MUONChamberEditor - Reve::RGValuator *fThreshold; // digit ADC min - Reve::RGValuator *fMaxVal; // digit ADC max - Reve::RGValuator *fClusterSize; // cluster point size - Reve::RGValuator *fHitSize; // hit point size + TEveGValuator *fThreshold; // digit ADC min + TEveGValuator *fMaxVal; // digit ADC max + TEveGValuator *fClusterSize; // cluster point size + TEveGValuator *fHitSize; // hit point size public: diff --git a/EVE/Alieve/MUONChamberGL.cxx b/EVE/Alieve/MUONChamberGL.cxx index 5ee93e0c0f5..e7ff592f860 100644 --- a/EVE/Alieve/MUONChamberGL.cxx +++ b/EVE/Alieve/MUONChamberGL.cxx @@ -24,11 +24,9 @@ #include #include -#include +#include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -68,7 +66,8 @@ Bool_t MUONChamberGL::SetModel(TObject* obj, const Option_t* /*opt*/) if(SetModelCheckClass(obj, Alieve::MUONChamber::Class())) { fChamber = (MUONChamber*) fExternalObj; - + fQS1.SetModel(&fChamber->fQuadSet1); + fQS2.SetModel(&fChamber->fQuadSet2); return kTRUE; } @@ -89,7 +88,7 @@ void MUONChamberGL::SetBBox() } //______________________________________________________________________ -void MUONChamberGL::DirectDraw(TGLRnrCtx& /*rnrCtx*/) const +void MUONChamberGL::DirectDraw(TGLRnrCtx& rnrCtx) const { // // Actual GL drawing. @@ -109,7 +108,7 @@ void MUONChamberGL::DirectDraw(TGLRnrCtx& /*rnrCtx*/) const if(hasData) { - DrawQuads(); + DrawQuads(rnrCtx); DrawPoints(); } @@ -119,7 +118,7 @@ void MUONChamberGL::DirectDraw(TGLRnrCtx& /*rnrCtx*/) const } //______________________________________________________________________ -void MUONChamberGL::DrawQuads() const +void MUONChamberGL::DrawQuads(TGLRnrCtx& rnrCtx) const { // // draw the digits as GL_QUADS @@ -137,30 +136,12 @@ void MUONChamberGL::DrawQuads() const glPolygonMode(GL_FRONT, GL_FILL); glPolygonMode(GL_BACK, GL_LINE); - glBegin(GL_QUADS); - for(std::vector::iterator q=fChamber->fQuadSet1.Quads().begin(); q!=fChamber->fQuadSet1.Quads().end(); ++q) { - UChar_t* c = (UChar_t*) &q->color; - glColor4ubv(c); - glVertex3fv(q->vertices); - glVertex3fv(q->vertices + 3); - glVertex3fv(q->vertices + 6); - glVertex3fv(q->vertices + 9); - } - glEnd(); + fQS1.DirectDraw(rnrCtx); glPolygonMode(GL_FRONT, GL_LINE); glPolygonMode(GL_BACK, GL_FILL); - glBegin(GL_QUADS); - for(std::vector::iterator q=fChamber->fQuadSet2.Quads().begin(); q!=fChamber->fQuadSet2.Quads().end(); ++q) { - UChar_t* c = (UChar_t*) &q->color; - glColor4ubv(c); - glVertex3fv(q->vertices); - glVertex3fv(q->vertices + 3); - glVertex3fv(q->vertices + 6); - glVertex3fv(q->vertices + 9); - } - glEnd(); + fQS2.DirectDraw(rnrCtx); glPopAttrib(); diff --git a/EVE/Alieve/MUONChamberGL.h b/EVE/Alieve/MUONChamberGL.h index ce4ef443d3f..4aa384b812c 100644 --- a/EVE/Alieve/MUONChamberGL.h +++ b/EVE/Alieve/MUONChamberGL.h @@ -2,10 +2,9 @@ #define ALIEVE_MUONChamberGL_H #include +#include -namespace Reve { -class QuadSetGL; -} +class TEveQuadSetGL; namespace Alieve { @@ -21,10 +20,13 @@ class MUONChamberGL : public TGLObject virtual void DirectDraw(TGLRnrCtx & rnrCtx) const; void DrawChamberFrame() const; - void DrawQuads() const; + void DrawQuads(TGLRnrCtx& rnrCtx) const; void DrawPoints() const; MUONChamber* fChamber; // fModel dynamic-casted to MUONChamberGL + TEveQuadSetGL fQS1; + TEveQuadSetGL fQS2; + mutable UInt_t fRTS; // render time stamp public: diff --git a/EVE/Alieve/MUONData.cxx b/EVE/Alieve/MUONData.cxx index 08e103a9588..e0c6f9edc18 100644 --- a/EVE/Alieve/MUONData.cxx +++ b/EVE/Alieve/MUONData.cxx @@ -31,8 +31,6 @@ #include "TString.h" #include "TClonesArray.h" #include "TList.h" - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -90,7 +88,7 @@ void MUONData::Reset() //______________________________________________________________________ MUONData::MUONData(const MUONData &mdata) : TObject(mdata), - Reve::ReferenceCount(), + TEveRefCnt(), fChambers(14), fNTrackList(0) { diff --git a/EVE/Alieve/MUONData.h b/EVE/Alieve/MUONData.h index 41f64d293d1..74d818b8ffd 100644 --- a/EVE/Alieve/MUONData.h +++ b/EVE/Alieve/MUONData.h @@ -1,7 +1,7 @@ #ifndef ALIEVE_MUONData_H #define ALIEVE_MUONData_H -#include +#include #include @@ -16,7 +16,7 @@ namespace Alieve { class MUONChamberData; -class MUONData : public TObject, public Reve::ReferenceCount +class MUONData : public TObject, public TEveRefCnt { protected: diff --git a/EVE/Alieve/MUONTrack.cxx b/EVE/Alieve/MUONTrack.cxx index 0a7fdae49bb..3260fb8a297 100644 --- a/EVE/Alieve/MUONTrack.cxx +++ b/EVE/Alieve/MUONTrack.cxx @@ -26,21 +26,19 @@ #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ // MUONTrack -// Produce Reve:Track from AliMUONTrack with dipole field model +// Produce TEveUtil:TEveTrack from AliMUONTrack with dipole field model ClassImp(MUONTrack) AliMagF* MUONTrack::fFieldMap = 0; //______________________________________________________________________ -MUONTrack::MUONTrack(Reve::RecTrack* t, TrackRnrStyle* rs) : - Reve::Track(t,rs), +MUONTrack::MUONTrack(TEveRecTrack* t, TEveTrackPropagator* rs) : + TEveTrack(t,rs), fTrack(0), fPart(0), fCount(0), @@ -142,7 +140,7 @@ void MUONTrack::PrintMUONTrackInfo() if (fIsMUONTrack) { cout << endl; - cout << " Track number " << fLabel << endl; + cout << " TEveTrack number " << fLabel << endl; cout << " ---------------------------------------------------------------------------------------------------------------------------------" << endl; cout << endl; cout << " Number of clusters " << fTrack->GetNClusters() << endl; @@ -155,7 +153,7 @@ void MUONTrack::PrintMUONTrackInfo() if (fIsRefTrack) { cout << endl; - cout << " Track reference number " << fLabel << endl; + cout << " TEveTrack reference number " << fLabel << endl; cout << " ---------------------------------------------------------------------------------------------------------------------------------" << endl; cout << endl; cout << " Number of clusters " << fTrack->GetNClusters() << endl; @@ -212,7 +210,7 @@ void MUONTrack::PrintMUONTrackInfo() } cout << endl; - cout << " Track parameters at vertex" << endl; + cout << " TEveTrack parameters at vertex" << endl; cout << " --------------------------------------------------------------------------------------------------------------------" << endl; cout << " InvBendMom BendSlope NonBendSlope BendCoord NonBendCoord Z Px Py Pz P" << endl; @@ -422,7 +420,7 @@ void MUONTrack::MUONTriggerInfo() // if (fIsMUONTrack) { - Reve::LoadMacro("MUON_trigger_info.C"); + TEveUtil::LoadMacro("MUON_trigger_info.C"); gROOT->ProcessLine(Form("MUON_trigger_info(%d);", fLabel)); } if (fIsRefTrack) { @@ -673,7 +671,7 @@ void MUONTrack::MakeMUONTrack(AliMUONTrack *mtrack) for (Int_t i = 0; i < nTrackHits; i++) { if (TMath::Abs(zr[i]) > 1000.0) { - //printf("Hit %d x %f y %f z %f \n",iHit,xr[i],yr[i],zr[i]); + //printf("TEveHit %d x %f y %f z %f \n",iHit,xr[i],yr[i],zr[i]); xrc[nrc] = xr[i]; yrc[nrc] = yr[i]; zrc[nrc] = zr[i]; @@ -838,7 +836,7 @@ void MUONTrack::MakeMCTrack(TParticle *part) fPart = new TParticle(*part); char form[1000]; - sprintf(form,"MCTrack %2d ", fLabel); + sprintf(form,"TEveMCTrack %2d ", fLabel); SetName(form); SetLineStyle(2); SetLineColor(8); diff --git a/EVE/Alieve/MUONTrack.h b/EVE/Alieve/MUONTrack.h index 66237d9042d..5c2059a09bd 100644 --- a/EVE/Alieve/MUONTrack.h +++ b/EVE/Alieve/MUONTrack.h @@ -1,7 +1,7 @@ #ifndef ALIEVE_MUONTrack_H #define ALIEVE_MUONTrack_H -#include +#include class AliMUONTrack; class AliMUONTriggerTrack; @@ -11,16 +11,12 @@ class AliTrackReference; class TParticle; -namespace Reve { - - class TrackRnrStyle; - class RecTrack; - -} +class TEveTrackPropagator; +class TEveRecTrack; namespace Alieve { -class MUONTrack: public Reve::Track +class MUONTrack: public TEveTrack { MUONTrack(const MUONTrack&); // Not implemented @@ -28,7 +24,7 @@ class MUONTrack: public Reve::Track public: - MUONTrack(Reve::RecTrack* t, Reve::TrackRnrStyle* rs); + MUONTrack(TEveRecTrack* t, TEveTrackPropagator* rs); virtual ~MUONTrack(); virtual void MakeTrack(Bool_t /*recurse*/=kFALSE) {} @@ -71,7 +67,7 @@ class MUONTrack: public Reve::Track static AliMagF *fFieldMap; // pointer to the magnetic field map - ClassDef(MUONTrack, 1); // Produce Reve:Track from AliMUONTrack + ClassDef(MUONTrack, 1); // Produce TEveUtil:TEveTrack from AliMUONTrack }; diff --git a/EVE/Alieve/PMDModule.cxx b/EVE/Alieve/PMDModule.cxx index 24c2018a607..6ad70eda33e 100644 --- a/EVE/Alieve/PMDModule.cxx +++ b/EVE/Alieve/PMDModule.cxx @@ -6,8 +6,6 @@ #include "AliPMDddldata.h" #include - -using namespace Reve; using namespace Alieve; const Float_t PMDModule::fgkRad = 0.25; @@ -47,7 +45,7 @@ void PMDModule::DisplayInit(Int_t ism) GenerateBox(ism,xism,yism,dxism,dyism); - Reve::FrameBox *pmdModBox = new FrameBox(); + TEveFrameBox *pmdModBox = new TEveFrameBox(); pmdModBox->SetAAQuadXY(xism, yism, 0, dxism, dyism); pmdModBox->SetFrameColor((Color_t) 31); pmdModBox->SetFrameFill(kTRUE); @@ -55,7 +53,7 @@ void PMDModule::DisplayInit(Int_t ism) SetName(smodule.Data()); SetOwnIds(kTRUE); - Reset(Reve::QuadSet::QT_HexagonXY, kFALSE, 32); + Reset(TEveQuadSet::kQT_HexagonXY, kFALSE, 32); fH1 = new TH1F("fH1", smodule.Data(), 100, 0., 1000.); fH1->SetDirectory(0); diff --git a/EVE/Alieve/PMDModule.h b/EVE/Alieve/PMDModule.h index 8b3db32e320..27030b64966 100644 --- a/EVE/Alieve/PMDModule.h +++ b/EVE/Alieve/PMDModule.h @@ -3,8 +3,8 @@ #ifndef ALIEVE_PMDModule_H #define ALIEVE_PMDModule_H -#include -#include +#include +#include #include #include @@ -13,7 +13,7 @@ namespace Alieve { -class PMDModule : public Reve::QuadSet +class PMDModule : public TEveQuadSet { private: PMDModule(const PMDModule&); // Not implemented diff --git a/EVE/Alieve/PMDModuleEditor.cxx b/EVE/Alieve/PMDModuleEditor.cxx index 42f83184b62..c270be14345 100644 --- a/EVE/Alieve/PMDModuleEditor.cxx +++ b/EVE/Alieve/PMDModuleEditor.cxx @@ -2,7 +2,7 @@ #include "PMDModuleEditor.h" #include -#include +#include #include #include @@ -16,12 +16,10 @@ #include #include -#include +#include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ diff --git a/EVE/Alieve/T0Module.cxx b/EVE/Alieve/T0Module.cxx index 470f610f72d..c2589823cee 100644 --- a/EVE/Alieve/T0Module.cxx +++ b/EVE/Alieve/T0Module.cxx @@ -9,7 +9,7 @@ #include #include #include -#include +#include #include #include "TArrayI.h" #include @@ -19,9 +19,6 @@ #include "AliT0RawReader.h" #include #include - - -using namespace Reve; using namespace Alieve; @@ -29,7 +26,7 @@ ClassImp(T0Module) /**************************************************************************/ T0Module::T0Module(const Text_t* n, Int_t sigType, AliT0digit *digits, AliT0RawReader *start) - : QuadSet(n), fSigType(sigType), fDigits(digits), fStart(start) + : TEveQuadSet(n), fSigType(sigType), fDigits(digits), fStart(start) { // // Default constructor @@ -53,12 +50,12 @@ void T0Module::LoadRaw(TString fileName, Int_t ievt) Int_t allData[110][5]; TRandom r(0); // cout<SetLimits(1, 3000); // Set proper raw time range. - Reve::QuadSet* raw_a = new T0Module("T0_RAW_A", 2,digits, start); raw_a->SetPalette(rawPalette); - raw_a->Reset(Reve::QuadSet::QT_HexagonXY, kFALSE, 32); - Reve::QuadSet* raw_c = new T0Module("T0_RAW_C", 3,digits, start); raw_c->SetPalette(rawPalette); - raw_c->Reset(Reve::QuadSet::QT_HexagonXY, kFALSE, 32); + TEveQuadSet* raw_a = new T0Module("T0_RAW_A", 2,digits, start); raw_a->SetPalette(rawPalette); + raw_a->Reset(TEveQuadSet::kQT_HexagonXY, kFALSE, 32); + TEveQuadSet* raw_c = new T0Module("T0_RAW_C", 3,digits, start); raw_c->SetPalette(rawPalette); + raw_c->Reset(TEveQuadSet::kQT_HexagonXY, kFALSE, 32); Float_t angle = 2 * TMath::Pi() / 12; start->Next(); for (Int_t i=0; i<110; i++) @@ -83,14 +80,14 @@ void T0Module::LoadRaw(TString fileName, Int_t ievt) raw_a->RefitPlex(); raw_c->RefitPlex(); - Reve::ZTrans& ta_a = raw_a->RefHMTrans(); + TEveTrans& ta_a = raw_a->RefHMTrans(); ta_a.SetPos(0, 0, 373); - Reve::ZTrans& tc_c = raw_c->RefHMTrans(); + TEveTrans& tc_c = raw_c->RefHMTrans(); tc_c.SetPos(0, 0, -69.7); - gReve->AddRenderElement(raw_a); - gReve->AddRenderElement(raw_c); - gReve->Redraw3D(); + gEve->AddElement(raw_a); + gEve->AddElement(raw_c); + gEve->Redraw3D(); } /**************************************************************************/ @@ -107,22 +104,22 @@ void T0Module::MakeModules(AliT0digit *digits) printf("%3d %3d\n ",ADC[i], TDC[i]); } - Reve::RGBAPalette* adcPalette = new RGBAPalette(5, 1024); + TEveRGBAPalette* adcPalette = new TEveRGBAPalette(5, 1024); adcPalette->SetLimits(1, 1024); // Set proper ADC range. - Reve::RGBAPalette* tdcPalette = new RGBAPalette(0, 9999); + TEveRGBAPalette* tdcPalette = new TEveRGBAPalette(0, 9999); tdcPalette->SetLimits(1, 9999); // Set proper TDC range. - Reve::QuadSet* qa = new T0Module("T0A_ADC", 0, digits); qa->SetPalette(adcPalette); - Reve::QuadSet* qc = new T0Module("T0C_ADC", 0, digits); qc->SetPalette(adcPalette); - Reve::QuadSet* qat = new T0Module("T0A_TDC", 1, digits); qat->SetPalette(tdcPalette); - Reve::QuadSet* qct = new T0Module("T0C_TDC", 1, digits); qct->SetPalette(tdcPalette); + TEveQuadSet* qa = new T0Module("T0A_ADC", 0, digits); qa->SetPalette(adcPalette); + TEveQuadSet* qc = new T0Module("T0C_ADC", 0, digits); qc->SetPalette(adcPalette); + TEveQuadSet* qat = new T0Module("T0A_TDC", 1, digits); qat->SetPalette(tdcPalette); + TEveQuadSet* qct = new T0Module("T0C_TDC", 1, digits); qct->SetPalette(tdcPalette); Float_t angle = 2 * TMath::Pi() / 12; - qa->Reset(Reve::QuadSet::QT_HexagonXY, kFALSE, 32); - qc->Reset(Reve::QuadSet::QT_HexagonXY, kFALSE, 32); - qat->Reset(Reve::QuadSet::QT_HexagonXY, kFALSE, 32); - qct->Reset(Reve::QuadSet::QT_HexagonXY, kFALSE, 32); + qa->Reset(TEveQuadSet::kQT_HexagonXY, kFALSE, 32); + qc->Reset(TEveQuadSet::kQT_HexagonXY, kFALSE, 32); + qat->Reset(TEveQuadSet::kQT_HexagonXY, kFALSE, 32); + qct->Reset(TEveQuadSet::kQT_HexagonXY, kFALSE, 32); @@ -152,31 +149,31 @@ void T0Module::MakeModules(AliT0digit *digits) qat->RefitPlex(); qct->RefitPlex(); - Reve::ZTrans& ta = qa->RefHMTrans(); + TEveTrans& ta = qa->RefHMTrans(); ta.SetPos(0, 0, 373); - Reve::ZTrans& tc = qc->RefHMTrans(); + TEveTrans& tc = qc->RefHMTrans(); tc.SetPos(0, 0, -69.7); - Reve::ZTrans& tat = qat->RefHMTrans(); + TEveTrans& tat = qat->RefHMTrans(); tat.SetPos(0, 0, 373); - Reve::ZTrans& tct = qct->RefHMTrans(); + TEveTrans& tct = qct->RefHMTrans(); tct.SetPos(0, 0, -69.7); - gReve->AddRenderElement(qa); - gReve->AddRenderElement(qc); - gReve->AddRenderElement(qat); - gReve->AddRenderElement(qct); + gEve->AddElement(qa); + gEve->AddElement(qc); + gEve->AddElement(qat); + gEve->AddElement(qct); - gReve->Redraw3D(); + gEve->Redraw3D(); } /**************************************************************************/ void T0Module::DigitSelected(Int_t idx) { - // Override control-click from QuadSet + // Override control-click from TEveQuadSet - DigitBase* qb = GetDigit(idx); + DigitBase_t* qb = GetDigit(idx); if (fSigType == 0) { //ADC printf("adc====================\n"); Int_t besttimeright = fDigits->BestTimeA(); diff --git a/EVE/Alieve/T0Module.h b/EVE/Alieve/T0Module.h index 239a87439bb..7ae20ccc7b1 100644 --- a/EVE/Alieve/T0Module.h +++ b/EVE/Alieve/T0Module.h @@ -8,13 +8,13 @@ ////////////////////////////////////////////////////////////////////////// -#include +#include #include #include namespace Alieve { -class T0Module : public Reve::QuadSet +class T0Module : public TEveQuadSet { T0Module(const T0Module&); diff --git a/EVE/Alieve/TOFDigitsInfo.cxx b/EVE/Alieve/TOFDigitsInfo.cxx index 94febe69471..7ee65b62b1d 100644 --- a/EVE/Alieve/TOFDigitsInfo.cxx +++ b/EVE/Alieve/TOFDigitsInfo.cxx @@ -2,14 +2,12 @@ // TOFDigitsInfo // -#include +#include #include "TOFDigitsInfo.h" #include #include //#include - -using namespace Reve; using namespace Alieve; using namespace std; @@ -19,7 +17,7 @@ ClassImp(TOFDigitsInfo) TOFDigitsInfo::TOFDigitsInfo(): TObject(), - ReferenceCount(), + TEveRefCnt(), fTree (0), fNewTree (0), fGeom (0), @@ -40,7 +38,7 @@ TOFDigitsInfo:: ~TOFDigitsInfo() void TOFDigitsInfo::SetTree(TTree* tree) { - static const Exc_t eH("TOFDigitsInfo::SetTree "); + static const TEveException eH("TOFDigitsInfo::SetTree "); if(fGeom == 0) { fGeom = new AliTOFGeometry(); @@ -74,8 +72,8 @@ void TOFDigitsInfo::LoadDigits() vol[0] = digs->GetSector(); // Sector Number (0-17) vol[1] = digs->GetPlate(); // Plate Number (0-4) vol[2] = digs->GetStrip(); // Strip Number (0-14/18) - vol[3] = digs->GetPadx(); // Pad Number in x direction (0-47) - vol[4] = digs->GetPadz(); // Pad Number in z direction (0-1) + vol[3] = digs->GetPadx(); // TEvePad Number in x direction (0-47) + vol[4] = digs->GetPadz(); // TEvePad Number in z direction (0-1) fTOFdigitMap->AddDigit(vol, digitNumber); //if (digitNumber==digitsTOF->GetEntries()-1) printf(" I am inside LoadDigits %3i \n", digitNumber); diff --git a/EVE/Alieve/TOFDigitsInfo.h b/EVE/Alieve/TOFDigitsInfo.h index 9c659c09e36..5fc64252d39 100644 --- a/EVE/Alieve/TOFDigitsInfo.h +++ b/EVE/Alieve/TOFDigitsInfo.h @@ -1,7 +1,7 @@ #ifndef ALIEVE_TOFDigitsInfo_H #define ALIEVE_TOFDigitsInfo_H -#include +#include //#include @@ -15,7 +15,7 @@ namespace Alieve { -class TOFDigitsInfo : public TObject, public Reve::ReferenceCount +class TOFDigitsInfo : public TObject, public TEveRefCnt { TOFDigitsInfo(const TOFDigitsInfo&); // Not implemented TOFDigitsInfo& operator=(const TOFDigitsInfo&); // Not implemented diff --git a/EVE/Alieve/TOFDigitsInfoEditor.cxx b/EVE/Alieve/TOFDigitsInfoEditor.cxx index 96e7c18b94c..462897fb681 100644 --- a/EVE/Alieve/TOFDigitsInfoEditor.cxx +++ b/EVE/Alieve/TOFDigitsInfoEditor.cxx @@ -11,8 +11,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ diff --git a/EVE/Alieve/TOFSector.cxx b/EVE/Alieve/TOFSector.cxx index 5460a1ac412..f5e0ca302eb 100644 --- a/EVE/Alieve/TOFSector.cxx +++ b/EVE/Alieve/TOFSector.cxx @@ -1,19 +1,17 @@ #include "TOFSector.h" -#include +#include #include #include #include - -using namespace Reve; using namespace Alieve; using namespace std; Bool_t TOFSector::fgStaticInitDone = kFALSE; -FrameBox* TOFSector::fgTOFsectorFrameBox = 0; -RGBAPalette* TOFSector::fgTOFsectorPalette = 0; +TEveFrameBox* TOFSector::fgTOFsectorFrameBox = 0; +TEveRGBAPalette* TOFSector::fgTOFsectorPalette = 0; //_______________________________________________________ ClassImp(TOFSector) @@ -21,7 +19,7 @@ ClassImp(TOFSector) /* ************************************************************************ */ TOFSector::TOFSector(const Text_t* n, const Text_t* t) : - QuadSet(n, t), + TEveQuadSet(n, t), fTOFgeometry(new AliTOFGeometry()), fTOFarray(0x0), fTOFtree(0x0), @@ -38,7 +36,7 @@ TOFSector::TOFSector(const Text_t* n, const Text_t* t) : for (Int_t ii=0; ii<5; ii++) fPlateFlag[ii]=kTRUE; - fGeoManager = (TGeoManager*)gReve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); + fGeoManager = (TGeoManager*)gEve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); if (!fGeoManager) { printf("ERROR: no TGeo\n"); } @@ -49,7 +47,7 @@ TOFSector::TOFSector(const Text_t* n, const Text_t* t) : TOFSector::TOFSector(TGeoManager *localGeoManager, Int_t nSector) : - QuadSet(Form("Sector%i",nSector)), + TEveQuadSet(Form("Sector%i",nSector)), fTOFgeometry(new AliTOFGeometry()), fTOFarray(0x0), fTOFtree(0x0), @@ -80,7 +78,7 @@ TOFSector::TOFSector(TGeoManager *localGeoManager, Int_t nSector, TClonesArray *tofArray) : - QuadSet(Form("Sector%i",nSector)), + TEveQuadSet(Form("Sector%i",nSector)), fTOFgeometry(new AliTOFGeometry()), fTOFarray(tofArray), fTOFtree(0x0), @@ -105,7 +103,7 @@ TOFSector::TOFSector(TGeoManager *localGeoManager, Int_t nSector, TTree *tofTree) : - QuadSet(Form("Sector%i",nSector)), + TEveQuadSet(Form("Sector%i",nSector)), fTOFgeometry(new AliTOFGeometry()), fTOFarray(0x0), fTOFtree(tofTree), @@ -157,13 +155,13 @@ void TOFSector::InitStatics() Float_t dx = 124.5; Float_t dz = 29.; Float_t dy = 370.6*2.; - fgTOFsectorFrameBox = new FrameBox(); + fgTOFsectorFrameBox = new TEveFrameBox(); fgTOFsectorFrameBox->SetAABox(-dx*0.5, -dy*0.5, -dz*0.5, dx, dy, dz); fgTOFsectorFrameBox->SetFrameColor((Color_t) 32);//31); - //fgTOFsectorPalette = new RGBAPalette(0, 2048); // TOT - fgTOFsectorPalette = new RGBAPalette(0, 8192/*1024*/); // TDC + //fgTOFsectorPalette = new TEveRGBAPalette(0, 2048); // TOT + fgTOFsectorPalette = new TEveRGBAPalette(0, 8192/*1024*/); // TDC fgTOFsectorPalette->SetLimits(0, 8192); fgStaticInitDone = kTRUE; @@ -194,7 +192,7 @@ void TOFSector::InitModule() void TOFSector::LoadQuads() { - Reset(QT_FreeQuad, kFALSE, 32); + Reset(kQT_FreeQuad, kFALSE, 32); //Int_t n_col = gStyle->GetNumberOfColors(); @@ -231,8 +229,8 @@ void TOFSector::LoadQuads() vol[1] = digs->GetPlate(); // Plate Number (0-4) vol[2] = digs->GetStrip(); // Strip Number (0-14/18) - vol[3] = digs->GetPadx(); // Pad Number in x direction (0-47) - vol[4] = digs->GetPadz(); // Pad Number in z direction (0-1) + vol[3] = digs->GetPadx(); // TEvePad Number in x direction (0-47) + vol[4] = digs->GetPadz(); // TEvePad Number in z direction (0-1) informations[0] = digs->GetTdc(); informations[1] = digs->GetAdc(); @@ -365,9 +363,9 @@ void TOFSector::SetMaxVal(Int_t mv) void TOFSector::DigitSelected(Int_t idx) { - // Override control-click from QuadSet + // Override control-click from TEveQuadSet - DigitBase* qb = GetDigit(idx); + DigitBase_t* qb = GetDigit(idx); TObject* obj = qb->fId.GetObject(); AliTOFdigit* digs = dynamic_cast(obj); // printf("TOFSector::QuadSelected "); Print(); diff --git a/EVE/Alieve/TOFSector.h b/EVE/Alieve/TOFSector.h index 4c6e46d6a54..7d19a8dd66c 100644 --- a/EVE/Alieve/TOFSector.h +++ b/EVE/Alieve/TOFSector.h @@ -1,11 +1,11 @@ #ifndef ALIEVE_TOFSector_H #define ALIEVE_TOFSector_H -#include -#include +#include +#include -#include -#include +#include +#include #include #include @@ -15,7 +15,7 @@ namespace Alieve { - class TOFSector : public Reve::QuadSet + class TOFSector : public TEveQuadSet { TOFSector(const TOFSector&); // Not implemented @@ -92,8 +92,8 @@ namespace Alieve { void SetPlate(Int_t nPlate, Bool_t r); - static Reve::FrameBox *fgTOFsectorFrameBox; - static Reve::RGBAPalette *fgTOFsectorPalette; + static TEveFrameBox *fgTOFsectorFrameBox; + static TEveRGBAPalette *fgTOFsectorPalette; ClassDef(TOFSector, 1); }; diff --git a/EVE/Alieve/TOFSectorEditor.cxx b/EVE/Alieve/TOFSectorEditor.cxx index 493cf966c9b..9a129346e61 100644 --- a/EVE/Alieve/TOFSectorEditor.cxx +++ b/EVE/Alieve/TOFSectorEditor.cxx @@ -5,7 +5,7 @@ #include #include -#include +#include #include #include @@ -13,8 +13,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -36,7 +34,7 @@ ClassImp(TOFSectorEditor) //{ /* - fHMTrans = new ZTransSubEditor(this); + fHMTrans = new TEveTransSubEditor(this); fHMTrans->Connect("UseTrans()", "Alieve::TPCSectorVizEditor", this, "Update()"); fHMTrans->Connect("TransChanged()", "Alieve::TPCSectorVizEditor", this, "Update()"); AddFrame(fHMTrans, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 2, 0, 0, 0)); @@ -50,7 +48,7 @@ ClassImp(TOFSectorEditor) //fPriority = 40; MakeTitle("TOFSector"); - fSectorID = new RGValuator(this, "SectorID", 110, 0); + fSectorID = new TEveGValuator(this, "SectorID", 110, 0); fSectorID->SetLabelWidth(60); fSectorID->SetShowSlider(kFALSE); fSectorID->SetNELength(4); @@ -111,7 +109,7 @@ ClassImp(TOFSectorEditor) AddFrame(f, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - fThreshold = new RGValuator(this, "Threshold", 200, 0); + fThreshold = new TEveGValuator(this, "Threshold", 200, 0); fThreshold->SetNELength(4); fThreshold->SetLabelWidth(60); fThreshold->Build(); @@ -121,7 +119,7 @@ ClassImp(TOFSectorEditor) "Alieve::TOFSectorEditor", this, "DoThreshold()"); AddFrame(fThreshold, new TGLayoutHints(kLHintsTop, 1, 1, 2, 1)); - fMaxVal = new RGValuator(this,"MaxVal", 200, 0); + fMaxVal = new TEveGValuator(this,"MaxVal", 200, 0); fMaxVal->SetNELength(4); fMaxVal->SetLabelWidth(60); fMaxVal->Build(); diff --git a/EVE/Alieve/TOFSectorEditor.h b/EVE/Alieve/TOFSectorEditor.h index 23ce680e9fc..618e8911ca3 100644 --- a/EVE/Alieve/TOFSectorEditor.h +++ b/EVE/Alieve/TOFSectorEditor.h @@ -12,11 +12,9 @@ class TGDoubleHSlider; class TGHSlider; -namespace Reve { - class RGValuator; - class RGDoubleValuator; - class ZTransSubEditor; -} +class TEveGValuator; +class TEveGDoubleValuator; +class TEveTransSubEditor; namespace Alieve { @@ -31,7 +29,7 @@ namespace Alieve { protected: TOFSector* fM; // fModel dynamic-casted to TOFSectorEditor - Reve::RGValuator* fSectorID; + TEveGValuator* fSectorID; TGCheckButton* fAutoTrans; @@ -43,8 +41,8 @@ namespace Alieve { TGCheckButton* fPlate3; TGCheckButton* fPlate4; - Reve::RGValuator* fThreshold; - Reve::RGValuator* fMaxVal; + TEveGValuator* fThreshold; + TEveGValuator* fMaxVal; // Declare widgets diff --git a/EVE/Alieve/TOFStrip.cxx b/EVE/Alieve/TOFStrip.cxx index a00b80ad3d1..7ea48956445 100644 --- a/EVE/Alieve/TOFStrip.cxx +++ b/EVE/Alieve/TOFStrip.cxx @@ -1,19 +1,17 @@ #include "TOFStrip.h" -#include +#include #include #include #include - -using namespace Reve; using namespace Alieve; using namespace std; Bool_t TOFStrip::fgStaticInitDone = kFALSE; -FrameBox* TOFStrip::fgTOFstripFrameBox = 0; -RGBAPalette* TOFStrip::fgTOFstripPalette = 0; +TEveFrameBox* TOFStrip::fgTOFstripFrameBox = 0; +TEveRGBAPalette* TOFStrip::fgTOFstripPalette = 0; //_______________________________________________________ ClassImp(TOFStrip) @@ -21,14 +19,14 @@ ClassImp(TOFStrip) /* ************************************************************************ */ TOFStrip::TOFStrip(const Text_t* n, const Text_t* t) : - QuadSet(n, t), + TEveQuadSet(n, t), fTOFgeometry(new AliTOFGeometry()), fTOFarray(0), fSector(-1), fPlate(-1), fStrip(-1), fDx(0), fDz(0) { - fGeoManager = (TGeoManager*)gReve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); + fGeoManager = (TGeoManager*)gEve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); if (!fGeoManager) printf("ERROR: no TGeo\n"); } @@ -37,7 +35,7 @@ TOFStrip::TOFStrip(const Text_t* n, const Text_t* t) : TOFStrip::TOFStrip(TGeoManager *localGeoManager, Int_t nSector, Int_t nPlate, Int_t nStrip) : - QuadSet(Form("Strip%i",nStrip)), + TEveQuadSet(Form("Strip%i",nStrip)), fTOFgeometry(new AliTOFGeometry()), fTOFarray(0), fSector(nSector), fPlate(nPlate), fStrip(nStrip), @@ -56,7 +54,7 @@ TOFStrip::TOFStrip(TGeoManager *localGeoManager, Int_t nSector, Int_t nPlate, Int_t nStrip, TClonesArray *tofArray) : - QuadSet(Form("Strip%i",nStrip)), + TEveQuadSet(Form("Strip%i",nStrip)), fTOFgeometry(new AliTOFGeometry()), fTOFarray(tofArray), fSector(nSector), fPlate(nPlate), fStrip(nStrip), @@ -97,13 +95,13 @@ void TOFStrip::InitStatics() Float_t dx = 2.5*48; Float_t dz = 3.5*2; - fgTOFstripFrameBox = new FrameBox(); + fgTOFstripFrameBox = new TEveFrameBox(); fgTOFstripFrameBox->SetAAQuadXZ(-dx*0.5, 0, -dz*0.5, dx, dz); fgTOFstripFrameBox->SetFrameColor((Color_t) 32);//31); - //fgTOFstripPalette = new RGBAPalette(0, 2048); // TOT - fgTOFstripPalette = new RGBAPalette(0, 8192); // TDC + //fgTOFstripPalette = new TEveRGBAPalette(0, 2048); // TOT + fgTOFstripPalette = new TEveRGBAPalette(0, 8192); // TDC fgStaticInitDone = kTRUE; } @@ -141,7 +139,7 @@ void TOFStrip::LoadQuads() Float_t x = -1; Float_t z = -1; - Reset(QT_RectangleXZFixedY, kFALSE, 32); + Reset(kQT_RectangleXZFixedY, kFALSE, 32); AliTOFdigit *tofDigit; diff --git a/EVE/Alieve/TOFStrip.h b/EVE/Alieve/TOFStrip.h index 2200bdbe24b..3f134b8fa7f 100644 --- a/EVE/Alieve/TOFStrip.h +++ b/EVE/Alieve/TOFStrip.h @@ -1,11 +1,11 @@ #ifndef ALIEVE_TOFStrip_H #define ALIEVE_TOFStrip_H -#include -#include +#include +#include -#include -#include +#include +#include #include #include @@ -14,7 +14,7 @@ namespace Alieve { -class TOFStrip : public Reve::QuadSet +class TOFStrip : public TEveQuadSet { TOFStrip(const TOFStrip&); // Not implemented TOFStrip& operator=(const TOFStrip&); // Not implemented @@ -52,9 +52,9 @@ public: static Bool_t fgStaticInitDone; static void InitStatics(); - static Reve::FrameBox* fgTOFstripFrameBox; + static TEveFrameBox* fgTOFstripFrameBox; - static Reve::RGBAPalette* fgTOFstripPalette; + static TEveRGBAPalette* fgTOFstripPalette; ClassDef(TOFStrip, 1); }; diff --git a/EVE/Alieve/TOFStripEditor.cxx b/EVE/Alieve/TOFStripEditor.cxx index 8d5826109c8..3e8d805aa7d 100644 --- a/EVE/Alieve/TOFStripEditor.cxx +++ b/EVE/Alieve/TOFStripEditor.cxx @@ -11,8 +11,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ diff --git a/EVE/Alieve/TPCData.cxx b/EVE/Alieve/TPCData.cxx index b15f8540e9d..63e7b01e94f 100644 --- a/EVE/Alieve/TPCData.cxx +++ b/EVE/Alieve/TPCData.cxx @@ -8,8 +8,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -151,7 +149,7 @@ void TPCData::LoadRaw(AliTPCRawStream& input, Bool_t spawnSectors, Bool_t warn) // via CreateSector() are loaded. // If spawnSectors is true sectors are created if data for them is encountered. - static const Exc_t eH("TPCData::LoadRaw "); + static const TEveException eH("TPCData::LoadRaw "); Int_t sector = -1, row = -1, pad = -1, rowOffset = 0; Short_t time, signal; diff --git a/EVE/Alieve/TPCData.h b/EVE/Alieve/TPCData.h index 719ad306f1a..04005d0b22a 100644 --- a/EVE/Alieve/TPCData.h +++ b/EVE/Alieve/TPCData.h @@ -3,7 +3,7 @@ #ifndef ALIEVE_TPCData_H #define ALIEVE_TPCData_H -#include +#include #include @@ -17,7 +17,7 @@ namespace Alieve { class TPCSectorData; -class TPCData : public TObject, public Reve::ReferenceCount +class TPCData : public TObject, public TEveRefCnt { protected: std::vector fSectors; diff --git a/EVE/Alieve/TPCLoader.cxx b/EVE/Alieve/TPCLoader.cxx index 00e2548f7e3..0792816f9fa 100644 --- a/EVE/Alieve/TPCLoader.cxx +++ b/EVE/Alieve/TPCLoader.cxx @@ -4,15 +4,13 @@ #include "TPCData.h" #include #include -#include -#include +#include +#include #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -22,7 +20,7 @@ using namespace Alieve; ClassImp(TPCLoader) TPCLoader::TPCLoader(const Text_t* n, const Text_t* t) : - RenderElementList(n, t), + TEveElementList(n, t), fFile(), fEvent(-1), @@ -49,7 +47,7 @@ TPCLoader::~TPCLoader() /**************************************************************************/ -void TPCLoader::RemoveElementLocal(RenderElement* el) +void TPCLoader::RemoveElementLocal(TEveElement* el) { for(Int_t i=0; i<36; ++i) { if(fSec2Ds[i] == el) fSec2Ds[i] = 0; @@ -77,7 +75,7 @@ void TPCLoader::SetData(TPCData* d) void TPCLoader::OpenFile() { - static const Exc_t eH("TPCLoader::OpenFile "); + static const TEveException eH("TPCLoader::OpenFile "); if(gSystem->AccessPathName(fFile, kReadPermission)) throw(eH + "can not read '" + fFile + "'."); @@ -100,7 +98,7 @@ void TPCLoader::OpenFile() void TPCLoader::LoadEvent() { - static const Exc_t eH("TPCLoader::LoadEvent "); + static const TEveException eH("TPCLoader::LoadEvent "); if(fReader == 0) throw(eH + "data file not opened."); @@ -117,7 +115,7 @@ void TPCLoader::LoadEvent() void TPCLoader::NextEvent(Bool_t rewindOnEnd) { - static const Exc_t eH("TPCLoader::NextEvent "); + static const TEveException eH("TPCLoader::NextEvent "); if(fReader == 0) throw(eH + "data file not opened."); @@ -140,7 +138,7 @@ void TPCLoader::NextEvent(Bool_t rewindOnEnd) void TPCLoader::GotoEvent(Int_t event) { - static const Exc_t eH("TPCLoader::GotoEvent "); + static const TEveException eH("TPCLoader::GotoEvent "); if(fReader == 0) throw(eH + "data file not opened."); @@ -167,8 +165,8 @@ void* TPCLoader::LoopEvent(TPCLoader* loader) loader->NextEvent(); loader->LoadEvent(); loader->UpdateSectors(); - if (gReve->GetEditor()->GetModel() == loader) - gReve->EditRenderElement(loader); + if (gEve->GetEditor()->GetModel() == loader) + gEve->EditElement(loader); return 0; } @@ -176,7 +174,7 @@ void* TPCLoader::LoopEvent(TPCLoader* loader) void TPCLoader::UpdateSectors(Bool_t dropNonPresent) { - gReve->DisableRedraw(); + gEve->DisableRedraw(); for(Int_t i=0; i<=35; ++i) { TPCSectorData* sd = fData->GetSectorData(i); @@ -185,7 +183,7 @@ void TPCLoader::UpdateSectors(Bool_t dropNonPresent) if(fSec2Ds[i] != 0) { if (dropNonPresent && sd == 0) { - gReve->RemoveRenderElement(fSec2Ds[i], this); + gEve->RemoveElement(fSec2Ds[i], this); fSec2Ds[i] = 0; } else { fSec2Ds[i]->IncRTS(); @@ -213,7 +211,7 @@ void TPCLoader::UpdateSectors(Bool_t dropNonPresent) s->SetAutoTrans(kTRUE); s->SetFrameColor(36); - gReve->AddRenderElement(s, this); + gEve->AddElement(s, this); } } @@ -221,7 +219,7 @@ void TPCLoader::UpdateSectors(Bool_t dropNonPresent) if(fSec3Ds[i] != 0) { if (dropNonPresent && sd == 0) { - gReve->RemoveRenderElement(fSec3Ds[i], this); + gEve->RemoveElement(fSec3Ds[i], this); fSec3Ds[i] = 0; } else { fSec3Ds[i]->IncRTS(); @@ -229,8 +227,8 @@ void TPCLoader::UpdateSectors(Bool_t dropNonPresent) } } } - gReve->Redraw3D(kTRUE, kFALSE); - gReve->EnableRedraw(); + gEve->Redraw3D(kTRUE, kFALSE); + gEve->EnableRedraw(); } void TPCLoader::ReloadSectors() @@ -241,7 +239,7 @@ void TPCLoader::ReloadSectors() void TPCLoader::CreateSectors3D() { - gReve->DisableRedraw(); + gEve->DisableRedraw(); for(Int_t i=0; i<=35; ++i) { TPCSectorData* sd = fData->GetSectorData(i); if(sd != 0 && fSec3Ds[i] == 0) { @@ -258,24 +256,24 @@ void TPCLoader::CreateSectors3D() s->SetAutoTrans(kTRUE); s->SetFrameColor(36); - gReve->AddRenderElement(s, this); + gEve->AddElement(s, this); } } - gReve->EnableRedraw(); + gEve->EnableRedraw(); } void TPCLoader::DeleteSectors3D() { - gReve->DisableRedraw(); + gEve->DisableRedraw(); for(Int_t i=0; i<=35; ++i) { - RenderElement* re = fSec3Ds[i]; + TEveElement* re = fSec3Ds[i]; if(re != 0) { - gReve->RemoveRenderElement(re, this); + gEve->RemoveElement(re, this); // delete re; // Done automatically. fSec3Ds[i] = 0; } } - gReve->EnableRedraw(); + gEve->EnableRedraw(); } /**************************************************************************/ diff --git a/EVE/Alieve/TPCLoader.h b/EVE/Alieve/TPCLoader.h index 702aa612767..f9996fa6ea2 100644 --- a/EVE/Alieve/TPCLoader.h +++ b/EVE/Alieve/TPCLoader.h @@ -3,7 +3,7 @@ #ifndef ALIEVE_TPCLoader_H #define ALIEVE_TPCLoader_H -#include +#include #include class AliRawReaderRoot; @@ -14,7 +14,7 @@ class TPCData; class TPCSector2D; class TPCSector3D; -class TPCLoader : public Reve::RenderElementList +class TPCLoader : public TEveElementList { friend class TPCLoaderEditor; @@ -43,7 +43,7 @@ public: TPCLoader(const Text_t* n="TPCLoader", const Text_t* t=0); virtual ~TPCLoader(); - virtual void RemoveElementLocal(Reve::RenderElement* el); + virtual void RemoveElementLocal(TEveElement* el); virtual void RemoveElementsLocal(); void SetFile(const Text_t* f) { fFile = f; } diff --git a/EVE/Alieve/TPCLoaderEditor.cxx b/EVE/Alieve/TPCLoaderEditor.cxx index 3c89a5e835d..6bb7dd99c18 100644 --- a/EVE/Alieve/TPCLoaderEditor.cxx +++ b/EVE/Alieve/TPCLoaderEditor.cxx @@ -3,8 +3,8 @@ #include "TPCLoaderEditor.h" #include #include -#include -#include +#include +#include #include #include @@ -16,8 +16,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -75,7 +73,7 @@ ClassImp(TPCLoaderEditor) AddFrame(f); } - fEvent = new RGValuator(this, "Event:", 110, 0); + fEvent = new TEveGValuator(this, "Event:", 110, 0); fEvent->SetShowSlider(kFALSE); fEvent->SetLabelWidth(labelW); fEvent->SetNELength(6); @@ -97,7 +95,7 @@ ClassImp(TPCLoaderEditor) labelW = 90; - fDataLoadThreshold = new RGValuator(this, "Load threshold:", 110, 0); + fDataLoadThreshold = new TEveGValuator(this, "Load threshold:", 110, 0); fDataLoadThreshold->SetShowSlider(kFALSE); fDataLoadThreshold->SetLabelWidth(labelW); fDataLoadThreshold->SetNELength(6); @@ -109,7 +107,7 @@ ClassImp(TPCLoaderEditor) "Alieve::TPCLoaderEditor", this, "DoDataLoadThreshold()"); AddFrame(fDataLoadThreshold, new TGLayoutHints(kLHintsLeft, 0, 0, 6, 0)); - fDataLoadPedestal = new RGValuator(this, "Load pedestal:", 110, 0); + fDataLoadPedestal = new TEveGValuator(this, "Load pedestal:", 110, 0); fDataLoadPedestal->SetShowSlider(kFALSE); fDataLoadPedestal->SetLabelWidth(labelW); fDataLoadPedestal->SetNELength(6); @@ -201,7 +199,7 @@ void TPCLoaderEditor::FileSelect() fi.fFilename = StrDup(gSystem->BaseName(fM->fFile)); fi.fFileTypes = tpcfiletypes; - new TGFileDialog(fClient->GetRoot(), gReve->GetMainWindow(), kFDOpen, &fi); + new TGFileDialog(fClient->GetRoot(), gEve->GetMainWindow(), kFDOpen, &fi); if (!fi.fFilename) return; diff --git a/EVE/Alieve/TPCLoaderEditor.h b/EVE/Alieve/TPCLoaderEditor.h index 6f9595e9189..47e6259c430 100644 --- a/EVE/Alieve/TPCLoaderEditor.h +++ b/EVE/Alieve/TPCLoaderEditor.h @@ -11,9 +11,7 @@ class TGNumberEntry; class TGColorSelect; class TGTextEntry; -namespace Reve { -class RGValuator; -} +class TEveGValuator; namespace Alieve { @@ -30,12 +28,12 @@ protected: TGTextEntry* fFile; TGTextButton* fOpenFile; - Reve::RGValuator* fEvent; + TEveGValuator* fEvent; TGCheckButton* fDoubleSR; // TPCData loading settings - Reve::RGValuator* fDataLoadThreshold; - Reve::RGValuator* fDataLoadPedestal; + TEveGValuator* fDataLoadThreshold; + TEveGValuator* fDataLoadPedestal; TGCheckButton* fDataAutoPedestal; TGTextButton* fUpdateSectors; diff --git a/EVE/Alieve/TPCSector2D.cxx b/EVE/Alieve/TPCSector2D.cxx index 8d77888929b..3ffbf928693 100644 --- a/EVE/Alieve/TPCSector2D.cxx +++ b/EVE/Alieve/TPCSector2D.cxx @@ -6,7 +6,7 @@ #include #include -#include +#include #include @@ -18,8 +18,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; using namespace std; @@ -62,8 +60,8 @@ void TPCSector2D::MakeSector3D() s->SetDataSource(fTPCData); s->SetSectorID(fSectorID); s->SetAutoTrans(fAutoTrans); - gReve->AddRenderElement(s, this); - gReve->Redraw3D(); + gEve->AddElement(s, this); + gEve->Redraw3D(); } /**************************************************************************/ @@ -107,8 +105,8 @@ void TPCSector2D::PadSelected(Int_t row, Int_t pad) if (sectorData == 0) return; Int_t mint = fMinTime; Int_t maxt = fMaxTime; - TH1S* h = new TH1S(Form("Seg%d_Row%d_Pad%d", sseg, srow, pad), - Form("Segment %d, Row %d, Pad %d", sseg, srow, pad), + TH1S* h = new TH1S(Form("Seg%d_Row%d_TEvePad%d", sseg, srow, pad), + Form("Segment %d, Row %d, TEvePad %d", sseg, srow, pad), maxt - mint +1 , mint, maxt); h->SetXTitle("Time"); h->SetYTitle("ADC"); @@ -131,12 +129,12 @@ void TPCSector2D::PadSelected(Int_t row, Int_t pad) maxt - mint +1 , mint, maxt, npad, 0, npad - 1); h->SetXTitle("Time"); - h->SetYTitle("Pad"); + h->SetYTitle("TEvePad"); h->SetZTitle("ADC"); TPCSectorData::RowIterator i = sectorData->MakeRowIterator(row); while (i.NextPad()) while (i.Next()) - h->Fill(i.Time(), i.Pad(), i.Signal()); + h->Fill(i.Time(), i.TEvePad(), i.Signal()); h->Draw(); gPad->Modified(); gPad->Update(); diff --git a/EVE/Alieve/TPCSector2DEditor.cxx b/EVE/Alieve/TPCSector2DEditor.cxx index 2848d0777c8..f044e9e64da 100644 --- a/EVE/Alieve/TPCSector2DEditor.cxx +++ b/EVE/Alieve/TPCSector2DEditor.cxx @@ -6,8 +6,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ diff --git a/EVE/Alieve/TPCSector2DGL.cxx b/EVE/Alieve/TPCSector2DGL.cxx index 288fab11bc1..9e12a65c1a4 100644 --- a/EVE/Alieve/TPCSector2DGL.cxx +++ b/EVE/Alieve/TPCSector2DGL.cxx @@ -7,8 +7,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; using namespace std; @@ -364,7 +362,7 @@ void TPCSector2DGL::TraceStepsDown(const TPCSectorData::SegmentInfo& s) void TPCSector2DGL::DisplayFrame() const { UChar_t col[4]; - ColorFromIdx(fSector->fFrameColor, col); + TEveUtil::ColorFromIdx(fSector->fFrameColor, col); glColor4ubv(col); if(fSector->fRnrInn) { diff --git a/EVE/Alieve/TPCSector3D.cxx b/EVE/Alieve/TPCSector3D.cxx index 458295a48e3..4401e52429c 100644 --- a/EVE/Alieve/TPCSector3D.cxx +++ b/EVE/Alieve/TPCSector3D.cxx @@ -10,8 +10,6 @@ #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -107,7 +105,7 @@ void TPCSector3D::LoadPadrow(TPCSectorData::RowIterator& iter, while (iter.NextPad()) { - pad = iter.Pad(); + pad = iter.TEvePad(); while (iter.Next()) { time = iter.Time(); @@ -133,11 +131,11 @@ void TPCSector3D::LoadPadrow(TPCSectorData::RowIterator& iter, void TPCSector3D::UpdateBoxes() { - // Populate parent class Reve::BoxSet with digit information. + // Populate parent class TEveBoxSet with digit information. // printf("TPCSector3D update boxes\n"); - fBoxSet.Reset(BoxSet::BT_AABox, kTRUE, 16384); + fBoxSet.Reset(TEveBoxSet::kBT_AABox, kTRUE, 16384); fPointSetArray.RemoveElements(); TPCSectorData* data = GetSectorData(); diff --git a/EVE/Alieve/TPCSector3D.h b/EVE/Alieve/TPCSector3D.h index 5cabd993eda..d6532062c51 100644 --- a/EVE/Alieve/TPCSector3D.h +++ b/EVE/Alieve/TPCSector3D.h @@ -6,8 +6,8 @@ #include #include -#include -#include +#include +#include namespace Alieve { @@ -23,8 +23,8 @@ protected: void UpdateBoxes(); void SetupPointSetArray(); - Reve::BoxSet fBoxSet; - Reve::PointSetArray fPointSetArray; + TEveBoxSet fBoxSet; + TEvePointSetArray fPointSetArray; Float_t fPointFrac; Float_t fPointSize; Bool_t fPointSetOn; diff --git a/EVE/Alieve/TPCSector3DEditor.cxx b/EVE/Alieve/TPCSector3DEditor.cxx index 580aea7723b..2f4979a18e7 100644 --- a/EVE/Alieve/TPCSector3DEditor.cxx +++ b/EVE/Alieve/TPCSector3DEditor.cxx @@ -3,7 +3,7 @@ #include "TPCSector3DEditor.h" #include -#include +#include #include #include @@ -14,8 +14,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -40,7 +38,7 @@ TPCSector3DEditor::TPCSector3DEditor(const TGWindow *p, fRnrFrame->Connect ("Toggled(Bool_t)","Alieve::TPCSector3DEditor", this, "DoRnrFrame()"); - fDriftVel = new RGValuator(this, "Vdrift fac", 110, 0); + fDriftVel = new TEveGValuator(this, "Vdrift fac", 110, 0); fDriftVel->SetLabelWidth(labelW); fDriftVel->SetShowSlider(kFALSE); fDriftVel->SetNELength(6); @@ -51,7 +49,7 @@ TPCSector3DEditor::TPCSector3DEditor(const TGWindow *p, "Alieve::TPCSector3DEditor", this, "DoDriftVel()"); AddFrame(fDriftVel, new TGLayoutHints(kLHintsTop, 1, 1, 2, 1)); - fPointFrac = new RGValuator(this,"Point frac", 200, 0); + fPointFrac = new TEveGValuator(this,"Point frac", 200, 0); fPointFrac->SetLabelWidth(labelW); fPointFrac->SetNELength(4); fPointFrac->Build(); @@ -62,7 +60,7 @@ TPCSector3DEditor::TPCSector3DEditor(const TGWindow *p, "Alieve::TPCSector3DEditor", this, "DoPointFrac()"); AddFrame(fPointFrac, new TGLayoutHints(kLHintsTop, 1, 1, 2, 1)); - fPointSize = new RGValuator(this,"Point size", 200, 0); + fPointSize = new TEveGValuator(this,"Point size", 200, 0); fPointSize->SetLabelWidth(labelW); fPointSize->SetShowSlider(kFALSE); fPointSize->SetNELength(4); diff --git a/EVE/Alieve/TPCSector3DEditor.h b/EVE/Alieve/TPCSector3DEditor.h index 6fda513f61c..71bc9f5f325 100644 --- a/EVE/Alieve/TPCSector3DEditor.h +++ b/EVE/Alieve/TPCSector3DEditor.h @@ -9,10 +9,8 @@ class TGCheckButton; class TGNumberEntry; class TGColorSelect; -namespace Reve { -class RGValuator; -class RGDoubleValuator; -} +class TEveGValuator; +class TEveGDoubleValuator; namespace Alieve { @@ -27,10 +25,10 @@ protected: TPCSector3D* fM; // fModel dynamic-casted to TPCSector3DEditor TGCheckButton* fRnrFrame; - Reve::RGValuator* fDriftVel; + TEveGValuator* fDriftVel; - Reve::RGValuator* fPointFrac; - Reve::RGValuator* fPointSize; + TEveGValuator* fPointFrac; + TEveGValuator* fPointSize; public: TPCSector3DEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, diff --git a/EVE/Alieve/TPCSector3DGL.cxx b/EVE/Alieve/TPCSector3DGL.cxx index 9c1646963a7..bd010ed65cd 100644 --- a/EVE/Alieve/TPCSector3DGL.cxx +++ b/EVE/Alieve/TPCSector3DGL.cxx @@ -3,13 +3,11 @@ #include "TPCSector3DGL.h" #include -#include +#include #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -53,7 +51,7 @@ Bool_t TPCSector3DGL::SetModel(TObject* obj, const Option_t* /*opt*/) if(SetModelCheckClass(obj, Alieve::TPCSector3D::Class())) { fSector = (TPCSector3D*) fExternalObj; if(fBoxRnr == 0) { - fBoxRnr = new BoxSetGL; + fBoxRnr = new TEveBoxSetGL; fBoxRnr->SetModel(&fSector->fBoxSet); } return kTRUE; @@ -100,13 +98,13 @@ void TPCSector3DGL::DirectDraw(TGLRnrCtx & rnrCtx) const glPushClientAttrib(GL_CLIENT_VERTEX_ARRAY_BIT); glEnableClientState(GL_VERTEX_ARRAY); - const Reve::PointSetArray& psa = fSector->fPointSetArray; + const TEvePointSetArray& psa = fSector->fPointSetArray; for(Int_t b=0; bSize() > 0) { - ColorFromIdx(ps->GetMarkerColor(), col); + TEveUtil::ColorFromIdx(ps->GetMarkerColor(), col); glColor4ubv(col); if (rnrCtx.SecSelection()) glLoadName(b + 1); @@ -120,7 +118,7 @@ void TPCSector3DGL::DirectDraw(TGLRnrCtx & rnrCtx) const if(fSector->fRnrFrame && ! rnrCtx.SecSelection()) { - ColorFromIdx(fSector->fFrameColor, col); + TEveUtil::ColorFromIdx(fSector->fFrameColor, col); glColor4ubv(col); if(fSector->fRnrInn) @@ -179,11 +177,11 @@ void TPCSector3DGL::ProcessSelection(TGLRnrCtx & /*rnrCtx*/, TGLSelectRecord & r return; } - const Reve::PointSetArray& psa = fSector->fPointSetArray; + const TEvePointSetArray& psa = fSector->fPointSetArray; if (rec.GetItem(1) > 0 && rec.GetItem(1) <= (UInt_t) psa.GetNBins()) { - // Reve::PointSet& ps = * psa.GetBin(rec.GetItem(1) - 1); + // TEvePointSet& ps = * psa.GetBin(rec.GetItem(1) - 1); printf("TPC3D Point selected, bin=%u, idx=%u\n", rec.GetItem(1) - 1, rec.GetItem(2)); return; } diff --git a/EVE/Alieve/TPCSector3DGL.h b/EVE/Alieve/TPCSector3DGL.h index 404c13eafa6..5042d8428c4 100644 --- a/EVE/Alieve/TPCSector3DGL.h +++ b/EVE/Alieve/TPCSector3DGL.h @@ -7,9 +7,7 @@ #include -namespace Reve { -class BoxSetGL; -} +class TEveBoxSetGL; namespace Alieve { @@ -22,7 +20,7 @@ class TPCSector3DGL : public TGLObject protected: TPCSector3D* fSector; // fModel dynamic-casted to TPCSector3DGL - Reve::BoxSetGL* fBoxRnr; + TEveBoxSetGL* fBoxRnr; mutable UInt_t fRTS; diff --git a/EVE/Alieve/TPCSectorData.cxx b/EVE/Alieve/TPCSectorData.cxx index 98c6bca7425..45ccbe22983 100644 --- a/EVE/Alieve/TPCSectorData.cxx +++ b/EVE/Alieve/TPCSectorData.cxx @@ -19,8 +19,6 @@ // For accessing data, see for example TPCSector2DGL::CreateTexture() // and LoadPadrow(). // - -using namespace Reve; using namespace Alieve; ClassImp(TPCSectorData) @@ -435,7 +433,7 @@ void TPCSectorData::RowIterator::ResetRow(const PadData* first, Short_t npads) void TPCSectorData::RowIterator::Test() { while(NextPad()) { - printf("Pad %d\n", fPad); + printf("TEvePad %d\n", fPad); PadIterator::Test(); } } diff --git a/EVE/Alieve/TPCSectorData.h b/EVE/Alieve/TPCSectorData.h index 9d8465c57c5..e3f93939845 100644 --- a/EVE/Alieve/TPCSectorData.h +++ b/EVE/Alieve/TPCSectorData.h @@ -3,7 +3,7 @@ #ifndef ALIEVE_TPCSectorData_H #define ALIEVE_TPCSectorData_H -#include +#include #include @@ -106,7 +106,7 @@ public: void ResetRow(); void ResetRow(const PadData* first, Short_t npads); - Short_t Pad() const { return fPad; } + Short_t TEvePad() const { return fPad; } void Test(); }; diff --git a/EVE/Alieve/TPCSectorViz.cxx b/EVE/Alieve/TPCSectorViz.cxx index 0d37faeb9b1..70b6d12a1ec 100644 --- a/EVE/Alieve/TPCSectorViz.cxx +++ b/EVE/Alieve/TPCSectorViz.cxx @@ -8,8 +8,6 @@ #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -23,7 +21,7 @@ ClassImp(TPCSectorViz) /**************************************************************************/ TPCSectorViz::TPCSectorViz(const Text_t* n, const Text_t* t) : - Reve::RenderElement(fFrameColor), + TEveElement(fFrameColor), TNamed(n, t), fTPCData (0), @@ -144,7 +142,7 @@ void TPCSectorViz::SetupColor(Int_t val, UChar_t* pixel) const Int_t nCol = gStyle->GetNumberOfColors(); Int_t cBin = (Int_t) Nint(nCol*(val - fThreshold)/div); - ColorFromIdx(gStyle->GetColorPalette(Min(nCol - 1, cBin)), pixel); + TEveUtil::ColorFromIdx(gStyle->GetColorPalette(Min(nCol - 1, cBin)), pixel); } void TPCSectorViz::ClearColorArray() diff --git a/EVE/Alieve/TPCSectorViz.h b/EVE/Alieve/TPCSectorViz.h index cd21a882095..35a28538073 100644 --- a/EVE/Alieve/TPCSectorViz.h +++ b/EVE/Alieve/TPCSectorViz.h @@ -3,8 +3,8 @@ #ifndef ALIEVE_TPCSectorViz_H #define ALIEVE_TPCSectorViz_H -#include -#include +#include +#include #include #include @@ -19,7 +19,7 @@ class TPCSectorVizEditor; class TPCSector2D; class TPCSector2DEditor; class TPCSector2DGL; class TPCSector3D; class TPCSector3DEditor; class TPCSector3DGL; -class TPCSectorViz : public Reve::RenderElement, +class TPCSectorViz : public TEveElement, public TNamed, public TAtt3D, public TAttBBox @@ -50,7 +50,7 @@ protected: Color_t fFrameColor; Bool_t fRnrFrame; - Reve::ZTrans fHMTrans; + TEveTrans fHMTrans; Bool_t fAutoTrans; UInt_t fRTS; //! Rendering TimeStamp @@ -93,7 +93,7 @@ public: virtual void SetRnrFrame(Bool_t rf) { fRnrFrame = rf; IncRTS(); } void SetAutoTrans(Bool_t t); - Reve::ZTrans& RefHMTrans() { return fHMTrans; } + TEveTrans& RefHMTrans() { return fHMTrans; } void SetUseTrans(Bool_t t) { fHMTrans.SetUseTrans(t); } ClassDef(TPCSectorViz, 1); // Base-class for TPC raw-data visualization diff --git a/EVE/Alieve/TPCSectorVizEditor.cxx b/EVE/Alieve/TPCSectorVizEditor.cxx index 4a14a5b4b99..912176640b6 100644 --- a/EVE/Alieve/TPCSectorVizEditor.cxx +++ b/EVE/Alieve/TPCSectorVizEditor.cxx @@ -3,8 +3,8 @@ #include "TPCSectorVizEditor.h" #include -#include -#include +#include +#include #include #include @@ -15,8 +15,6 @@ #include #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ @@ -42,14 +40,14 @@ TPCSectorVizEditor::TPCSectorVizEditor(const TGWindow *p, MakeTitle("Transformation matrix"); - fHMTrans = new ZTransSubEditor(this); + fHMTrans = new TEveTransSubEditor(this); fHMTrans->Connect("UseTrans()", "Alieve::TPCSectorVizEditor", this, "Update()"); fHMTrans->Connect("TransChanged()", "Alieve::TPCSectorVizEditor", this, "Update()"); AddFrame(fHMTrans, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 2, 0, 0, 0)); MakeTitle("TPCSectorViz"); - fSectorID = new RGValuator(this, "SectorID", 110, 0); + fSectorID = new TEveGValuator(this, "SectorID", 110, 0); fSectorID->SetLabelWidth(labelW); fSectorID->SetShowSlider(kFALSE); fSectorID->SetNELength(4); @@ -83,7 +81,7 @@ TPCSectorVizEditor::TPCSectorVizEditor(const TGWindow *p, AddFrame(f, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); } - fThreshold = new RGValuator(this, "Threshold", 200, 0); + fThreshold = new TEveGValuator(this, "Threshold", 200, 0); fThreshold->SetNELength(4); fThreshold->SetLabelWidth(labelW); fThreshold->Build(); @@ -93,7 +91,7 @@ TPCSectorVizEditor::TPCSectorVizEditor(const TGWindow *p, "Alieve::TPCSectorVizEditor", this, "DoThreshold()"); AddFrame(fThreshold, new TGLayoutHints(kLHintsTop, 1, 1, 2, 1)); - fMaxVal = new RGValuator(this,"MaxVal", 200, 0); + fMaxVal = new TEveGValuator(this,"MaxVal", 200, 0); fMaxVal->SetNELength(4); fMaxVal->SetLabelWidth(labelW); fMaxVal->Build(); @@ -103,7 +101,7 @@ TPCSectorVizEditor::TPCSectorVizEditor(const TGWindow *p, "Alieve::TPCSectorVizEditor", this, "DoMaxVal()"); AddFrame(fMaxVal, new TGLayoutHints(kLHintsTop, 1, 1, 2, 1)); - fTime = new RGDoubleValuator(this,"Time", 200, 0); + fTime = new TEveGDoubleValuator(this,"Time", 200, 0); fTime->SetNELength(4); fTime->SetLabelWidth(labelW); fTime->Build(); @@ -123,7 +121,7 @@ void TPCSectorVizEditor::SetModel(TObject* obj) { fM = dynamic_cast(obj); - fHMTrans->SetDataFromTrans(&fM->fHMTrans); + fHMTrans->SetModel(&fM->fHMTrans); fSectorID->SetValue(fM->fSectorID); fAutoTrans->SetState(fM->fAutoTrans ? kButtonDown : kButtonUp); diff --git a/EVE/Alieve/TPCSectorVizEditor.h b/EVE/Alieve/TPCSectorVizEditor.h index a2ca57cd9cb..7a604fae507 100644 --- a/EVE/Alieve/TPCSectorVizEditor.h +++ b/EVE/Alieve/TPCSectorVizEditor.h @@ -11,11 +11,9 @@ class TGColorSelect; class TGDoubleHSlider; class TGHSlider; -namespace Reve { -class RGValuator; -class RGDoubleValuator; -class ZTransSubEditor; -} +class TEveGValuator; +class TEveGDoubleValuator; +class TEveTransSubEditor; namespace Alieve { @@ -29,19 +27,19 @@ class TPCSectorVizEditor : public TGedFrame protected: TPCSectorViz* fM; // fModel dynamic-casted to TPCSectorVizEditor - Reve::ZTransSubEditor* fHMTrans; + TEveTransSubEditor* fHMTrans; - Reve::RGValuator* fSectorID; + TEveGValuator* fSectorID; TGCheckButton* fAutoTrans; TGCheckButton* fRnrInn; TGCheckButton* fRnrOut1; TGCheckButton* fRnrOut2; - Reve::RGValuator* fThreshold; - Reve::RGValuator* fMaxVal; + TEveGValuator* fThreshold; + TEveGValuator* fMaxVal; - Reve::RGDoubleValuator* fTime; + TEveGDoubleValuator* fTime; public: TPCSectorVizEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, diff --git a/EVE/Alieve/TRDData.cxx b/EVE/Alieve/TRDData.cxx index aa61c110fed..95989891947 100644 --- a/EVE/Alieve/TRDData.cxx +++ b/EVE/Alieve/TRDData.cxx @@ -9,11 +9,9 @@ #include "AliTRDgeometry.h" #include "AliTRDdigitsManager.h" -using namespace Reve; using namespace Alieve; using namespace std; - ClassImp(TRDHits) ClassImp(TRDDigits) ClassImp(TRDClusters) @@ -23,7 +21,7 @@ ClassImp(TRDClusters) /////////////////////////////////////////////////////////// //________________________________________________________ -TRDDigits::TRDDigits(TRDChamber *p): OldQuadSet("digits", ""), RenderElement(), fParent(p) +TRDDigits::TRDDigits(TRDChamber *p): TEveQuadSet("digits", ""), fParent(p) {} //________________________________________________________ @@ -41,102 +39,102 @@ void TRDDigits::SetData(AliTRDdigitsManager *digits) } //________________________________________________________ -void TRDDigits::ComputeRepresentation() +void TRDDigits::ComputeRepresentation() { -// Calculate digits representation according to user settings. The -// user can set the following parameters: -// - digits scale (log/lin) -// - digits threshold -// - digits apparence (quads/boxes) - - fQuads.clear(); - // MT fBoxes.fBoxes.clear(); + // Calculate digits representation according to user settings. The + // user can set the following parameters: + // - digits scale (log/lin) + // - digits threshold + // - digits apparence (quads/boxes) + + TEveQuadSet::Reset(TEveQuadSet::kQT_FreeQuad, kTRUE, 64); + // MT fBoxes.fBoxes.clear(); - Double_t colSize, rowSize, scale; - Double_t x, y, z; + Double_t colSize, rowSize, scale; + Double_t x, y, z; - Int_t charge; - Float_t t0; - Float_t timeBinSize; + Int_t charge; + Float_t t0; + Float_t timeBinSize; - AliTRDcalibDB* calibration = AliTRDcalibDB::Instance(); + AliTRDcalibDB* calibration = AliTRDcalibDB::Instance(); Double_t cloc[4][3], cglo[3]; - Int_t color, dimension; - fData.Expand(); - for (Int_t row = 0; row < fParent->rowMax; row++) { - rowSize = .5 * fParent->fPadPlane->GetRowSize(row); - z = fParent->fPadPlane->GetRowPos(row) - rowSize; + Int_t color, dimension; + fData.Expand(); + for (Int_t row = 0; row < fParent->rowMax; row++) { + rowSize = .5 * fParent->fPadPlane->GetRowSize(row); + z = fParent->fPadPlane->GetRowPos(row) - rowSize; - for (Int_t col = 0; col < fParent->colMax; col++) { - colSize = .5 * fParent->fPadPlane->GetColSize(col); - y = fParent->fPadPlane->GetColPos(col) - colSize; - t0 = calibration->GetT0(fParent->fDet, col, row); - timeBinSize = calibration->GetVdrift(fParent->fDet, col, row)/fParent->samplingFrequency; + for (Int_t col = 0; col < fParent->colMax; col++) { + colSize = .5 * fParent->fPadPlane->GetColSize(col); + y = fParent->fPadPlane->GetColPos(col) - colSize; + t0 = calibration->GetT0(fParent->fDet, col, row); + timeBinSize = calibration->GetVdrift(fParent->fDet, col, row)/fParent->samplingFrequency; - for (Int_t time = 0; time < fParent->timeMax; time++) { - charge = fData.GetDataUnchecked(row, col, time); - if (charge < fParent->GetDigitsThreshold()) continue; + for (Int_t time = 0; time < fParent->timeMax; time++) { + charge = fData.GetDataUnchecked(row, col, time); + if (charge < fParent->GetDigitsThreshold()) continue; - x = fParent->fX0 - (time+0.5-t0)*timeBinSize; - scale = fParent->GetDigitsLog() ? TMath::Log(float(charge))/TMath::Log(1024.) : charge/1024.; - color = 50+int(scale*50.); + x = fParent->fX0 - (time+0.5-t0)*timeBinSize; + scale = fParent->GetDigitsLog() ? TMath::Log(float(charge))/TMath::Log(1024.) : charge/1024.; + color = 50+int(scale*50.); - cloc[0][2] = z - rowSize * scale; - cloc[0][1] = y - colSize * scale; - cloc[0][0] = x; + cloc[0][2] = z - rowSize * scale; + cloc[0][1] = y - colSize * scale; + cloc[0][0] = x; - cloc[1][2] = z - rowSize * scale; - cloc[1][1] = y + colSize * scale; - cloc[1][0] = x; + cloc[1][2] = z - rowSize * scale; + cloc[1][1] = y + colSize * scale; + cloc[1][0] = x; - cloc[2][2] = z + rowSize * scale; - cloc[2][1] = y + colSize * scale; - cloc[2][0] = x; + cloc[2][2] = z + rowSize * scale; + cloc[2][1] = y + colSize * scale; + cloc[2][0] = x; - cloc[3][2] = z + rowSize * scale; - cloc[3][1] = y - colSize * scale; - cloc[3][0] = x; + cloc[3][2] = z + rowSize * scale; + cloc[3][1] = y - colSize * scale; + cloc[3][0] = x; - Float_t* p = 0; - if( fParent->GetDigitsBox()){ - // MT fBoxes.fBoxes.push_back(Reve::Box()); - // MT fBoxes.fBoxes.back().color[0] = (UChar_t)color; - // MT fBoxes.fBoxes.back().color[1] = (UChar_t)color; - // MT fBoxes.fBoxes.back().color[2] = (UChar_t)color; - // MT fBoxes.fBoxes.back().color[3] = (UChar_t)color; - // MT p = fBoxes.fBoxes.back().vertices; - dimension = 2; - } else { - fQuads.push_back(Reve::Quad()); - fQuads.back().ColorFromIdx(color); - p = fQuads.back().vertices; - dimension = 1; - } - - for(int id=0; idfGeo->RotateBack(fParent->fDet,cloc[ic],cglo); - p[0] = cglo[0]; p[1] = cglo[1]; p[2] = cglo[2]; - p+=3; - } - } // end time loop - } // end col loop - } // end row loop - fData.Compress(1); + Float_t* p = 0; + if( fParent->GetDigitsBox()){ + // MT fBoxes.fBoxes.push_back(Box()); + // MT fBoxes.fBoxes.back().color[0] = (UChar_t)color; + // MT fBoxes.fBoxes.back().color[1] = (UChar_t)color; + // MT fBoxes.fBoxes.back().color[2] = (UChar_t)color; + // MT fBoxes.fBoxes.back().color[3] = (UChar_t)color; + // MT p = fBoxes.fBoxes.back().vertices; + dimension = 2; + } else { + AddQuad((Float_t*)0); + QuadColor(color); + p = ((QFreeQuad_t*) fLastDigit)->fVertices; + dimension = 1; + } + + for(int id=0; idfGeo->RotateBack(fParent->fDet,cloc[ic],cglo); + p[0] = cglo[0]; p[1] = cglo[1]; p[2] = cglo[2]; + p+=3; + } + } // end time loop + } // end col loop + } // end row loop + fData.Compress(1); } //________________________________________________________ void TRDDigits::Paint(Option_t *option) { if(fParent->GetDigitsBox()) fBoxes.Paint(option); - else OldQuadSet::Paint(option); + else TEveQuadSet::Paint(option); } //________________________________________________________ void TRDDigits::Reset() { - fQuads.clear(); + TEveQuadSet::Reset(TEveQuadSet::kQT_FreeQuad, kTRUE, 64); // MT fBoxes.fBoxes.clear(); fData.Reset(); } @@ -146,7 +144,7 @@ void TRDDigits::Reset() /////////////////////////////////////////////////////////// //________________________________________________________ -TRDHits::TRDHits(TRDChamber *p):PointSet("hits", 20), fParent(p) +TRDHits::TRDHits(TRDChamber *p):TEvePointSet("hits", 20), fParent(p) {} //________________________________________________________ diff --git a/EVE/Alieve/TRDData.h b/EVE/Alieve/TRDData.h index a5af9066ac3..0a9649d1439 100644 --- a/EVE/Alieve/TRDData.h +++ b/EVE/Alieve/TRDData.h @@ -12,15 +12,15 @@ #define ALIEVE_TRDData_H #ifndef REVE_QuadSet_H -#include +#include #endif #ifndef REVE_BoxSet_H -#include +#include #endif #ifndef REVE_PointSet_H -#include +#include #endif #ifndef ROOT_TGedFrame @@ -32,7 +32,7 @@ class AliTRDdigitsManager; namespace Alieve { class TRDChamber; - class TRDHits : public Reve::PointSet + class TRDHits : public TEvePointSet { public: TRDHits(TRDChamber *p); @@ -60,7 +60,7 @@ namespace Alieve { }; - class TRDDigits : public Reve::OldQuadSet, public Reve::RenderElement + class TRDDigits : public TEveQuadSet { friend class TRDDigitsEditor; public: @@ -75,7 +75,7 @@ namespace Alieve { TRDChamber *fParent; private: - Reve::BoxSet fBoxes; + TEveBoxSet fBoxes; AliTRDdataArrayI fData; ClassDef(TRDDigits,1) // Digits visualisation for TRD diff --git a/EVE/Alieve/TRDLoader.cxx b/EVE/Alieve/TRDLoader.cxx index fff68244ebc..7969ee88442 100644 --- a/EVE/Alieve/TRDLoader.cxx +++ b/EVE/Alieve/TRDLoader.cxx @@ -1,8 +1,8 @@ #include "TRDLoader.h" #include "TRDModuleImp.h" -#include -#include +#include +#include #include "TSystem.h" #include "TFile.h" @@ -31,8 +31,6 @@ #include - -using namespace Reve; using namespace Alieve; using namespace std; class AliTRDdataArrayI; @@ -46,7 +44,7 @@ ClassImp(Alieve::TRDLoaderEditor) //________________________________________________________ -TRDLoader::TRDLoader(const Text_t* n, const Text_t* t) : Reve::RenderElementList(n, t), fSM(-1), fStack(-1), fLy(-1), fEvent(0) +TRDLoader::TRDLoader(const Text_t* n, const Text_t* t) : TEveElementList(n, t), fSM(-1), fStack(-1), fLy(-1), fEvent(0) { kLoadHits = kFALSE; kLoadDigits = kFALSE; @@ -102,36 +100,36 @@ void TRDLoader::AddChambers(int sm, int stk, int ly) TRDChamber *CHMB = 0x0; int det; for(int ism=ism_start; ism(ism)); + ichmb = find_if(fChildren.begin(), fChildren.end(), ID(ism)); if(ichmb != fChildren.end()){ SM = (TRDNode*)(*ichmb); SM->SetRnrSelf(kTRUE); }else{ - gReve->AddRenderElement(SM = new TRDNode("SM", ism), this); - SM->FindListTreeItem(gReve->GetListTree())->SetTipText(Form("Supermodule %2d", ism)); + gEve->AddElement(SM = new TRDNode("SM", ism), this); + SM->FindListTreeItem(gEve->GetListTree())->SetTipText(Form("Supermodule %2d", ism)); } for(int istk=istk_start; istkbegin(), SM->end(), ID(istk)); + ichmb = find_if(SM->begin(), SM->end(), ID(istk)); if(ichmb != SM->end()){ STK = (TRDNode*)(*ichmb); STK->SetRnrSelf(kTRUE); }else{ - gReve->AddRenderElement(STK = new TRDNode("Stack", istk), SM); - STK->FindListTreeItem(gReve->GetListTree())->SetTipText(Form("SM %2d Stack %1d", ism, istk)); + gEve->AddElement(STK = new TRDNode("Stack", istk), SM); + STK->FindListTreeItem(gEve->GetListTree())->SetTipText(Form("SM %2d Stack %1d", ism, istk)); } for(int ily=ily_start; ilyGetDetector(ily, istk, ism); - ichmb = find_if(STK->begin(), STK->end(), ID(det)); + ichmb = find_if(STK->begin(), STK->end(), ID(det)); if(ichmb != STK->end()) (*ichmb)->SetRnrSelf(kTRUE); else{ - gReve->AddRenderElement(CHMB = new TRDChamber(det), STK); + gEve->AddElement(CHMB = new TRDChamber(det), STK); CHMB->SetGeometry(fGeo); - CHMB->FindListTreeItem(gReve->GetListTree())->SetTipText(Form("SM %2d Stack %1d Layer %1d", ism, istk, ily)); + CHMB->FindListTreeItem(gEve->GetListTree())->SetTipText(Form("SM %2d Stack %1d Layer %1d", ism, istk, ily)); } } } } - gReve->Redraw3D(); + gEve->Redraw3D(); } //________________________________________________________ @@ -139,11 +137,11 @@ TRDChamber* TRDLoader::GetChamber(int d) { List_i ism, istack, ichmb; - ism = find_if(fChildren.begin(), fChildren.end(), ID(fGeo->GetSector(d))); + ism = find_if(fChildren.begin(), fChildren.end(), ID(fGeo->GetSector(d))); if(ism == fChildren.end()) return 0x0; - istack = find_if(((TRDNode*)(*ism))->begin(), ((TRDNode*)(*ism))->end(), ID(fGeo->GetChamber(d))); + istack = find_if(((TRDNode*)(*ism))->begin(), ((TRDNode*)(*ism))->end(), ID(fGeo->GetChamber(d))); if(istack == ((TRDNode*)(*ism))->end()) return 0x0; - ichmb = find_if(((TRDNode*)(*istack))->begin(), ((TRDNode*)(*istack))->end(), ID(d)); + ichmb = find_if(((TRDNode*)(*istack))->begin(), ((TRDNode*)(*istack))->end(), ID(d)); if(ichmb == ((TRDNode*)(*istack))->end()) return 0x0; return dynamic_cast(*ichmb); } @@ -184,7 +182,7 @@ Bool_t TRDLoader::GoToEvent(int ev) f->Close(); delete f; - gReve->Redraw3D(); + gEve->Redraw3D(); return kTRUE; } @@ -364,7 +362,7 @@ TRDLoaderEditor::TRDLoaderEditor(const TGWindow* p, Int_t width, Int_t height, U AddFrame(f); - fEvent = new RGValuator(this, "Event:", 110, 0); + fEvent = new TEveGValuator(this, "Event:", 110, 0); fEvent->SetShowSlider(kFALSE); fEvent->SetLabelWidth(labelW); fEvent->SetNELength(6); @@ -380,7 +378,7 @@ TRDLoaderEditor::TRDLoaderEditor(const TGWindow* p, Int_t width, Int_t height, U TGGroupFrame *fGroupFrame1974 = new TGGroupFrame(this,"Chamber(s) selector"); TGVerticalFrame *fVerticalFrame1974 = new TGVerticalFrame(fGroupFrame1974, 150, 50,kVerticalFrame); - fSMNumber = new RGValuator(fVerticalFrame1974, "SM:", 0, 0); + fSMNumber = new TEveGValuator(fVerticalFrame1974, "SM:", 0, 0); fSMNumber->SetShowSlider(kFALSE); fSMNumber->SetLabelWidth(labelW); fSMNumber->SetNELength(6); @@ -389,7 +387,7 @@ TRDLoaderEditor::TRDLoaderEditor(const TGWindow* p, Int_t width, Int_t height, U fSMNumber->SetToolTip("Supermodule id [-1 for all]"); fVerticalFrame1974->AddFrame(fSMNumber, new TGLayoutHints(kLHintsLeft | kLHintsTop | kLHintsCenterX | kLHintsExpandY,2,2,2,2)); - fStackNumber = new RGValuator(fVerticalFrame1974, "Stack:", 0, 0); + fStackNumber = new TEveGValuator(fVerticalFrame1974, "Stack:", 0, 0); fStackNumber->SetShowSlider(kFALSE); fStackNumber->SetLabelWidth(labelW); fStackNumber->SetNELength(6); @@ -398,7 +396,7 @@ TRDLoaderEditor::TRDLoaderEditor(const TGWindow* p, Int_t width, Int_t height, U fStackNumber->SetToolTip("Stack id [-1 for all in this SM]"); fVerticalFrame1974->AddFrame(fStackNumber, new TGLayoutHints(kLHintsLeft | kLHintsTop | kLHintsCenterX | kLHintsExpandY,2,2,2,2)); - fPlaneNumber = new RGValuator(fVerticalFrame1974, "Plane:", 0, 0); + fPlaneNumber = new TEveGValuator(fVerticalFrame1974, "Plane:", 0, 0); fPlaneNumber->SetShowSlider(kFALSE); fPlaneNumber->SetLabelWidth(labelW); fPlaneNumber->SetNELength(6); @@ -476,7 +474,7 @@ void TRDLoaderEditor::FileOpen() fi.fFilename = StrDup(gSystem->BaseName(fM->fFilename.Data())); // fi.fFileTypes = tpcfiletypes; - new TGFileDialog(fClient->GetRoot(), gReve->GetMainWindow(), kFDOpen, &fi); + new TGFileDialog(fClient->GetRoot(), gEve->GetMainWindow(), kFDOpen, &fi); if (!fi.fFilename) return; fFile->SetToolTipText(gSystem->DirName (fi.fFilename)); diff --git a/EVE/Alieve/TRDLoader.h b/EVE/Alieve/TRDLoader.h index e1cb9c3dc33..e3965b42698 100644 --- a/EVE/Alieve/TRDLoader.h +++ b/EVE/Alieve/TRDLoader.h @@ -10,17 +10,9 @@ // by A.Bercuci (A.Bercuci@gsi.de) Fri Oct 27 2006 //////////////////////////////////////////////////////////////////////// -#ifndef REVE_RenderElement_H -#include -#endif - -#ifndef ROOT_TString -#include -#endif - -#ifndef ROOT_TGedFrame +#include #include -#endif +#include class AliTRDv1; class AliTRDgeometry; @@ -29,9 +21,9 @@ class TGNumberEntry; class TGColorSelect; class TGTextEntry; class TTree; -namespace Reve { - class RGValuator; -} + +class TEveGValuator; + namespace Alieve { class TRDChamber; class TRDLoaderManager; @@ -43,7 +35,7 @@ namespace Alieve { kRawRoot = 4, kRawData = 5 }; - class TRDLoader : public Reve::RenderElementList + class TRDLoader : public TEveElementList { friend class TRDLoaderEditor; public: @@ -90,10 +82,10 @@ namespace Alieve { virtual void SetModel(TObject* obj); protected: - TRDLoader *fM; - TGTextEntry *fFile; - Reve::RGValuator *fEvent; - Reve::RGValuator *fSMNumber, *fStackNumber, *fPlaneNumber; + TRDLoader *fM; + TGTextEntry *fFile; + TEveGValuator *fEvent; + TEveGValuator *fSMNumber, *fStackNumber, *fPlaneNumber; ClassDef(TRDLoaderEditor,1) // Editor for TRDLoader }; diff --git a/EVE/Alieve/TRDLoaderImp.cxx b/EVE/Alieve/TRDLoaderImp.cxx index cc93d230e19..1e7e918e828 100644 --- a/EVE/Alieve/TRDLoaderImp.cxx +++ b/EVE/Alieve/TRDLoaderImp.cxx @@ -3,7 +3,7 @@ //#include "AliTRDv1.h" -#include +#include #include "TFile.h" #include "TTree.h" @@ -21,8 +21,6 @@ #include "AliTRDv1.h" #include "AliTRDhit.h" #include "AliTRDdigitsManager.h" - -using namespace Reve; using namespace Alieve; using namespace std; @@ -96,7 +94,7 @@ Bool_t TRDLoaderSim::GoToEvent(int ev) if(!LoadTracklets(t)) return kFALSE; } - gReve->Redraw3D(); + gEve->Redraw3D(); return kTRUE; } @@ -224,7 +222,7 @@ Bool_t TRDLoaderRaw::GoToEvent(int ev) return kFALSE; } - static const Exc_t eH("TRDLoader::GotoEvent "); + static const TEveException eH("TRDLoader::GotoEvent "); if(fRawRootReader == 0x0) throw(eH + "data file not opened."); @@ -238,8 +236,8 @@ Bool_t TRDLoaderRaw::GoToEvent(int ev) do NextEvent(); while(fEventOld != ev && !(checkEnd == kTRUE && fEventOld == 0)); LoadEvent(); - gReve->Redraw3D(); - //gReve->EnableRedraw(); + gEve->Redraw3D(); + //gEve->EnableRedraw(); return kTRUE; } @@ -248,7 +246,7 @@ Bool_t TRDLoaderRaw::LoadEvent() { Info("LoadEvent()", "Loading ..."); - static const Exc_t eH("TRDLoader::LoadEvent "); + static const TEveException eH("TRDLoader::LoadEvent "); if(fRawRootReader == 0x0) throw(eH + "data file not opened."); @@ -268,7 +266,7 @@ Bool_t TRDLoaderRaw::LoadEvent() //________________________________________________________ void TRDLoaderRaw::NextEvent(Bool_t rewindOnEnd) { - static const Exc_t eH("TRDLoader::NextEvent "); + static const TEveException eH("TRDLoader::NextEvent "); if(fRawRootReader == 0x0) throw(eH + "data file not opened."); diff --git a/EVE/Alieve/TRDLoaderManager.cxx b/EVE/Alieve/TRDLoaderManager.cxx index 76a65edbd6b..95bbd0f94a4 100644 --- a/EVE/Alieve/TRDLoaderManager.cxx +++ b/EVE/Alieve/TRDLoaderManager.cxx @@ -2,7 +2,7 @@ #include "TRDLoader.h" #include "TRDLoaderImp.h" -#include +#include #include #include @@ -14,8 +14,6 @@ #include #include "AliLog.h" - -using namespace Reve; using namespace Alieve; using namespace std; @@ -29,7 +27,7 @@ ClassImp(Alieve::TRDLoaderManagerEditor) //________________________________________________________ -TRDLoaderManager::TRDLoaderManager(const Text_t* n, const Text_t* t) : Reve::RenderElementList(n, t) +TRDLoaderManager::TRDLoaderManager(const Text_t* n, const Text_t* t) : TEveElementList(n, t) { } @@ -48,27 +46,27 @@ void TRDLoaderManager::Add(Int_t type, const Text_t *name, const Text_t *title) switch(type){ case 0: //fChildren.push_back(new TRDLoaderSim(name, title)); - gReve->AddRenderElement(trdl = new TRDLoaderSim(name, title), this); - ((TRDLoaderSim*)trdl)->FindListTreeItem(gReve->GetListTree())->SetTipText(title); + gEve->AddElement(trdl = new TRDLoaderSim(name, title), this); + ((TRDLoaderSim*)trdl)->FindListTreeItem(gEve->GetListTree())->SetTipText(title); break; case 1: case 2: case 3: //fChildren.push_back(new TRDLoader(name, title)); - gReve->AddRenderElement(trdl = new TRDLoader(name, title), this); - trdl->FindListTreeItem(gReve->GetListTree())->SetTipText(title); + gEve->AddElement(trdl = new TRDLoader(name, title), this); + trdl->FindListTreeItem(gEve->GetListTree())->SetTipText(title); trdl->SetDataType((Alieve::TRDDataTypes)type); break; case 4: case 5: //fChildren.push_back(new TRDLoaderRaw(name, title)); - gReve->AddRenderElement(trdl = new TRDLoaderRaw(name, title), this); - ((TRDLoaderRaw*)trdl)->FindListTreeItem(gReve->GetListTree())->SetTipText(title); + gEve->AddElement(trdl = new TRDLoaderRaw(name, title), this); + ((TRDLoaderRaw*)trdl)->FindListTreeItem(gEve->GetListTree())->SetTipText(title); trdl->SetDataType((Alieve::TRDDataTypes)type); break; } - gReve->Redraw3D(); + gEve->Redraw3D(); } @@ -89,7 +87,7 @@ void TRDLoaderManager::Remove(Int_t entry) //printf("TRDLoaderManager::Remove(%d)\n", entry); List_i it = fChildren.begin(); for(int i=0; iRemoveRenderElement((*it), this); + gEve->RemoveElement((*it), this); fChildren.erase(it); } diff --git a/EVE/Alieve/TRDLoaderManager.h b/EVE/Alieve/TRDLoaderManager.h index 18b488ac456..81f160823eb 100644 --- a/EVE/Alieve/TRDLoaderManager.h +++ b/EVE/Alieve/TRDLoaderManager.h @@ -10,9 +10,7 @@ // by A.Bercuci (A.Bercuci@gsi.de) Mon Feb 26 2007 //////////////////////////////////////////////////////////////////////// -#ifndef REVE_RenderElement_H -#include -#endif +#include #ifndef ROOT_TNamed #include @@ -25,8 +23,10 @@ class TGComboBox; class TGTextButton; class TClonesArray; + namespace Alieve { - class TRDLoaderManager : public Reve::RenderElementList + + class TRDLoaderManager : public TEveElementList { friend class TRDLoaderManagerEditor; public: diff --git a/EVE/Alieve/TRDModule.cxx b/EVE/Alieve/TRDModule.cxx index 01d73b086f0..94df2c03b6d 100644 --- a/EVE/Alieve/TRDModule.cxx +++ b/EVE/Alieve/TRDModule.cxx @@ -8,13 +8,10 @@ //#include "TColor.h" //#include "TMath.h" -#include "Reve/ReveManager.h" -#include "Reve/Track.h" +#include "TEveManager.h" +#include "TEveTrack.h" - -using namespace Reve; using namespace Alieve; -//using namespace std; ClassImp(TRDModule) ClassImp(TRDModuleEditor) @@ -230,7 +227,7 @@ void TRDModuleEditor::UpdateChamber() if(dynamic_cast(fM)) (dynamic_cast(fM))->UpdateLeaves(); - gReve->Redraw3D(); + gEve->Redraw3D(); } //_________________________________________________________ @@ -240,7 +237,7 @@ void TRDModuleEditor::UpdateClusters(Pixel_t /*col*/) /* if(fM->fRecPoints){ fM->fRecPoints->SetMarkerColor(col ? fHitsColor->GetColor() : col); - gReve->Redraw3D(); + gEve->Redraw3D(); } */ } @@ -252,7 +249,7 @@ void TRDModuleEditor::UpdateHits(Pixel_t /*col*/) /* if(fM->fHits){ fM->fHits->SetMarkerColor(col ? fClustersColor->GetColor() : col); - gReve->Redraw3D(); + gEve->Redraw3D(); } */ } diff --git a/EVE/Alieve/TRDModuleImp.cxx b/EVE/Alieve/TRDModuleImp.cxx index dcee0ae5a91..8bb2da6d963 100644 --- a/EVE/Alieve/TRDModuleImp.cxx +++ b/EVE/Alieve/TRDModuleImp.cxx @@ -4,8 +4,8 @@ #include "TMath.h" #include -#include "Reve/ReveManager.h" -#include "Reve/Track.h" +#include "TEveManager.h" +#include "TEveTrack.h" #include "AliLog.h" #include "AliRun.h" @@ -20,9 +20,6 @@ #include "AliTRDdataArrayI.h" #include "AliTRDmcmTracklet.h" - - -using namespace Reve; using namespace Alieve; using namespace std; @@ -31,7 +28,7 @@ ClassImp(TRDNode) //________________________________________________________ TRDNode::TRDNode(const char *typ, Int_t det) : - Reve::RenderElement(), TRDModule(typ, det) + TEveElement(), TRDModule(typ, det) { } @@ -58,7 +55,7 @@ void TRDNode::Reset() //________________________________________________________ void TRDNode::Collapse() { - TGListTree *list = gReve->GetListTree(); + TGListTree *list = gEve->GetListTree(); TRDNode *node = 0x0; List_i iter = fChildren.begin(); while(iter != fChildren.end()){ @@ -71,7 +68,7 @@ void TRDNode::Collapse() //________________________________________________________ void TRDNode::Expand() { - TGListTree *list = gReve->GetListTree(); + TGListTree *list = gEve->GetListTree(); TRDNode *node = 0x0; List_i iter = fChildren.begin(); while(iter != fChildren.end()){ @@ -96,7 +93,7 @@ void TRDNode::EnableListElements() if((chmb = dynamic_cast(*iter))) chmb->SetRnrSelf(kTRUE); iter++; } - gReve->Redraw3D(); + gEve->Redraw3D(); } //________________________________________________________ @@ -114,7 +111,7 @@ void TRDNode::DisableListElements() if((chmb = dynamic_cast(*iter))) chmb->SetRnrSelf(kFALSE); iter++; } - gReve->Redraw3D(); + gEve->Redraw3D(); } //________________________________________________________ @@ -205,7 +202,7 @@ void TRDNode::UpdateNode() //________________________________________________________ TRDChamber::TRDChamber(Int_t det) : - Reve::RenderElement(), TRDModule("Chmb", det), rowMax(-1), colMax(-1), timeMax(22), fX0(0.), fPla(-1) + TEveElement(), TRDModule("Chmb", det), rowMax(-1), colMax(-1), timeMax(22), fX0(0.), fPla(-1) { // // Constructor @@ -225,7 +222,7 @@ TRDChamber::TRDChamber(Int_t det) : //________________________________________________________ TRDChamber::TRDChamber(const TRDChamber &mod): - Reve::RenderElement(), TRDModule("Chmb", mod.fDet) + TEveElement(), TRDModule("Chmb", mod.fDet) { // // Copy constructor @@ -362,7 +359,7 @@ void TRDChamber::LoadTracklets(TObjArray *tracks) // Info("LoadTracklets()", Form("tracks = 0x%x", tracks)); if(!fTracklets){ - fTracklets = new std::vector; + fTracklets = new std::vector; } else fTracklets->clear(); @@ -371,7 +368,7 @@ void TRDChamber::LoadTracklets(TObjArray *tracks) for(int itrk=0; itrkGetEntries();itrk++){ trk = (AliTRDmcmTracklet*)tracks->At(itrk); trk->MakeTrackletGraph(fGeo,.5); - fTracklets->push_back(new Reve::Track()); + fTracklets->push_back(new TEveTrack()); fTracklets->back()->SetLineColor(4); cloc[0] = trk->GetTime0(); // x0 @@ -403,7 +400,7 @@ void TRDChamber::Paint(Option_t* option) if(fRecPoints && fRnrRecPoints) fRecPoints->GetObject()->Paint(option); if(fHits && fRnrHits) fHits->GetObject()->Paint(option); if(fTracklets && fRnrTracklets){ - for(vector::iterator i=fTracklets->begin(); i != fTracklets->end(); ++i) (*i)->Paint(option); + for(vector::iterator i=fTracklets->begin(); i != fTracklets->end(); ++i) (*i)->Paint(option); } } diff --git a/EVE/Alieve/TRDModuleImp.h b/EVE/Alieve/TRDModuleImp.h index 7ae0d042d14..1d7f0398e6a 100644 --- a/EVE/Alieve/TRDModuleImp.h +++ b/EVE/Alieve/TRDModuleImp.h @@ -12,9 +12,7 @@ #include -#ifndef REVE_RenderElement_H -#include -#endif +#include #ifndef ALIEVE_TRDModule_H #include "TRDModule.h" @@ -27,14 +25,13 @@ class AliTRDdataArrayI; class AliTRDdigitsManager; class TObjArray; -namespace Reve { - class Track; -} +class TEveTrack; + namespace Alieve { class TRDHits; class TRDDigits; - class TRDChamber : public Reve::RenderElement, public TRDModule + class TRDChamber : public TEveElement, public TRDModule { friend class TRDDigits; public: @@ -63,7 +60,7 @@ namespace Alieve { TRDDigits *fDigits; // digits representation TRDHits *fHits; // hits representation TRDHits *fRecPoints;// cluster representation - std::vector *fTracklets; // mcm tracklets + std::vector *fTracklets; // mcm tracklets // data representation section Int_t rowMax; // number of rows for this pad plane @@ -79,7 +76,7 @@ namespace Alieve { }; - class TRDNode : public Reve::RenderElement, public TRDModule + class TRDNode : public TEveElement, public TRDModule { public: TRDNode(const char *typ, Int_t det=0); diff --git a/EVE/Alieve/TrackFitter.cxx b/EVE/Alieve/TrackFitter.cxx index dab5de7143d..e327cb15877 100644 --- a/EVE/Alieve/TrackFitter.cxx +++ b/EVE/Alieve/TrackFitter.cxx @@ -2,7 +2,6 @@ #include "TrackFitter.h" -//#include "TClass.h" #include "TCanvas.h" #include "TGraph.h" #include "TGraphErrors.h" @@ -11,25 +10,26 @@ #include "AliRieman.h" #include "AliExternalTrackParam.h" -#include -#include -#include +#include +#include +#include +#include -using namespace Reve; using namespace Alieve; //______________________________________________________________________ // TrackFitter // -// TrackFitter is an interface to helix fit. It creates a set of points, listening to signal -// PointCtrlClicked() of any Reve::PointSet. Via editor it fits selected points and creates a -// reconstructed track. +// TrackFitter is an interface to helix fit. It creates a set of +// points, listening to signal PointCtrlClicked() of any +// TEvePointSet. Via editor it fits selected points and creates a +// reconstructed track. // ClassImp(TrackFitter) -TrackFitter::TrackFitter(const Text_t* name, Int_t n_points, TreeVarType_e tv_type) : - Reve::PointSet(name, n_points, tv_type), +TrackFitter::TrackFitter(const Text_t* name, Int_t n_points, ETreeVarType_e tv_type) : + TEvePointSet(name, n_points, tv_type), fGraphSelected(0), fGraphFitted(0), @@ -53,12 +53,12 @@ TrackFitter::TrackFitter(const Text_t* name, Int_t n_points, TreeVarType_e tv_ty fGraphFitted->SetName("Fitted points"); fGraphFitted->SetMarkerColor(2); - fTrackList = new TrackList("Tracks"); + fTrackList = new TEveTrackList("Tracks"); fTrackList->SetLineWidth(2); fTrackList->SetLineColor(8); fTrackList->IncDenyDestroy(); - fTrackList->GetRnrStyle()->SetEditPathMarks(kTRUE); - gReve->AddRenderElement(fTrackList, this); + fTrackList->GetPropagator()->SetEditPathMarks(kTRUE); + gEve->AddElement(fTrackList, this); UpdateItems(); } @@ -74,11 +74,11 @@ TrackFitter::~TrackFitter() /**************************************************************************/ void TrackFitter::DestroyElements() { - // Virtual method of base class Reve::RenderElement. + // Virtual method of base class TEveElement. // It preserves track list to have coomon track propagator attributes. - RenderElement::DestroyElements(); - gReve->AddRenderElement(fTrackList, this); + TEveElement::DestroyElements(); + gEve->AddElement(fTrackList, this); fTrackList->DestroyElements(); UpdateItems(); } @@ -91,8 +91,8 @@ void TrackFitter::Start() Reset(); if(fConnected == kFALSE) { - TQObject::Connect("Reve::PointSet", "PointCtrlClicked(Reve::PointSet*,Int_t)", - "Alieve::TrackFitter", this, "AddFitPoint(Reve::PointSet*,Int_t)"); + TQObject::Connect("TEvePointSet", "PointCtrlClicked(TEvePointSet*,Int_t)", + "Alieve::TrackFitter", this, "AddFitPoint(TEvePointSet*,Int_t)"); fConnected = kTRUE; } @@ -104,14 +104,14 @@ void TrackFitter::Stop() if(fConnected) { - TQObject::Disconnect("Reve::PointSet", "AddFitPoint(Reve::PointSet*,Int_t)"); + TQObject::Disconnect("TEvePointSet", "AddFitPoint(TEvePointSet*,Int_t)"); fConnected = kFALSE; } } /**************************************************************************/ -void TrackFitter::AddFitPoint(Reve::PointSet* ps, Int_t n) +void TrackFitter::AddFitPoint(TEvePointSet* ps, Int_t n) { // Add/remove given point depending if exists in the fMapPS. @@ -180,7 +180,7 @@ void TrackFitter::FitTrack() Double_t cov[15]; fRieman->GetExternalParameters(r, param, cov); // curvature to pt - param[4] /= TrackRnrStyle::fgDefMagField*TrackRnrStyle::fgkB2C; + param[4] /= TEveTrackPropagator::fgDefMagField*TEveTrackPropagator::fgkB2C; // sign in tang if(param[4] < 0) param[3] *= -1; AliExternalTrackParam trackParam(r, fAlpha, param, cov); @@ -188,27 +188,27 @@ void TrackFitter::FitTrack() // make track Double_t V0[3]; - trackParam.GetXYZAt(r, TrackRnrStyle::fgDefMagField, V0); + trackParam.GetXYZAt(r, TEveTrackPropagator::fgDefMagField, V0); Double_t P0[3]; - trackParam.GetPxPyPzAt(r, TrackRnrStyle::fgDefMagField, P0); - RecTrack rc; - rc.V.Set(V0); - rc.P.Set(P0); - rc.sign = trackParam.Charge(); + trackParam.GetPxPyPzAt(r, TEveTrackPropagator::fgDefMagField, P0); + TEveRecTrack rc; + rc.fV.Set(V0); + rc.fP.Set(P0); + rc.fSign = trackParam.Charge(); - Track* track = new Track(&rc, fTrackList->GetRnrStyle()); + TEveTrack* track = new TEveTrack(&rc, fTrackList->GetPropagator()); track->SetName(Form("track %f", fAlpha)); - PathMark* pm = new PathMark(PathMark::Daughter); + TEvePathMark* pm = new TEvePathMark(TEvePathMark::kDaughter); for(Int_t i=0; i==fLastPoint; i++) { GetPoint(i, x, y, z); - pm->V.Set(x, y, z); - pm->P.Set(P0); + pm->fV.Set(x, y, z); + pm->fP.Set(P0); track->AddPathMark(pm); } track->MakeTrack(); track->SetAttLineAttMarker(fTrackList); - gReve->AddRenderElement(track, fTrackList); + gEve->AddElement(track, fTrackList); } @@ -217,7 +217,7 @@ void TrackFitter::Reset(Int_t n, Int_t ids) // Reset selection. if(fRieman) fRieman->Reset(); - PointSet::Reset(n, ids); + TEvePointSet::Reset(n, ids); fMapPS.clear(); } @@ -226,7 +226,7 @@ void TrackFitter::DrawRiemanGraph() { // Draw graph of rieman fit. - static const Exc_t eH("TrackFitter::DrawRiemanGraph "); + static const TEveException eH("TrackFitter::DrawRiemanGraph "); if(fRieman == 0) throw(eH + "fitter not set."); diff --git a/EVE/Alieve/TrackFitter.h b/EVE/Alieve/TrackFitter.h index 4359dc482db..0a56f18950b 100644 --- a/EVE/Alieve/TrackFitter.h +++ b/EVE/Alieve/TrackFitter.h @@ -3,7 +3,7 @@ #ifndef ALIEVE_TrackFitter_H #define ALIEVE_TrackFitter_H -#include +#include #include #include @@ -11,14 +11,11 @@ class TGraphErrors; class TGraph; class AliRieman; -namespace Reve -{ -class TrackList; -} +class TEveTrackList; namespace Alieve { -class TrackFitter : public Reve::PointSet +class TrackFitter : public TEvePointSet { private: TrackFitter(const TrackFitter&); // Not implemented @@ -31,9 +28,9 @@ protected: struct Point_t { // inner structure to check duplicates - Reve::PointSet* fPS; // selected pointset + TEvePointSet* fPS; // selected pointset Int_t fIdx; // location in the point set array - Point_t(Reve::PointSet* ps, Int_t i): fPS(ps), fIdx(i){} + Point_t(TEvePointSet* ps, Int_t i): fPS(ps), fIdx(i){} bool operator<(const Point_t& o) const { if (fPS != o.fPS) return fPS < o.fPS; return fIdx < o.fIdx; } }; @@ -43,14 +40,14 @@ protected: Bool_t fConnected; // object connected to pointset Ctrl-shift signal - Reve::TrackList* fTrackList; // track list created with rieman fit + TEveTrackList* fTrackList; // track list created with rieman fit - std::map fMapPS; // map of selected points from different PointSet + std::map fMapPS; // map of selected points from different TEvePointSet public: - TrackFitter(const Text_t* name, Int_t n_points=0, TreeVarType_e tv_type=TVT_XYZ); + TrackFitter(const Text_t* name, Int_t n_points=0, ETreeVarType_e tv_type=kTVT_XYZ); virtual ~TrackFitter(); - void AddFitPoint(Reve::PointSet*,Int_t); // slot for PointCtrlClicked() signal + void AddFitPoint(TEvePointSet*,Int_t); // slot for PointCtrlClicked() signal virtual void DestroyElements(); // *MENU* diff --git a/EVE/Alieve/TrackFitterEditor.cxx b/EVE/Alieve/TrackFitterEditor.cxx index 4e767dbbacf..b6b5e4e0c7a 100644 --- a/EVE/Alieve/TrackFitterEditor.cxx +++ b/EVE/Alieve/TrackFitterEditor.cxx @@ -4,8 +4,6 @@ #include #include - -using namespace Reve; using namespace Alieve; //______________________________________________________________________ diff --git a/EVE/Alieve/VSDCreator.cxx b/EVE/Alieve/VSDCreator.cxx index 0ad6a460b44..14e3e0382cd 100644 --- a/EVE/Alieve/VSDCreator.cxx +++ b/EVE/Alieve/VSDCreator.cxx @@ -2,7 +2,7 @@ #include "VSDCreator.h" -#include +#include #include #include @@ -26,8 +26,8 @@ #include #include +#include -using namespace Reve; using namespace Alieve; using namespace std; @@ -39,7 +39,7 @@ using namespace std; ClassImp(VSDCreator) VSDCreator::VSDCreator(const Text_t* name, const Text_t* title) : - VSD(name, title), + TEveVSD(name, title), mKineType (KT_Standard), mDataDir ("."), @@ -84,7 +84,7 @@ VSDCreator::VSDCreator(const Text_t* name, const Text_t* title) : void VSDCreator::CreateVSD(const Text_t* data_dir, Int_t event, const Text_t* vsd_file) { - static const Exc_t eH("VSDCreator::CreateVSD "); + static const TEveException eH("VSDCreator::CreateVSD "); mDataDir = data_dir; mEvent = event; @@ -117,10 +117,10 @@ void VSDCreator::CreateVSD(const Text_t* data_dir, Int_t event, // GledNS::PushFD(); if(mDebugLevel > 0) - printf("%s opening output VSD.\n", eH.Data()); + printf("%s opening output TEveVSD.\n", eH.Data()); TFile* file = TFile::Open(vsd_file, "RECREATE", "ALICE VisualizationDataSummary"); - mDirectory = new TDirectoryFile("Event0", ""); + fDirectory = new TDirectoryFile("Event0", ""); if(mDebugLevel > 0) printf("%s creating trees now ...\n", eH.Data()); @@ -133,19 +133,19 @@ void VSDCreator::CreateVSD(const Text_t* data_dir, Int_t event, file->Write(); file->Close(); delete file; - mDirectory =0; + fDirectory =0; //GledNS::PopFD(); - // clean after the VSD data was sucessfuly written - mTreeK = 0; - mTreeH = 0; - //mTreeTR = 0; - mTreeC = 0; - mTreeV0 = 0; - mTreeKK = 0; - mTreeR = 0; - mTreeGI = 0; + // clean after the TEveVSD data was sucessfuly written + fTreeK = 0; + fTreeH = 0; + //fTreeTR = 0; + fTreeC = 0; + fTreeV0 = 0; + fTreeKK = 0; + fTreeR = 0; + fTreeGI = 0; pRunLoader->UnloadAll(); delete pRunLoader; @@ -160,35 +160,35 @@ void VSDCreator::CreateVSD(const Text_t* data_dir, Int_t event, void VSDCreator::CreateTrees() { - static const Exc_t eH("VSDCreator::CreateTrees "); + static const TEveException eH("VSDCreator::CreateTrees "); - if(mDirectory == 0) + if(fDirectory == 0) throw(eH + "output directory not set."); try { if(mDebugLevel > 1) printf("%sConvertKinematics.\n", eH.Data()); ConvertKinematics(); - } catch(Exc_t& exc) { WarnCaller(exc); } + } catch(TEveException& exc) { Warning(eH, exc); } try { if(mDebugLevel > 1) printf("%sConvertHits.\n", eH.Data()); ConvertHits(); - } catch(Exc_t& exc) { WarnCaller(exc); } + } catch(TEveException& exc) { Warning(eH, exc); } try { if(mDebugLevel > 1) printf("%sConvertClusters.\n", eH.Data()); ConvertClusters(); - } catch(Exc_t& exc) { WarnCaller(exc); } + } catch(TEveException& exc) { Warning(eH, exc); } try { if(mDebugLevel > 1) printf("%sConvertRecTracks.\n", eH.Data()); ConvertRecTracks(); - } catch(Exc_t& exc) { - WarnCaller(exc + " Skipping V0 extraction."); + } catch(TEveException& exc) { + Warning(exc, "skipping V0 extraction."); goto end_esd_processing; } @@ -196,13 +196,13 @@ void VSDCreator::CreateTrees() if(mDebugLevel > 1) printf("%sConvertV0.\n", eH.Data()); ConvertV0(); - } catch(Exc_t& exc) { WarnCaller(exc); } + } catch(TEveException& exc) { Warning(eH, exc); } try { if(mDebugLevel > 1) printf("%sConvertKinks.\n", eH.Data()); ConvertKinks(); - } catch(Exc_t& exc) { WarnCaller(exc); } + } catch(TEveException& exc) { Warning(eH, exc); } end_esd_processing: @@ -210,7 +210,7 @@ end_esd_processing: if(mDebugLevel > 1) printf("%sConvertGenInfo.\n", eH.Data()); ConvertGenInfo(); - } catch(Exc_t& exc) { WarnCaller(exc); } + } catch(TEveException& exc) { Warning(eH, exc); } return; } @@ -221,46 +221,48 @@ end_esd_processing: void VSDCreator::ConvertKinematics() { - static const Exc_t eH("VSDCreator::ConvertKinematics "); + static const TEveException eH("VSDCreator::ConvertKinematics "); - if(mTreeK != 0) + if(fTreeK != 0) throw (eH + "kinematics already converted"); AliStack* stack = pRunLoader->Stack(); if(stack == 0) throw(eH + "stack is null."); - mDirectory->cd(); - mTreeK = new TTree("Kinematics", "TParticles sorted by Label"); + fDirectory->cd(); + fTreeK = new TTree("Kinematics", "TParticles sorted by Label"); Int_t nentries = stack->GetNtrack(); - vector vmc(nentries); + vector vmc(nentries); for (Int_t idx=0; idxParticle(idx); - vmc[idx] = *tp; - vmc[idx].label = idx; + vmc[idx] = *tp; + vmc[idx].fLabel = idx; } - // read track refrences - TTree* mTreeTR = pRunLoader->TreeTR(); + // read track refrences + // functionality now in KineTools. + /* + TTree* fTreeTR = pRunLoader->TreeTR(); - if(mTreeTR == 0) { - WarnCaller(eH + "no TrackRefs; some data will not be available."); + if(fTreeTR == 0) { + Warning(eH, "no TrackRefs; some data will not be available."); } else { TClonesArray* RunArrayTR = 0; - mTreeTR->SetBranchAddress("AliRun", &RunArrayTR); + fTreeTR->SetBranchAddress("AliRun", &RunArrayTR); - Int_t nPrimaries = (Int_t) mTreeTR->GetEntries(); + Int_t nPrimaries = (Int_t) fTreeTR->GetEntries(); for (Int_t iPrimPart = 0; iPrimPartGetEntry(%d) \n",iPrimPart); - mTreeTR->GetEntry(iPrimPart); - // printf("END mTreeTR->GetEntry(%d) \n",iPrimPart); + // printf("T0 fTreeTR->GetEntry(%d) \n",iPrimPart); + fTreeTR->GetEntry(iPrimPart); + // printf("END fTreeTR->GetEntry(%d) \n",iPrimPart); for (Int_t iTrackRef = 0; iTrackRef < RunArrayTR->GetEntriesFast(); iTrackRef++) { AliTrackReference *trackRef = (AliTrackReference*)RunArrayTR->At(iTrackRef); Int_t track = trackRef->GetTrack(); if(track < nentries && track > 0){ - MCTrack& mct = vmc[track]; + TEveMCTrack& mct = vmc[track]; if(trackRef->TestBit(kNotDeleted)) { mct.decayed = true; mct.t_decay = trackRef->GetTime(); @@ -277,16 +279,17 @@ void VSDCreator::ConvertKinematics() } } } + */ - mTreeK->Branch("K", "Reve::MCTrack", &mpK, fBuffSize); + fTreeK->Branch("K", "TEveMCTrack", &fpK, fBuffSize); printf("sizeofvmc = %d\n", vmc.size()); - for(vector::iterator k=vmc.begin(); k!=vmc.end(); ++k) { - MCTrack& mct = *k; - mK = mct; + for(vector::iterator k=vmc.begin(); k!=vmc.end(); ++k) { + TEveMCTrack& mct = *k; + fK = mct; TParticle* m = &mct; - Int_t mi = mct.label; + Int_t mi = mct.fLabel; int cnt = 0; while(m->GetMother(0) != -1) { if(cnt > 100) { @@ -296,12 +299,12 @@ void VSDCreator::ConvertKinematics() m = &vmc[mi]; ++cnt; } - mK.eva_label = mi; + fK.fEvaLabel = mi; - mTreeK->Fill(); + fTreeK->Fill(); } - mTreeK->BuildIndex("label"); + fTreeK->BuildIndex("label"); } /**************************************************************************/ @@ -331,14 +334,14 @@ namespace { void VSDCreator::ConvertHits() { - static const Exc_t eH("VSDCreator::ConvertHits "); + static const TEveException eH("VSDCreator::ConvertHits "); - if(mTreeH != 0) + if(fTreeH != 0) throw(eH + "hits already converted."); - mDirectory->cd(); - mTreeH = new TTree("Hits", "Combined detector hits."); - mTreeH->Branch("H", "Reve::Hit", &mpH, fBuffSize); + fDirectory->cd(); + fTreeH = new TTree("Hits", "Combined detector hits."); + fTreeH->Branch("H", "TEveHit", &fpH, fBuffSize); map hmap; // parameters for ITS, TPC hits filtering @@ -356,7 +359,7 @@ void VSDCreator::ConvertHits() Int_t count = 0; TTree* treeh = pRunLoader->GetTreeH(det.name, false); if(treeh == 0) { - WarnCaller(eH + "no hits for "+ det.name +"."); + Warning(eH, Form("no hits for %s.", det.name)); continue; } AliTPCTrackHitsV2 hv2, *_hv2=&hv2; @@ -369,15 +372,16 @@ void VSDCreator::ConvertHits() x = y = z = 0; do { AliHit* ah = hv2.GetHit(); - x1=ah->X();y1=ah->Y();z1=ah->Z(); - if((x-x1)*(x-x1)+(y-y1)*(y-y1)+(z-z1)*(z-z1) > tpc_sqr_res) { - mH.det_id = det.detidx; - mH.subdet_id = 0; - mH.label = ah->Track(); - mH.eva_label = eva_idx; - mH.V.x = x1; mH.V.y = y1; mH.V.z = z1; - mTreeH->Fill(); - hmap[mH.label]++; + x1 = ah->X(); y1 = ah->Y(); z1 = ah->Z(); + if ((x-x1)*(x-x1) + (y-y1)*(y-y1) + (z-z1)*(z-z1) > tpc_sqr_res) + { + fH.fDetId = det.detidx; + fH.fSubdetId = 0; + fH.fLabel = ah->Track(); + fH.fEvaLabel = eva_idx; + fH.fV.fX = x1; fH.fV.fY = y1; fH.fV.fZ = z1; + fTreeH->Fill(); + hmap[fH.fLabel]++; x = x1; y = y1; z = z1; count++; } @@ -389,7 +393,7 @@ void VSDCreator::ConvertHits() default: { TTree* treeh = pRunLoader->GetTreeH(det.name, false); if(treeh == 0) { - WarnCaller(eH + "no hits for "+ det.name +"."); + Warning(eH, Form("no hits for %s.", det.name)); continue; } TClonesArray *arr = new TClonesArray(det.hitbranch); @@ -405,18 +409,18 @@ void VSDCreator::ConvertHits() // printf("%d entry %d hits for primary %d \n", i, nh, eva_idx); for (Int_t j=0; jUncheckedAt(j); - mH.det_id = det.detidx; - mH.subdet_id = 0; - mH.label = ali_hit->GetTrack(); - mH.eva_label = eva_idx; - mH.V.Set(ali_hit->X(), ali_hit->Y(), ali_hit->Z()); + fH.fDetId = det.detidx; + fH.fSubdetId = 0; + fH.fLabel = ali_hit->GetTrack(); + fH.fEvaLabel = eva_idx; + fH.fV.Set(ali_hit->X(), ali_hit->Y(), ali_hit->Z()); if(det.detidx == 2) { x1=ali_hit->X();y1=ali_hit->Y();z1=ali_hit->Z(); if((x-x1)*(x-x1)+(y-y1)*(y-y1)+(z-z1)*(z-z1) < trd_sqr_res) continue; x=x1; y=y1; z=z1; } - hmap[mH.label]++; - mTreeH->Fill(); + hmap[fH.fLabel]++; + fTreeH->Fill(); } } delete arr; @@ -428,7 +432,7 @@ void VSDCreator::ConvertHits() //set geninfo for(map::iterator j=hmap.begin(); j!=hmap.end(); ++j) { - GetGeninfo(j->first)->n_hits += j->second; + GetGeninfo(j->first)->fNHits += j->second; } } @@ -438,29 +442,29 @@ void VSDCreator::ConvertHits() void VSDCreator::ConvertClusters() { - static const Exc_t eH("VSDCreator::ConvertClusters "); + static const TEveException eH("VSDCreator::ConvertClusters "); - if(mTreeC != 0) + if(fTreeC != 0) throw(eH + "clusters already converted."); - mDirectory->cd(); - mTreeC = new TTree("Clusters", "rec clusters"); - mTreeC->Branch("C", "Reve::Cluster", &mpC, fBuffSize); + fDirectory->cd(); + fTreeC = new TTree("Clusters", "rec clusters"); + fTreeC->Branch("C", "TEveCluster", &fpC, fBuffSize); try { ConvertITSClusters(); - } catch(Exc_t& exc) { WarnCaller(exc); } + } catch(TEveException& exc) { Warning(eH, exc); } try { ConvertTPCClusters(); - } catch(Exc_t& exc) { WarnCaller(exc); } + } catch(TEveException& exc) { Warning(eH, exc); } } /**************************************************************************/ void VSDCreator::ConvertTPCClusters() { - static const Exc_t eH("VSDCreator::ConvertTPCClusters "); + static const TEveException eH("VSDCreator::ConvertTPCClusters "); auto_ptr f ( TFile::Open(Form("%s/TPC.RecPoints.root", mDataDir.Data())) ); @@ -506,22 +510,24 @@ void VSDCreator::ConvertTPCClusters() if(_clrow->GetArray()) { // cl = new AliTPCclusterMI(*(AliTPCclusterMI*)_clrow->GetArray()->UncheckedAt(ncl)); cl = (AliTPCclusterMI*)_clrow->GetArray()->UncheckedAt(ncl); - if(cl->GetLabel(0) >= 0){ + if(cl->GetLabel(0) >= 0) + { x = par->GetPadRowRadii(sec,row); y = cl->GetY(); z = cl->GetZ(); par->AdjustCosSin(sec,cs,sn); tmp = x*cs-y*sn; y= x*sn+y*cs; x=tmp; - mC.det_id = 1; - mC.subdet_id = 0; - mC.label[0] = cl->GetLabel(0); - mC.label[1] = cl->GetLabel(1); - mC.label[2] = cl->GetLabel(2); - mC.V.Set(x, y, z); - - mTreeC->Fill(); - { int i = 0; - while(i < 3 && mC.label[i]) - cmap[mC.label[i++]]++; + fC.fDetId = 1; + fC.fSubdetId = 0; + fC.fLabel[0] = cl->GetLabel(0); + fC.fLabel[1] = cl->GetLabel(1); + fC.fLabel[2] = cl->GetLabel(2); + fC.fV.Set(x, y, z); + + fTreeC->Fill(); + { + int i = 0; + while(i < 3 && fC.fLabel[i]) + cmap[fC.fLabel[i++]]++; } } } @@ -530,7 +536,7 @@ void VSDCreator::ConvertTPCClusters() } //set geninfo for(map::iterator j=cmap.begin(); j!=cmap.end(); ++j) { - GetGeninfo(j->first)->n_clus += j->second; + GetGeninfo(j->first)->fNClus += j->second; } } @@ -538,7 +544,7 @@ void VSDCreator::ConvertTPCClusters() void VSDCreator::ConvertITSClusters() { - static const Exc_t eH("VSDCreator::ConvertITSClusters "); + static const TEveException eH("VSDCreator::ConvertITSClusters "); auto_ptr f ( TFile::Open(Form("%s/ITS.RecPoints.root", mDataDir.Data())) ); @@ -590,27 +596,27 @@ void VSDCreator::ConvertITSClusters() Float_t cp=TMath::Cos(phi1), sp=TMath::Sin(phi1); Float_t r=tx*cp+ty*sp; - gc[0]= r*cp - recp->GetY()*sp; - gc[1]= r*sp + recp->GetY()*cp; - gc[2]= recp->GetZ(); - - mC.det_id = 0; - mC.subdet_id = 0; - mC.label[0] = recp->GetLabel(0); - mC.label[1] = recp->GetLabel(1); - mC.label[2] = recp->GetLabel(2); - mC.V.x = r*cp - recp->GetY()*sp; - mC.V.y = r*sp + recp->GetY()*cp; - mC.V.z = recp->GetZ(); - mTreeC->Fill(); + gc[0] = r*cp - recp->GetY()*sp; + gc[1] = r*sp + recp->GetY()*cp; + gc[2] = recp->GetZ(); + + fC.fDetId = 0; + fC.fSubdetId = 0; + fC.fLabel[0] = recp->GetLabel(0); + fC.fLabel[1] = recp->GetLabel(1); + fC.fLabel[2] = recp->GetLabel(2); + fC.fV.fX = r*cp - recp->GetY()*sp; + fC.fV.fY = r*sp + recp->GetY()*cp; + fC.fV.fZ = recp->GetZ(); + fTreeC->Fill(); { int i = 0; - while(i < 3 && mC.label[i]) - cmap[mC.label[i++]]++; + while(i < 3 && fC.fLabel[i]) + cmap[fC.fLabel[i++]]++; } } for(map::iterator j=cmap.begin(); j!=cmap.end(); ++j) { - GetGeninfo(j->first)->n_clus += j->second; + GetGeninfo(j->first)->fNClus += j->second; } } delete arr; @@ -622,15 +628,15 @@ void VSDCreator::ConvertITSClusters() void VSDCreator::ConvertRecTracks() { - static const Exc_t eH("VSDCreator::ConvertRecTracks "); + static const TEveException eH("VSDCreator::ConvertRecTracks "); - if(mTreeR != 0) + if(fTreeR != 0) throw(eH + "tracks already converted."); - mDirectory->cd(); - mTreeR = new TTree("RecTracks", "rec tracks"); + fDirectory->cd(); + fTreeR = new TTree("RecTracks", "rec tracks"); - mTreeR->Branch("R", "Reve::RecTrack", &mpR, 512*1024,1); + fTreeR->Branch("R", "TEveRecTrack", &fpR, 512*1024,1); TFile f(Form("%s/AliESDs.root", mDataDir.Data())); if(!f.IsOpen()) @@ -653,16 +659,16 @@ void VSDCreator::ConvertRecTracks() for (Int_t n=0; nGetNumberOfTracks(); n++) { esd_t = fEvent->GetTrack(n); - mR.label = esd_t->GetLabel(); - mR.status = (Int_t) esd_t->GetStatus(); - mR.sign = (Int_t) esd_t->GetSign(); - esd_t->GetXYZ(dbuf); mR.V.Set(dbuf); - esd_t->GetPxPyPz(dbuf); mR.P.Set(dbuf); + fR.fLabel = esd_t->GetLabel(); + fR.fStatus = (Int_t) esd_t->GetStatus(); + fR.fSign = (Int_t) esd_t->GetSign(); + esd_t->GetXYZ(dbuf); fR.fV.Set(dbuf); + esd_t->GetPxPyPz(dbuf); fR.fP.Set(dbuf); Double_t ep = esd_t->GetP(); - mR.beta = ep/TMath::Sqrt(ep*ep + TMath::C()*TMath::C()*esd_t->GetMass()*esd_t->GetMass()); - mTreeR->Fill(); + fR.fBeta = ep/TMath::Sqrt(ep*ep + TMath::C()*TMath::C()*esd_t->GetMass()*esd_t->GetMass()); + fTreeR->Fill(); } - mTreeR->BuildIndex("label"); + fTreeR->BuildIndex("label"); delete fEvent; } @@ -670,15 +676,15 @@ void VSDCreator::ConvertRecTracks() void VSDCreator::ConvertV0() { - static const Exc_t eH("VSDCreator::ConvertV0 "); + static const TEveException eH("VSDCreator::ConvertV0 "); - if(mTreeV0 != 0) + if(fTreeV0 != 0) throw(eH + "V0 already converted."); - mDirectory->cd(); - mTreeV0 = new TTree("V0", "V0 points"); + fDirectory->cd(); + fTreeV0 = new TTree("V0", "V0 points"); - mTreeV0->Branch("V0", "Reve::RecV0", &mpV0, 512*1024,1); + fTreeV0->Branch("V0", "TEveRecV0", &fpV0, 512*1024,1); TFile f(Form("%s/AliESDs.root", mDataDir.Data())); if(!f.IsOpen()){ @@ -702,42 +708,42 @@ void VSDCreator::ConvertV0() Double_t pos[3]; - mV0.status = av->GetStatus(); + fV0.fStatus = av->GetStatus(); // Point of closest approach av->GetXYZ(pos[0],pos[1],pos[2]); - mV0.V_ca.x = pos[0]; - mV0.V_ca.y = pos[1]; - mV0.V_ca.z = pos[2]; + fV0.fVCa.fX = pos[0]; + fV0.fVCa.fY = pos[1]; + fV0.fVCa.fZ = pos[2]; // set birth vertex of neutral particle av->GetXYZ(pos[0], pos[1], pos[2]); - mV0.V0_birth.Set(pos); + fV0.fV0Birth.Set(pos); // momentum and position of negative particle av->GetParamN()->GetPxPyPz(pos); - mV0.P_neg.Set(pos); + fV0.fPNeg.Set(pos); av->GetParamN()->GetXYZ(pos); - mV0.V_neg.Set(pos); + fV0.fVNeg.Set(pos); // momentum and position of positive particle av->GetParamP()->GetPxPyPz(pos); - mV0.P_pos.Set(pos); + fV0.fPPos.Set(pos); av->GetParamP()->GetXYZ(pos); - mV0.V_pos.Set(pos); + fV0.fVPos.Set(pos); - mV0.label = 0; // !!!! mother label unknown - mV0.pdg = av->GetPdgCode(); + fV0.fLabel = 0; // !!!! mother label unknown + fV0.fPdg = av->GetPdgCode(); // daughter indices - mV0.d_label[0] = TMath::Abs(trackN->GetLabel()); - mV0.d_label[1] = TMath::Abs(trackP->GetLabel()); + fV0.fDLabel[0] = TMath::Abs(trackN->GetLabel()); + fV0.fDLabel[1] = TMath::Abs(trackP->GetLabel()); // printf("V0 convert labels(%d,%d) index(%d,%d)\n", - // mV0.d_label[0], mV0.d_label[1], + // fV0.d_label[0], fV0.d_label[1], // av->GetNIndex(), av->GetPIndex()); - mTreeV0->Fill(); + fTreeV0->Fill(); } - // if(fEvent->GetNumberOfV0s()) mTreeV0->BuildIndex("label"); + // if(fEvent->GetNumberOfV0s()) fTreeV0->BuildIndex("label"); delete fEvent; } @@ -745,15 +751,15 @@ void VSDCreator::ConvertV0() void VSDCreator::ConvertKinks() { - static const Exc_t eH("VSDCreator::ConvertKinks "); + static const TEveException eH("VSDCreator::ConvertKinks "); - if(mTreeKK != 0) + if(fTreeKK != 0) throw(eH + "Kinks already converted."); - mDirectory->cd(); - mTreeKK = new TTree("Kinks", "ESD Kinks"); + fDirectory->cd(); + fTreeKK = new TTree("Kinks", "ESD Kinks"); - mTreeKK->Branch("KK", "Reve::RecKink", &mpKK, fBuffSize); + fTreeKK->Branch("KK", "TEveRecKink", &fpKK, fBuffSize); TFile f(Form("%s/AliESDs.root", mDataDir.Data())); if(!f.IsOpen()){ @@ -777,74 +783,73 @@ void VSDCreator::ConvertKinks() Double_t pos[3]; - - mKK.label = kk->GetLabel(0); - mKK.status = Int_t(kk->GetStatus(1) << 8 + kk->GetStatus(2)); + fKK.fLabel = kk->GetLabel(0); + fKK.fStatus = Int_t(kk->GetStatus(1) << 8 + kk->GetStatus(2)); // reconstructed kink position - mKK.label_sec = kk->GetLabel(1); - mKK.V_kink.Set(kk->GetPosition()); + fKK.fLabelSec = kk->GetLabel(1); + fKK.fVKink.Set(kk->GetPosition()); const AliExternalTrackParam& tp_mother = kk->RefParamMother(); // momentum and position of mother tp_mother.GetPxPyPz(pos); - mKK.P.Set(pos); + fKK.fP.Set(pos); tp_mother.GetXYZ(pos); - mKK.V.Set(pos); + fKK.fV.Set(pos); const Double_t* par = tp_mother.GetParameter(); // printf("KINK Pt %f, %f \n",1/tp_mother.Pt(),par[4] ); - mKK.sign = (par[4] < 0) ? -1 : 1; + fKK.fSign = (par[4] < 0) ? -1 : 1; const AliExternalTrackParam& tp_daughter = kk->RefParamDaughter(); // momentum and position of daughter tp_daughter.GetPxPyPz(pos); - mKK.P_sec.Set(pos); + fKK.fPSec.Set(pos); tp_daughter.GetXYZ(pos); - mKK.V_end.Set(pos); + fKK.fVEnd.Set(pos); - mTreeKK->Fill(); + fTreeKK->Fill(); } - if(fEvent->GetNumberOfKinks()) mTreeKK->BuildIndex("label"); + if(fEvent->GetNumberOfKinks()) fTreeKK->BuildIndex("label"); delete fEvent; } /**************************************************************************/ -// GenInfo +// TEveMCRecCrossRef /**************************************************************************/ void VSDCreator::ConvertGenInfo() { - static const Exc_t eH("VSDCreator::ConvertGenInfo "); + static const TEveException eH("VSDCreator::ConvertGenInfo "); - if(mTreeGI != 0) + if(fTreeGI != 0) throw(eH + "GI already converted."); - mDirectory->cd(); - mTreeGI = new TTree("GenInfo", "Objects prepared for cross querry"); + fDirectory->cd(); + fTreeGI = new TTree("TEveMCRecCrossRef", "Objects prepared for cross querry"); - GenInfo::Class()->IgnoreTObjectStreamer(true); - mTreeGI->Branch("GI", "Reve::GenInfo", &mpGI, fBuffSize); - mTreeGI->Branch("K.", "Reve::MCTrack", &mpK); - mTreeGI->Branch("R.", "Reve::RecTrack", &mpR); + TEveMCRecCrossRef::Class()->IgnoreTObjectStreamer(true); + fTreeGI->Branch("GI", "TEveMCRecCrossRef", &fpGI, fBuffSize); + fTreeGI->Branch("K.", "TEveMCTrack", &fpK); + fTreeGI->Branch("R.", "TEveRecTrack", &fpR); - for(map::iterator j=mGenInfoMap.begin(); j!=mGenInfoMap.end(); ++j) { - mGI = *(j->second); - mGI.label = j->first; - mTreeK->GetEntry(j->first); + for (map::iterator j=mGenInfoMap.begin(); j!=mGenInfoMap.end(); ++j) { + fGI = *(j->second); + fGI.fLabel = j->first; + fTreeK->GetEntry(j->first); - if(mTreeR) { - Int_t re = mTreeR->GetEntryNumberWithIndex(j->first); + if (fTreeR) { + Int_t re = fTreeR->GetEntryNumberWithIndex(j->first); if(re != -1) - mGI.is_rec = true; + fGI.fIsRec = true; } - // Int_t has_v0 = mTreeV0->GetEntryNumberWithIndex(j->first); + // Int_t has_v0 = fTreeV0->GetEntryNumberWithIndex(j->first); //if (has_v0 != -1) - // mGI.has_V0 = true; - if (mTreeKK) { - Int_t has_kk = mTreeKK->GetEntryNumberWithIndex(j->first); + // fGI.has_V0 = true; + if (fTreeKK) { + Int_t has_kk = fTreeKK->GetEntryNumberWithIndex(j->first); if (has_kk != -1) - mGI.has_kink = true; + fGI.fHasKink = true; } - mTreeGI->Fill(); + fTreeGI->Fill(); } mGenInfoMap.clear(); } @@ -855,7 +860,7 @@ void VSDCreator::ConvertGenInfo() /**************************************************************************/ /**************************************************************************/ -AliTPCParam* VSDCreator::GetTpcParam(const Exc_t& eh) +AliTPCParam* VSDCreator::GetTpcParam(const TEveException& eh) { auto_ptr fp( TFile::Open(Form("%s/galice.root", mDataDir.Data())) ); if(!fp.get()) @@ -868,13 +873,13 @@ AliTPCParam* VSDCreator::GetTpcParam(const Exc_t& eh) -GenInfo* VSDCreator::GetGeninfo(Int_t label) +TEveMCRecCrossRef* VSDCreator::GetGeninfo(Int_t label) { // printf("get_geninfo %d\n", label); - GenInfo* gi; - map::iterator i = mGenInfoMap.find(label); + TEveMCRecCrossRef* gi; + map::iterator i = mGenInfoMap.find(label); if(i == mGenInfoMap.end()) { - gi = new GenInfo(); + gi = new TEveMCRecCrossRef(); mGenInfoMap[label] = gi; } else { gi = i->second; diff --git a/EVE/Alieve/VSDCreator.h b/EVE/Alieve/VSDCreator.h index aa196a41d1a..0cdc9261092 100644 --- a/EVE/Alieve/VSDCreator.h +++ b/EVE/Alieve/VSDCreator.h @@ -3,7 +3,7 @@ #ifndef ALIEVE_VSDCreator_H #define ALIEVE_VSDCreator_H -#include +#include class AliTPCParam; class AliRunLoader; @@ -12,7 +12,7 @@ class AliRunLoader; namespace Alieve { -class VSDCreator : public Reve::VSD +class VSDCreator : public TEveVSD { VSDCreator(const VSDCreator&); // Not implemented VSDCreator& operator=(const VSDCreator&); // Not implemented @@ -22,8 +22,8 @@ public: protected: void MakeItsDigitsInfo(); - Reve::GenInfo* GetGeninfo(Int_t label); - AliTPCParam* GetTpcParam(const Reve::Exc_t& eh); + TEveMCRecCrossRef* GetGeninfo(Int_t label); + AliTPCParam* GetTpcParam(const TEveException& eh); KineType_e mKineType; // X{GS} 7 PhonyEnum() TString mDataDir; // X{G} @@ -34,7 +34,7 @@ protected: Int_t mDebugLevel; - std::map mGenInfoMap; //! + std::map mGenInfoMap; //! public: VSDCreator(const Text_t* name="Alieve::VSDCreator", const Text_t* title=""); diff --git a/EVE/Alieve/alieve_main/alieve_main.cxx b/EVE/Alieve/alieve_main/alieve_main.cxx index 4ba1fd2def0..326c0cd953f 100644 --- a/EVE/Alieve/alieve_main/alieve_main.cxx +++ b/EVE/Alieve/alieve_main/alieve_main.cxx @@ -1,13 +1,47 @@ -#include -#include +#include +#include +#include +#include +#include + +#include +#include #include int main(int argc, char **argv) { - Reve::SetupEnvironment(); + static const TEveException eH("alieve::main"); + + if(gSystem->Getenv("REVESYS") == 0) { + if(gSystem->Getenv("ALICE_ROOT") != 0) { + Info(eH.Data(), "setting REVESYS from ALICE_ROOT."); + gSystem->Setenv("REVESYS", Form("%s/EVE", gSystem->Getenv("ALICE_ROOT"))); + } else { + Error(eH.Data(), "REVESYS not defined, neither is ALICE_ROOT."); + gSystem->Exit(1); + } + } + if(gSystem->AccessPathName(gSystem->Getenv("REVESYS")) == kTRUE) { + Error(eH.Data(), "REVESYS '%s' does not exist.", gSystem->Getenv("REVESYS")); + gSystem->Exit(1); + } + + TString macPath(gROOT->GetMacroPath()); + macPath += Form(":%s/macros", gSystem->Getenv("REVESYS")); + gInterpreter->AddIncludePath(gSystem->Getenv("REVESYS")); + if(gSystem->Getenv("ALICE_ROOT") != 0) { + macPath += Form(":%s/alice-macros", gSystem->Getenv("REVESYS")); + gInterpreter->AddIncludePath(Form("%s/include", gSystem->Getenv("ALICE_ROOT"))); + gInterpreter->AddIncludePath(gSystem->Getenv("ALICE_ROOT")); + } + gROOT->SetMacroPath(macPath); + + TRint app("App", &argc, argv); + + TEveManager::Create(); + - int r = Reve::ReveManager::SpawnGuiAndRun(argc, argv); - Getlinem(kCleanUp, 0); - return r; + app.Run(); // Never returns. + return 0; } diff --git a/EVE/Alieve/Cascade.cxx b/EVE/Alieve/blacklisted-classes/Cascade.cxx similarity index 100% rename from EVE/Alieve/Cascade.cxx rename to EVE/Alieve/blacklisted-classes/Cascade.cxx diff --git a/EVE/Alieve/Cascade.h b/EVE/Alieve/blacklisted-classes/Cascade.h similarity index 100% rename from EVE/Alieve/Cascade.h rename to EVE/Alieve/blacklisted-classes/Cascade.h diff --git a/EVE/Alieve/CascadeEditors.cxx b/EVE/Alieve/blacklisted-classes/CascadeEditors.cxx similarity index 100% rename from EVE/Alieve/CascadeEditors.cxx rename to EVE/Alieve/blacklisted-classes/CascadeEditors.cxx diff --git a/EVE/Alieve/CascadeEditors.h b/EVE/Alieve/blacklisted-classes/CascadeEditors.h similarity index 100% rename from EVE/Alieve/CascadeEditors.h rename to EVE/Alieve/blacklisted-classes/CascadeEditors.h diff --git a/EVE/Alieve/V0.cxx b/EVE/Alieve/blacklisted-classes/V0.cxx similarity index 100% rename from EVE/Alieve/V0.cxx rename to EVE/Alieve/blacklisted-classes/V0.cxx diff --git a/EVE/Alieve/V0.h b/EVE/Alieve/blacklisted-classes/V0.h similarity index 100% rename from EVE/Alieve/V0.h rename to EVE/Alieve/blacklisted-classes/V0.h diff --git a/EVE/Alieve/V0Editors.cxx b/EVE/Alieve/blacklisted-classes/V0Editors.cxx similarity index 100% rename from EVE/Alieve/V0Editors.cxx rename to EVE/Alieve/blacklisted-classes/V0Editors.cxx diff --git a/EVE/Alieve/V0Editors.h b/EVE/Alieve/blacklisted-classes/V0Editors.h similarity index 100% rename from EVE/Alieve/V0Editors.h rename to EVE/Alieve/blacklisted-classes/V0Editors.h diff --git a/EVE/Reve/.SKEL-ged.cxx b/EVE/Reve/.SKEL-ged.cxx deleted file mode 100644 index a9bde8f162f..00000000000 --- a/EVE/Reve/.SKEL-ged.cxx +++ /dev/null @@ -1,58 +0,0 @@ -// $Header$ - -#include "CLASS.h" -#include - -#include -#include - -#include -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// CLASS -// - -ClassImp(CLASS) - -CLASS::CLASS(const TGWindow *p, Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - fM(0) - // Initialize widget pointers to 0 -{ - MakeTitle("STEM"); - - // Create widgets - // fXYZZ = new TGSomeWidget(this, ...); - // AddFrame(fXYZZ, new TGLayoutHints(...)); - // fXYZZ->Connect("SignalName()", "Reve::CLASS", this, "DoXYZZ()"); -} - -CLASS::~CLASS() -{} - -/**************************************************************************/ - -void CLASS::SetModel(TObject* obj) -{ - fM = dynamic_cast(obj); - - // Set values of widgets - // fXYZZ->SetValue(fM->GetXYZZ()); -} - -/**************************************************************************/ - -// Implements callback/slot methods - -// void CLASS::DoXYZZ() -// { -// fM->SetXYZZ(fXYZZ->GetValue()); -// Update(); -// } diff --git a/EVE/Reve/.SKEL-ged.h b/EVE/Reve/.SKEL-ged.h deleted file mode 100644 index 3419a9f5f34..00000000000 --- a/EVE/Reve/.SKEL-ged.h +++ /dev/null @@ -1,43 +0,0 @@ -// $Header$ - -#ifndef REVE_CLASS_H -#define REVE_CLASS_H - -#include - -class TGButton; -class TGCheckButton; -class TGNumberEntry; -class TGColorSelect; - -namespace Reve { - -class STEM; - -class CLASS : public TGedFrame -{ -private: - CLASS(const CLASS&); // Not implemented - CLASS& operator=(const CLASS&); // Not implemented - -protected: - STEM* fM; // fModel dynamic-casted to CLASS - - // Declare widgets - // TGSomeWidget* fXYZZ; - -public: - CLASS(const TGWindow* p=0, Int_t width=170, Int_t height=30, UInt_t options = kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - virtual ~CLASS(); - - virtual void SetModel(TObject* obj); - - // Declare callback/slot methods - // void DoXYZZ(); - - ClassDef(CLASS, 0); // Editor for STEM -}; // endclass CLASS - -} - -#endif diff --git a/EVE/Reve/.SKEL-gedsubed.cxx b/EVE/Reve/.SKEL-gedsubed.cxx deleted file mode 100644 index 6d45c7a2a2f..00000000000 --- a/EVE/Reve/.SKEL-gedsubed.cxx +++ /dev/null @@ -1,98 +0,0 @@ -// $Header$ - -#include "CLASS.h" -#include - -#include -#include - -#include -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// XXCLASS -// -// - -ClassImp(XXCLASS) - -//______________________________________________________________________ -XXCLASS::XXCLASS(const TGWindow *p) : - TGVerticalFrame(p), - fM (0) -{ - // Constructor. -} - -//______________________________________________________________________ -void XXCLASS::SetModel(STEM* m) -{ - // Set model object. - - fM = m; -} - -//______________________________________________________________________ -void XXCLASS::Changed() -{ - // Emit Changed signal. - - Emit("Changed()"); -} - -//______________________________________________________________________ -//void XXCLASS::DoABCD() -//{ -// // Set some value from some widget -// Changed(); -//} - - -//______________________________________________________________________ -// CLASS -// -// - -ClassImp(CLASS) - -//______________________________________________________________________ -CLASS::CLASS(const TGWindow *p, Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - fM (0), - fSE (0) -{ - // Constructor. - - MakeTitle("STEM"); - - fSE = new XXCLASS(this); - AddFrame(fSE, new TGLayoutHints(kLHintsTop, 2, 0, 2, 2)); - fSE->Connect("Changed()", "CLASS", this, "Update()"); -} - -/**************************************************************************/ - -//______________________________________________________________________ -void CLASS::SetModel(TObject* obj) -{ - // Set model object. - fM = dynamic_cast(obj); - fSE->SetModel(fM); -} - -/**************************************************************************/ - -// Implements callback/slot methods - -//______________________________________________________________________ -// void CLASS::DoXYZZ() -// { -// fM->SetXYZZ(fXYZZ->GetValue()); -// Update(); -// } diff --git a/EVE/Reve/.SKEL-gedsubed.h b/EVE/Reve/.SKEL-gedsubed.h deleted file mode 100644 index 5e2ef1c039e..00000000000 --- a/EVE/Reve/.SKEL-gedsubed.h +++ /dev/null @@ -1,63 +0,0 @@ -// $Header$ - -#ifndef REVE_CLASS_H -#define REVE_CLASS_H - -#include - -class TGButton; -class TGCheckButton; -class TGNumberEntry; -class TGColorSelect; - -namespace Reve { - -class STEM; - -class XXCLASS : public TGVerticalFrame -{ -private: - XXCLASS(const XXCLASS&); // Not implemented - XXCLASS& operator=(const XXCLASS&); // Not implemented - -protected: - STEM *fM; - -public: - XXCLASS(const TGWindow* p); - virtual ~XXCLASS() {} - - void SetModel(STEM* m); - - void Changed(); //*SIGNAL* - - // void DoABCD(); - - ClassDef(XXCLASS, 0) // Sub-editor for STEM -}; - - -class CLASS : public TGedFrame -{ -private: - CLASS(const CLASS&); // Not implemented - CLASS& operator=(const CLASS&); // Not implemented - -protected: - STEM *fM; // fModel dynamic-casted to STEM - XXCLASS *fSE; - -public: - CLASS(const TGWindow* p=0, Int_t width=170, Int_t height=30, UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - virtual ~CLASS() {} - - virtual void SetModel(TObject* obj); - - void DoXYZZ(); - - ClassDef(CLASS, 0) // Editor for STEM -}; - -} - -#endif diff --git a/EVE/Reve/.SKEL-gl.cxx b/EVE/Reve/.SKEL-gl.cxx deleted file mode 100644 index 0ec5a21a7f2..00000000000 --- a/EVE/Reve/.SKEL-gl.cxx +++ /dev/null @@ -1,47 +0,0 @@ -// $Header$ - -#include "CLASS.h" -#include - -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// CLASS -// - -ClassImp(CLASS) - -CLASS::CLASS() : TGLObject(), fM(0) -{ - // fDLCache = kFALSE; // Disable display list. -} - -CLASS::~CLASS() -{} - -/**************************************************************************/ - -Bool_t CLASS::SetModel(TObject* obj, const Option_t* /*opt*/) -{ - if(SetModelCheckClass(obj, STEM::Class())) { - fM = dynamic_cast(obj); - return kTRUE; - } - return kFALSE; -} - -void CLASS::SetBBox() -{ - // !! This ok if master sub-classed from TAttBBox - SetAxisAlignedBBox(((STEM*)fExternalObj)->AssertBBox()); -} - -/**************************************************************************/ - -void CLASS::DirectDraw(TGLRnrCtx & rnrCtx) const -{ - // printf("CLASS::DirectDraw Style %d, LOD %d\n", flags.Style(), flags.LOD()); -} diff --git a/EVE/Reve/.SKEL-gl.h b/EVE/Reve/.SKEL-gl.h deleted file mode 100644 index 73bbfa6a9b3..00000000000 --- a/EVE/Reve/.SKEL-gl.h +++ /dev/null @@ -1,42 +0,0 @@ -// $Header$ - -#ifndef REVE_CLASS_H -#define REVE_CLASS_H - -#include - -class TGLViewer; -class TGLScene; - -namespace Reve { - -class STEM; - -class CLASS : public TGLObject -{ -private: - CLASS(const CLASS&); // Not implemented - CLASS& operator=(const CLASS&); // Not implemented - -protected: - STEM* fM; // fModel dynamic-casted to CLASS - - virtual void DirectDraw(TGLRnrCtx & rnrCtx) const; - -public: - CLASS(); - virtual ~CLASS(); - - virtual Bool_t SetModel(TObject* obj, const Option_t* opt=0); - virtual void SetBBox(); - - // To support two-level selection - // virtual Bool_t SupportsSecondarySelect() const { return kTRUE; } - // virtual void ProcessSelection(TGLRnrCtx & rnrCtx, TGLSelectRecord & rec); - - ClassDef(CLASS, 0); -}; // endclass CLASS - -} - -#endif diff --git a/EVE/Reve/.SKEL.cxx b/EVE/Reve/.SKEL.cxx deleted file mode 100644 index 10107710010..00000000000 --- a/EVE/Reve/.SKEL.cxx +++ /dev/null @@ -1,16 +0,0 @@ -// $Header$ - -#include "CLASS.h" - -using namespace Reve; - -//______________________________________________________________________ -// CLASS -// - -ClassImp(CLASS) - -CLASS::CLASS() -{ - -} diff --git a/EVE/Reve/.SKEL.h b/EVE/Reve/.SKEL.h deleted file mode 100644 index e14f77b6284..00000000000 --- a/EVE/Reve/.SKEL.h +++ /dev/null @@ -1,29 +0,0 @@ -// $Header$ - -#ifndef REVE_CLASS_H -#define REVE_CLASS_H - -#include - -#include - -namespace Reve { - -class CLASS -{ -private: - CLASS(const CLASS&); // Not implemented - CLASS& operator=(const CLASS&); // Not implemented - -protected: - -public: - CLASS(); - virtual ~CLASS() {} - - ClassDef(CLASS, 1); -}; // endclass CLASS - -} - -#endif diff --git a/EVE/Reve/BoxSet.cxx b/EVE/Reve/BoxSet.cxx deleted file mode 100644 index 0d67a17d4ca..00000000000 --- a/EVE/Reve/BoxSet.cxx +++ /dev/null @@ -1,239 +0,0 @@ -// $Header$ - -#include "BoxSet.h" -#include -#include -#include -#include -#include - -using namespace Reve; - - -//______________________________________________________________________________ -// BoxSet -// -// A collection of 3D-boxes. The way how the boxes are defined depends -// on the fBoxType data-member. -// BT_FreeBox arbitrary box: specify 8*(x,y,z) box corners -// BT_AABox axis-aligned box: specify (x,y,z) and (w, h, d) -// BT_AABoxFixedDim axis-aligned box w/ fixed dimensions: specify (x,y,z) -// also set fDefWidth, fDefHeight and fDefDepth -// -// Each box can be assigned: -// a) Color or signal value. Thresholds and signal-to-color mapping -// can then be set dynamically via the RGBAPalette class. -// b) External TObject* (stored as TRef). -// -// See also base-class DigitSet for more information. - -ClassImp(BoxSet) - -//______________________________________________________________________________ -BoxSet::BoxSet(const Text_t* n, const Text_t* t) : - DigitSet (n, t), - - fBoxType (BT_Undef), - fDefWidth (1), - fDefHeight (1), - fDefDepth (1) -{ - // Constructor. - - // Override from DigitSet. - fDisableLigting = kFALSE; -} - -/******************************************************************************/ - -//______________________________________________________________________________ -Int_t BoxSet::SizeofAtom(BoxSet::BoxType_e bt) -{ - // Return size of data-structure describing a box of type bt. - - static const Exc_t eH("BoxSet::SizeofAtom "); - - switch (bt) { - case BT_Undef: return 0; - case BT_FreeBox: return sizeof(BFreeBox); - case BT_AABox: return sizeof(BAABox); - case BT_AABoxFixedDim: return sizeof(BAABoxFixedDim); - default: throw(eH + "unexpected atom type."); - } - return 0; -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void BoxSet::Reset(BoxSet::BoxType_e boxType, Bool_t valIsCol, Int_t chunkSize) -{ - // Reset the data containers to zero size. - // The arguments describe the basic parameters of data storage. - - fBoxType = boxType; - fValueIsColor = valIsCol; - fDefaultValue = valIsCol ? 0 : kMinInt; - if (fOwnIds) - ReleaseIds(); - fPlex.Reset(SizeofAtom(fBoxType), chunkSize); -} - -//______________________________________________________________________________ -void BoxSet::Reset() -{ - // Reset the data containers to zero size. - // Keep the old data-storage parameters. - - if (fOwnIds) - ReleaseIds(); - fPlex.Reset(SizeofAtom(fBoxType), TMath::Max(fPlex.N(), 64)); -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void BoxSet::AddBox(const Float_t* verts) -{ - // Create a new box from a set of 8 vertices. - // To be used for box-type BT_FreeBox. - - static const Exc_t eH("BoxSet::AddBox "); - - if (fBoxType != BT_FreeBox) - throw(eH + "expect free box-type."); - - BFreeBox* b = (BFreeBox*) NewDigit(); - memcpy(b->fVertices, verts, sizeof(b->fVertices)); -} - -//______________________________________________________________________________ -void BoxSet::AddBox(Float_t a, Float_t b, Float_t c, Float_t w, Float_t h, Float_t d) -{ - // Create a new axis-aligned box from at a given position and with - // specified dimensions. - // To be used for box-type BT_AABox. - - static const Exc_t eH("BoxSet::AddBox "); - - if (fBoxType != BT_AABox) - throw(eH + "expect axis-aligned box-type."); - - BAABox* box = (BAABox*) NewDigit(); - box->fA = a; box->fB = b; box->fC = c; - box->fW = w; box->fH = h; box->fD = d; -} - -//______________________________________________________________________________ -void BoxSet::AddBox(Float_t a, Float_t b, Float_t c) -{ - // Create a new axis-aligned box from at a given position. - // To be used for box-type BT_AABoxFixedDim. - - static const Exc_t eH("BoxSet::AddBox "); - - if (fBoxType != BT_AABoxFixedDim) - throw(eH + "expect axis-aligned fixed-dimension box-type."); - - BAABoxFixedDim* box = (BAABoxFixedDim*) NewDigit(); - box->fA = a; box->fB = b; box->fC = c; -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void BoxSet::ComputeBBox() -{ - // Fill bounding-box information of the base-class TAttBBox (virtual method). - // If member 'FrameBox* fFrame' is set, frame's corners are used as bbox. - - static const Exc_t eH("BoxSet::ComputeBBox "); - - if (fFrame != 0) - { - BBoxInit(); - Int_t n = fFrame->GetFrameSize() / 3; - Float_t *bbps = fFrame->GetFramePoints(); - for (int i=0; i - -class TGeoMatrix; -class TRandom; - -namespace Reve { - -class BoxSet: public DigitSet -{ - friend class BoxSetGL; - - BoxSet(const BoxSet&); // Not implemented - BoxSet& operator=(const BoxSet&); // Not implemented - -public: - enum BoxType_e - { - BT_Undef, // unknown-ignored - BT_FreeBox, // arbitrary box: specify 8*(x,y,z) box corners - BT_AABox, // axis-aligned box: specify (x,y,z) and (w, h, d) - BT_AABoxFixedDim // axis-aligned box w/ fixed dimensions: specify (x,y,z) - }; - -protected: - - struct BFreeBox : public DigitBase { Float_t fVertices[24]; }; - - struct BOrigin : public DigitBase { Float_t fA, fB, fC; }; - - struct BAABox : public BOrigin { Float_t fW, fH, fD; }; - - struct BAABoxFixedDim : public BOrigin {}; - -protected: - BoxType_e fBoxType; // Type of rendered box. - - Float_t fDefWidth; // Breadth assigned to first coordinate (A). - Float_t fDefHeight; // Breadth assigned to second coordinate (B). - Float_t fDefDepth; // Breadth assigned to third coordinate (C). - - static Int_t SizeofAtom(BoxType_e bt); - -public: - BoxSet(const Text_t* n="BoxSet", const Text_t* t=""); - virtual ~BoxSet() {} - - void Reset(BoxType_e boxType, Bool_t valIsCol, Int_t chunkSize); - void Reset(); - - void AddBox(const Float_t* verts); - void AddBox(Float_t a, Float_t b, Float_t c, Float_t w, Float_t h, Float_t d); - void AddBox(Float_t a, Float_t b, Float_t c); - - virtual void ComputeBBox(); - // virtual void Paint(Option_t* option = ""); - - void Test(Int_t nboxes); - - Float_t GetDefWidth() const { return fDefWidth; } - Float_t GetDefHeight() const { return fDefHeight; } - Float_t GetDefDepth() const { return fDefDepth; } - - void SetDefWidth(Float_t v) { fDefWidth = v ; } - void SetDefHeight(Float_t v) { fDefHeight = v ; } - void SetDefDepth(Float_t v) { fDefDepth = v ; } - - ClassDef(BoxSet, 1); // Visual class showing a set of boxes. -}; // endclass BoxSet - -} - -#endif diff --git a/EVE/Reve/BoxSetGL.cxx b/EVE/Reve/BoxSetGL.cxx deleted file mode 100644 index 0a796886a15..00000000000 --- a/EVE/Reve/BoxSetGL.cxx +++ /dev/null @@ -1,344 +0,0 @@ -// $Header$ - -#include "BoxSetGL.h" -#include - -#include -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________________ -// BoxSetGL -// -// A GL rendering class for BoxSet. -// - -ClassImp(BoxSetGL) - -//______________________________________________________________________________ -BoxSetGL::BoxSetGL() : fM(0), fBoxDL(0) -{ - // Default constructor. - - // fDLCache = false; // Disable display list. -} - -//______________________________________________________________________________ -BoxSetGL::~BoxSetGL() -{ - // Destructor. Noop. -} - -/**************************************************************************/ -// Protected methods -/**************************************************************************/ - -//______________________________________________________________________________ -Int_t BoxSetGL::PrimitiveType() const -{ - // Return GL primitive used to render the boxes, based on the - // render-mode specified in the model object. - - return (fM->fRenderMode != DigitSet::RM_Line) ? GL_QUADS : GL_LINE_LOOP; -} - -//______________________________________________________________________________ -inline Bool_t BoxSetGL::SetupColor(const DigitSet::DigitBase& q) const -{ - // Set GL color for given primitive. - - if (fM->fValueIsColor) - { - glColor4ubv((UChar_t*) & q.fValue); - return kTRUE; - } - else - { - UChar_t c[4]; - Bool_t visible = fM->fPalette->ColorFromValue(q.fValue, fM->fDefaultValue, c); - if (visible) - glColor4ubv(c); - return visible; - } -} - -//______________________________________________________________________________ -void BoxSetGL::MakeOriginBox(Float_t p[24], Float_t dx, Float_t dy, Float_t dz) const -{ - // Fill array p to represent a box (0,0,0) - (dx,dy,dz). - - // bottom - p[0] = 0; p[1] = dy; p[2] = 0; p += 3; - p[0] = dx; p[1] = dy; p[2] = 0; p += 3; - p[0] = dx; p[1] = 0; p[2] = 0; p += 3; - p[0] = 0; p[1] = 0; p[2] = 0; p += 3; - // top - p[0] = 0; p[1] = dy; p[2] = dz; p += 3; - p[0] = dx; p[1] = dy; p[2] = dz; p += 3; - p[0] = dx; p[1] = 0; p[2] = dz; p += 3; - p[0] = 0; p[1] = 0; p[2] = dz; -} - -//______________________________________________________________________________ -inline void BoxSetGL::RenderBox(const Float_t p[24]) const -{ - // Render a box specified by points in array p. - - // bottom: 0123 - glNormal3f(0, 0, -1); - glVertex3fv(p); glVertex3fv(p + 3); - glVertex3fv(p + 6); glVertex3fv(p + 9); - // top: 7654 - glNormal3f(0, 0, 1); - glVertex3fv(p + 21); glVertex3fv(p + 18); - glVertex3fv(p + 15); glVertex3fv(p + 12); - // back: 0451 - glNormal3f(0, 1, 0); - glVertex3fv(p); glVertex3fv(p + 12); - glVertex3fv(p + 15); glVertex3fv(p + 3); - // front: 3267 - glNormal3f(0, -1, 0); - glVertex3fv(p + 9); glVertex3fv(p + 6); - glVertex3fv(p + 18); glVertex3fv(p + 21); - // left: 0374 - glNormal3f(-1, 0, 0); - glVertex3fv(p); glVertex3fv(p + 9); - glVertex3fv(p + 21); glVertex3fv(p + 12); - // right: 1562 - glNormal3f(1, 0, 0); - glVertex3fv(p + 3); glVertex3fv(p + 15); - glVertex3fv(p + 18); glVertex3fv(p + 6); -} - -//______________________________________________________________________________ -void BoxSetGL::MakeDisplayList() const -{ - // Create a display-list for rendering a single box, based on the - // current box-type. - // Some box-types don't benefit from the display-list rendering and - // so display-list is not created. - - if (fM->fBoxType == BoxSet::BT_AABox || - fM->fBoxType == BoxSet::BT_AABoxFixedDim) - { - if (fBoxDL == 0) - fBoxDL = glGenLists(1); - - Float_t p[24]; - if (fM->fBoxType == BoxSet::BT_AABox) - MakeOriginBox(p, 1.0f, 1.0f, 1.0f); - else - MakeOriginBox(p, fM->fDefWidth, fM->fDefHeight, fM->fDefDepth); - - glNewList(fBoxDL, GL_COMPILE); - glBegin(PrimitiveType()); - RenderBox(p); - glEnd(); - glEndList(); - } -} - -/**************************************************************************/ -// Virtuals from base-classes -/**************************************************************************/ - -//______________________________________________________________________________ -Bool_t BoxSetGL::ShouldDLCache(const TGLRnrCtx & rnrCtx) const -{ - // Determines if display-list will be used for rendering. - // Virtual from TGLLogicalShape. - - MakeDisplayList(); - - if (rnrCtx.DrawPass() == TGLRnrCtx::kPassOutlineLine) - return kFALSE; - return TGLObject::ShouldDLCache(rnrCtx); -} - -//______________________________________________________________________________ -void BoxSetGL::DLCacheDrop() -{ - // Called when display lists have been destroyed externally and the - // internal display-list data needs to be cleare. - // Virtual from TGLLogicalShape. - - fBoxDL = 0; - TGLObject::DLCacheDrop(); -} - -//______________________________________________________________________________ -void BoxSetGL::DLCachePurge() -{ - // Called when display-lists need to be returned to the system. - // Virtual from TGLLogicalShape. - - static const Exc_t eH("BoxSetGL::DLCachePurge "); - - if (fBoxDL == 0) return; - if (fScene) - { - fScene->GetGLCtxIdentity()->RegisterDLNameRangeToWipe(fBoxDL, 1); - } - else - { - Warning(eH, "Scene unknown, attempting direct deletion."); - glDeleteLists(fBoxDL, 1); - } - TGLObject::DLCachePurge(); -} - -/**************************************************************************/ - -//______________________________________________________________________________ -Bool_t BoxSetGL::SetModel(TObject* obj, const Option_t* /*opt*/) -{ - // Set model object. - // Virtual from TGLObject. - - Bool_t isok = SetModelCheckClass(obj, Reve::BoxSet::Class()); - fM = isok ? dynamic_cast(obj) : 0; - return isok; -} - -//______________________________________________________________________________ -void BoxSetGL::SetBBox() -{ - // Fill the bounding-box data of the logical-shape. - // Virtual from TGLObject. - - SetAxisAlignedBBox(fM->AssertBBox()); -} - -//______________________________________________________________________________ -void BoxSetGL::DirectDraw(TGLRnrCtx & rnrCtx) const -{ - // Actual rendering code. - // Virtual from TGLLogicalShape. - - static const Exc_t eH("BoxSetGL::DirectDraw "); - - if (rnrCtx.DrawPass() == TGLRnrCtx::kPassOutlineLine) - return; - - BoxSet& mB = * fM; - // printf("BoxSetGL::DirectDraw N boxes %d\n", mB.fPlex.Size()); - if(mB.fPlex.Size() == 0) - return; - - glPushAttrib(GL_ENABLE_BIT | GL_POLYGON_BIT); - glColorMaterial(GL_FRONT_AND_BACK, GL_DIFFUSE); - glEnable(GL_COLOR_MATERIAL); - - if (mB.fRenderMode == DigitSet::RM_Fill) - glPolygonMode(GL_FRONT_AND_BACK, GL_FILL); - else if (mB.fRenderMode == DigitSet::RM_Line) - glPolygonMode(GL_FRONT_AND_BACK, GL_LINE); - - if (mB.fDisableLigting) glDisable(GL_LIGHTING); - - if (rnrCtx.SecSelection()) glPushName(0); - - Int_t boxSkip = 0; - if (rnrCtx.ShapeLOD() < 50) - boxSkip = 6 - (rnrCtx.ShapeLOD()+1)/10; - - VoidCPlex::iterator bi(mB.fPlex); - - switch (mB.fBoxType) - { - - case BoxSet::BT_FreeBox: - { - GLenum primitiveType = PrimitiveType(); - while (bi.next()) - { - BoxSet::BFreeBox& b = * (BoxSet::BFreeBox*) bi(); - if (SetupColor(b)) - { - if (rnrCtx.SecSelection()) glLoadName(bi.index()); - glBegin(primitiveType); - RenderBox(b.fVertices); - glEnd(); - } - if (boxSkip) { Int_t s = boxSkip; while (s--) bi.next(); } - } - break; - } // end case free-box - - case BoxSet::BT_AABox: - { - glEnable(GL_NORMALIZE); - while (bi.next()) - { - BoxSet::BAABox& b = * (BoxSet::BAABox*) bi(); - if (SetupColor(b)) - { - if (rnrCtx.SecSelection()) glLoadName(bi.index()); - glPushMatrix(); - glTranslatef(b.fA, b.fB, b.fC); - glScalef (b.fW, b.fH, b.fD); - glCallList(fBoxDL); - glPopMatrix(); - } - if (boxSkip) { Int_t s = boxSkip; while (s--) bi.next(); } - } - break; - } - - case BoxSet::BT_AABoxFixedDim: - { - while (bi.next()) - { - BoxSet::BAABoxFixedDim& b = * (BoxSet::BAABoxFixedDim*) bi(); - if (SetupColor(b)) - { - if (rnrCtx.SecSelection()) glLoadName(bi.index()); - glTranslatef(b.fA, b.fB, b.fC); - glCallList(fBoxDL); - glTranslatef(-b.fA, -b.fB, -b.fC); - } - if (boxSkip) { Int_t s = boxSkip; while (s--) bi.next(); } - } - break; - } - - default: - { - throw(eH + "unsupported box-type."); - } - - } // end switch box-type - - if (rnrCtx.SecSelection()) glPopName(); - - glPopAttrib(); -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void BoxSetGL::ProcessSelection(TGLRnrCtx & /*rnrCtx*/, TGLSelectRecord & rec) -{ - // Processes secondary selection from TGLViewer. - // Calls TPointSet3D::PointSelected(Int_t) with index of selected - // point as an argument. - - if (rec.GetN() < 2) return; - fM->DigitSelected(rec.GetItem(1)); -} - -//______________________________________________________________________________ -void BoxSetGL::Render(TGLRnrCtx & rnrCtx) -{ - // Interface for direct rendering from classes that include BoxSet - // as a member. - - MakeDisplayList(); - DirectDraw(rnrCtx); - glDeleteLists(fBoxDL, 1); - fBoxDL = 0; -} diff --git a/EVE/Reve/BoxSetGL.h b/EVE/Reve/BoxSetGL.h deleted file mode 100644 index 4676876b8f7..00000000000 --- a/EVE/Reve/BoxSetGL.h +++ /dev/null @@ -1,50 +0,0 @@ -// $Header$ - -#ifndef REVE_BoxSetGL_H -#define REVE_BoxSetGL_H - -#include -#include - -namespace Reve { - -class BoxSetGL : public TGLObject -{ - BoxSetGL(const BoxSetGL&); // Not implemented - BoxSetGL& operator=(const BoxSetGL&); // Not implemented - -protected: - BoxSet* fM; // Model object. - - mutable UInt_t fBoxDL; // Display-list id for a box atom. - - virtual void DirectDraw(TGLRnrCtx & rnrCtx) const; - - Int_t PrimitiveType() const; - Bool_t SetupColor(const DigitSet::DigitBase& q) const; - void MakeOriginBox(Float_t p[24], Float_t dx, Float_t dy, Float_t dz) const; - void RenderBox(const Float_t p[24]) const; - void MakeDisplayList() const; - -public: - BoxSetGL(); - virtual ~BoxSetGL(); - - virtual Bool_t ShouldDLCache(const TGLRnrCtx & rnrCtx) const; - virtual void DLCacheDrop(); - virtual void DLCachePurge(); - - virtual Bool_t SetModel(TObject* obj, const Option_t* opt=0); - virtual void SetBBox(); - - virtual Bool_t SupportsSecondarySelect() const { return kTRUE; } - virtual void ProcessSelection(TGLRnrCtx & rnrCtx, TGLSelectRecord & rec); - - virtual void Render(TGLRnrCtx & rnrCtx); - - ClassDef(BoxSetGL, 0); // GL rendering class for BoxSet. -}; // endclass BoxSetGL - -} - -#endif diff --git a/EVE/Reve/ChangeLog b/EVE/Reve/ChangeLog deleted file mode 100644 index 32737761457..00000000000 --- a/EVE/Reve/ChangeLog +++ /dev/null @@ -1,2638 +0,0 @@ -2007-12-17 Alja Mrak-Tadel - - * PointSet.cxx: - * PointSet.h: - Inherits from TQObject and emits signal PointCtrlClicked(). - - * Track.cxx: - * Track.h: - Move inheritance of TQObject to PointSet. Add to pop-up menu - ability to print track parameters. - -2007-11-20 Alja Mrak-Tadel - - * NLTBases.cxx: - * NLTBases.h: - * NLTProjectorEditor.cxx: - * NLTProjectorEditor.h: - Add some docs. - - * NLTProjections.cxx: - * NLTProjections.h: - * NLTProjector.cxx: - * NLTProjector.h: - Put projections classes to new files. - -2007-11-19 Matevz Tadel - - * BoxSet.cxx: - * GridStepper.cxx: - * GridStepper.h: - * GridStepperEditor.h: - * LineEditor.h: - * LinkDef.h: - * NLTProjector.cxx: - * NLTProjector.h: - * NLTProjector.cxx: - * PODs.h: - * Pad.cxx: - * Pad.h: - * Plex.h: - * PointSet.cxx: - * PointSet.h: - * PointSetArrayEditor.cxx: - * PointSetArrayEditor.h: - * RGBAPalette.h: - * RGBAPaletteEditor.h: - * RenderElement.cxx: - * RenderElement.h: - * ReveManager.cxx: - * ReveManager.h: - * Scene.h: - * SceneInfo.h: - * StraightLineSet.h: - * Track.cxx: - * Track.h: - * TriangleSet.cxx: - * TriangleSet.h: - * TriangleSetEditor.h: - * TriangleSetGL.cxx: - * TriangleSetGL.h: - * Viewer.h: - * ZTransEditor.h: - Add some class docs. - -2007-11-19 Alja Mrak-Tadel - - * LinkDef.h: - Rename class RhoZ and CircularFishEye to NLTRhoZ and NLTCircularFishEye. - - * NLTProjector.cxx: - * NLTProjector.h: - Document members and functions. - -2007-11-09 Matevz Tadel - - * Track.cxx: - * Track.h: - Fix update propagation from TrackRnrStyle::MakeTracks(). - Fix handling of ctx-menu functions. - - * TrackEditors.cxx: - * TrackRnrStyleEditor.cxx: - * TrackRnrStyleEditor.h: - Add some class-docs. - -2007-11-08 Matevz Tadel - - * Reve.cxx: - Rewrite Exc_t operator+ variants. - - * Track.cxx: - * Track.h: - Added comments required by coding conventions. - Add context-menu functions TrackList::FindTrackByLabel/Index(). - Use mMinInt for unset label/index. - Handle negative label according to ALICE convention. - -2007-11-08 Alja Mrak-Tadel - - * NLTProjector.cxx: - Bugfix: in GetValForScreenPos() check if distortion exist before checking - the limit. - -2007-11-07 Matevz Tadel - - * BoxSet.cxx: - * BoxSet.h: - * BoxSetGL.cxx: - * BoxSetGL.h: - * DigitSet.cxx: - * DigitSet.h: - * DigitSetEditor.cxx: - * DigitSetEditor.h: - Added comments required by coding conventions. - -2007-11-07 Matevz Tadel - - * LinkDef.h: - Removed entries for Cascade and V0 classes. - - * Cascade.cxx: - * Cascade.h: - * CascadeEditors.cxx: - * CascadeEditors.h: - * V0.cxx: - * V0.h: - * V0Editors.cxx: - * V0Editors.h: - Moved to Alieve. - -2007-11-06 Alja Mrak-Tadel - - * GeoNode.cxx: - * GeoNode.h: - Implement load/save of GeoNodeRnrEl and GeoShapeRnrEl. GeoNodeRnrEl - is no longer NLTProjectable. - - * LinkDef.h: - Remove common base class for GeoNodeRnrEl and GeoShapeRnrEl. - - * NLTPolygonSet.cxx: - Move NLTProjectale class from GeoRnrEl to GeoShapeRnrEl. - - * NLTProjector.cxx: - * NLTProjector.h: - * NLTProjectorGL.cxx: - * NLTProjectorGL.h: - Check if projected value is in the limit. - - * NLTProjectorEditor.cxx: - Change range for number of tick-mark. - -2007-11-06 Matevz Tadel - - * NLTBases.cxx: - * NLTTrackGL.cxx: - * PODs.h: - Comments, grayspace. - - * NLTTrack.cxx: - * NLTTrack.h: - * Track.cxx: - * Track.h: - Original track's path marks were copied to the projected track in - Track::SetTrackParams(). This caused duplication of track-lines - and occasional crashes during event navigation. - Comments, grayspace. - -2007-11-01 Matevz Tadel - - * RGValuators.cxx: - * TrackRnrStyleEditor.cxx: - From Bertrand: Windows fixes. - -2007-10-23 Alja Mrak-Tadel - - * GeoNode.cxx: - * GeoNode.h: - * LinkDef.h: - * NLTBases.cxx: - * NLTBases.h: - Move implementation of NLTProjectable class for geometry into GeoNode - files. - - * NLTTrack.cxx: - Fix bug in GetBreakPoint(). Check segments on projected points. - - * NLTPolygonSet.cxx: - * NLTPolygonSet.h: - * NLTPolygonSetGL.cxx: - * NLTProjector.cxx: - * NLTProjector.h: - * NLTProjectorEditor.cxx: - * NLTProjectorEditor.h: - * NLTProjectorGL.cxx: - * NLTTrack.cxx: - Set center of NLTProjection. - - * PODs.h: - Add function for scalar product in vector. - - * StraightLineSet.cxx: - In UpdateProjection() fix bug => translate point according to - transformation matrix. - -2007-10-22 Matevz Tadel - - * Viewer.cxx: - Modify defaults for otho-camera (disable rotations). - -2007-10-16 Matevz Tadel - - EVE-dev - - * Line.cxx: - * Line.h: - * PointSet.cxx: - * PointSet.h: - * TTreeTools.cxx: - * TTreeTools.h: - Add support for optional integer ids for every point in a - PointSet. Can also be filled via TPointSelector. - Remove obsolete constructor from PointSet and Line. - - * Track.cxx: - Merge from EVE-head-after-merge to HEAD. - -2007-10-10 Alja Mrak-Tadel - - * NLTProjector.cxx: - * NLTProjector.h: - * NLTProjectorGL.cxx: - * NLTProjectorEditor.cxx: - * NLTProjectorEditor.h: - Set NLTProjection name according to projection type and - distortion. Use fAxisColor instead of RenderElement::fMainColor. - -2007-10-05 Matevz Tadel - - EVE-dev - - * RGeoNodeEditors.cxx: - * RGeoNodeEditors.h: - * GeoNodeEditor.cxx: - * GeoNodeEditor.h: - Rename inconsistently named file RGeoNodeEditors to - GeoNodeEditor. - - * RGTopFrame.cxx: - * RGTopFrame.h: - * ReveManager.cxx: - * ReveManager.h: - * Cascade.cxx: - * DigitSet.cxx: - * GeoNode.cxx: - * LinkDef.h: - * NLTProjector.cxx: - * PointSet.cxx: - * QuadSet.cxx: - * RGBrowser.cxx: - * RGBrowser.h: - * RGEditor.cxx: - * RenderElement.cxx: - * RenderElement.h: - * Scene.cxx: - * SceneInfo.cxx: - * Track.cxx: - * TrackEditors.cxx: - * TrackRnrStyleEditor.cxx: - * TriangleSet.cxx: - * V0.cxx: - * VSDSelector.cxx: - * Viewer.cxx: - * reve_main/reve_main.cxx: - Renamed class RGTopFrame to ReveManager. - -2007-10-04 Matevz Tadel - - EVE-dev - - * BoxSetGL.cxx: - Make box face-normals and face-orientations consistent. - -2007-10-04 Matevz Tadel - - EVE-dev - - * GeoNode.cxx: - For class GeoShapeRnrEl: - Add missing call to ElementChanged() in ImportShapeExtract(). - Properly handle fHMTrans::UseTrans. - - * TGeoShapeExtract.cxx: - * TGeoShapeExtract.h: - Add setters and AddElement() method to allow creation of ad hoc - shape collections. - -2007-10-03 Matevz Tadel - - EVE-dev - - * BoxSetGL.cxx: - Progressively skip more and more boxes at lower levels of detail. - -2007-10-03 Matevz Tadel - - EVE-dev - - * EventBase.h: - Fix compilation warning. - - * MCHelixLine.hi: - Include cassert, needed by gcc-4.1. - - * RGEditor.cxx: - Call RenderElement::ElementChanged() instead of - gReve->RenderElementChanged(). - - * RGeoNodeEditors.cxx: - * RGeoNodeEditors.h: - Use RGValuator for top-node visibility option and level. - Add missing call to Update() for those two callbacks. - -2007-10-02 Matevz Tadel - - EVE-dev - - * DigitSet.cxx: - * DigitSet.h: - * DigitSetEditor.cxx: - * DigitSetEditor.h: - New files: take common digit rendering stuff from QuadSet. - - * QuadSet.cxx: - * QuadSet.h: - Much code moved to DigitSet: this is the new base. - - * QuadSetEditor.cxx: - * QuadSetEditor.h: - Removed files: all done in DigitSetEditor now. - - * QuadSetGL.cxx: - * QuadSetGL.h: - Changes for DigitSet. - Skip rendering in line-pass of outline mode. - - * BoxSet.cxx: - * BoxSet.h: - Inherit from DigitSet. - Implement optimised axis-aligned box modes. - - * BoxSetGL.cxx: - * BoxSetGL.h: - Support new box-modes and secondary-selection. - - * FrameBox.cxx: - * FrameBox.h: - * FrameBoxGL.cxx: - * FrameBoxGL.h: - Add support for background polygon. - - * LinkDef.h: - Add DigitSet and DigitSetEditor. - Remove QuadSetEditor and Box. - - * PointSet.cxx: - * PointSet.h: - Support assignment of external references in PointSetArray. - - * RGBrowser.cxx: - Tried to add HTML browser; apparently the class was not put into - root repository yet, - - * StraightLineSet.cxx: - Effc++ warnings. - -2007-09-19 Matevz Tadel - - EVE-dev - - * EventBase.cxx: - * EventBase.h: - Added empty virtual functions for event-navigation. - Moved new-event-commands list and method from Alieve::Event. - - * RGValuators.cxx: - Do not use GetName() on TGWindow derivatives. - - * Track.cxx: - Added initialization of min/max/lim momentums to the other - TrackList ctor as well. - -2007-09-19 Matevz Tadel - - EVE-dev - - * MCHelixLine.hi: - Properly extrapolate helices to boundaries (needed for - high-momentum tracks). - Added check for near-zero pT (extrapolate as line). - Some code cleanup. - - * RenderElement.cxx: - In SetRnrState() check if update is really necessary. - - * Track.cxx: - * Track.h: - * TrackEditors.cxx: - * TrackEditors.h: - * TrackRnrStyleEditor.cxx: - * TrackRnrStyleEditor.h: - Implement automatic determination of p and pT ranges. - Moved momentum ranges from TrackRnrStyle to TrackList. - -2007-09-10 Matevz Tadel - - EVE-dev - - * TGClassBrowser.cxx: - * TGFileBrowser.cxx: - * TGFileBrowser.h: - * TGNewBrowser.cxx: - * TGNewBrowser.h: - From Bertrand. - - - Removed dependencies on libRIO - - Solved problems when user double-click on different keys - in different opened Root files - - Changed icons size for Root files containing pictures - - Added drawing option combobox - - Added a few main menu entries, allowing to: - - add a new tab with canvas - - add a new tab with editor - - remove a tab element - - execute a plugin by TGFileDialog selection - - Added key shortcuts for these menus entries - - Double-clicking on a .C file opens it in the editor if - the active tab is the editor one, otherwise the default - action will be taken (execute it) - - Properly goes to current (startup) directory at startup - time (open the list tree to the current directory) - - Properly remove menu when closing a tab element - - Temporary remove keys binding on embedded menus - -2007-09-06 Matevz Tadel - - EVE-dev - - * RGBrowser.cxx: - Clarify exception text. - - * RGEditor.cxx: - From Bertrand: use set-method when changing static - TGedFrame::fgFrameCreator (required for windows). - -2007-08-31 Alja Mrak-Tadel - - EVE-dev - - * RenderElement.cxx: - * RenderElement.h: - New virtual GetListTreeIcon(), which sets an icon picture in a list tree. - - * Reve.cxx: - Initialize list tree icons. - - * Scene.h: - * Track.h: - * Viewer.h: - * PointSet.h: - Set specific icons for this class in a list tree. - -2007-08-30 Alja Mrak-Tadel - - * StraightLineSet.cxx: - * StraightLineSet.h: - Handle translation and scale in projected line-set separately. - -2007-08-30 Alja Mrak-Tadel - - EVE-dev - - * NLTProjector.h: - Reindent. - - * NLTProjectorEditor.cxx: - * NLTProjectorEditor.h: - Add RGValuator for current depth. - - * StraightLineSet.cxx: - * StraightLineSet.h: - Use transformation matrix, to scale or move line set. - - * ZTrans.cxx: - * ZTrans.h: - Add multiply function with Float_t* as an argument. - -2007-08-30 Matevz Tadel - - EVE-dev - - * RenderElement.cxx: - * RenderElement.h: - Change DenyDestroy to Int_t, replace Set with Inc/Dec - methods. Fixed zero-ref checks accordingly. - - Symmetrized RemoveElement and RemoveElements with their Local - parts. - - Moved code for list-tree item mgmnt from RGTopFrame to Add/Remove - element methods here. - - * RGTopFrame.cxx: - * RGTopFrame.h: - Moved list-tree item mgmnt from Add/RemoveRenderElement to - appropriate methods in RenderElement. - - Update to new RnrEl::DenyDestroy. - - Added Bool_t fKeepEmptyCont as it is queried by many macros. - - * RGBrowser.cxx: - Update to new RnrEl::DenyDestroy. - - * PointSet.cxx: - * PointSet.h: - * Viewer.cxx: - * Viewer.h: - * Cascade.cxx: - * Cascade.h: - * V0.cxx: - * V0.h: - Update to new RnrEl::RemoveElementLocal, RemoveElementsLocal. - - * NLTBases.cxx: - * NLTBases.h: - Added list fProjectedList to NLTProjectable. - Set of functions to manage it. - Proper management in relevant functions of NLTProjectable and - NTLProjected. - - * NLTTrack.cxx: - * NLTTrack.h: - Forward CtrlClicked() call (from gl sec-selection) to - fProjectable. - - * NLTProjector.cxx: - Set RnrSelf/Children() on imported elements. - - * NLTPolygonSet.cxx: - * NLTPolygonSet.h: - Fix search for duplicate polygons a little. - - * Track.cxx: - * Track.h: - Manage list of projected tracks so that it works in TrackCount. - - * Reve.cxx: - Revert to gled-style check if function is loaded in cint. - -2007-08-30 Matevz Tadel - - EVE-dev - - * TGFileBrowser.cxx: - * TGFileBrowser.h: - From Bertrand. - Override ReallyDelete() so that browser is properly deregistered - from root. - - * TGNewBrowser.cxx: - * TGNewBrowser.h: - From Bertrand. - Move framework specific menus to the left menu-bar. - - * RGBrowser.cxx: - Remove the 'Framework' popup on construction. - Add 'Reve' popup to inherited member fMenuBar. - Added 'New Text Editor' menu entry. - -2007-08-29 Alja Mrak-Tadel - - EVE-dev - - * LinkDef.h: - Register new class NLTSLineSet. - - * StraightLineSet.cxx: - * StraightLineSet.h: - Implement StraightLineSet projected class NLTSLineSet. - - * StraightLineSetGL.cxx: - StraightLineSet inherits from TAttLine. - - * StraightLineSetEditor.cxx: - Editor not friend class of model. Use Getters/Setters. - -2007-08-29 Alja Mrak-Tadel - - EVE-dev - - * NLTProjectorEditor.cxx: - ChangeTGNumberEntry length. - - * Track.cxx: - * Track.h: - Add function in Track to set line and marker attributes from TrackList. - -2007-08-29 Matevz Tadel - - EVE-dev - - * TGClassBrowser.cxx: - * TGClassBrowser.h: - * TGCommandPlugin.cxx: - * TGCommandPlugin.h: - * TGFileBrowser.cxx: - * TGFileBrowser.h: - * TGNewBrowser.cxx: - * TGNewBrowser.h: - New files from Bertrand, somewhat hacked: prototype implementation - of a new root browser. - - * LinkDef.h: - Register new classes TGClassBrowser, TGCommandPlugin, - TGFileBrowser and TGNewBrowser. - - * RGBrowser.cxx: - * RGBrowser.h: - Fix includes for the new-browser files (before they were in - ROOTSYS/include). - -2007-08-28 Alja Mrak-Tadel - - EVE-dev - - * GridStepperEditor.cxx: - * GridStepperEditor.h: - Configure GridStepper widgets. - - * NLTProjector.cxx: - Remeve obsolete Signal/Slot call. - -2007-08-28 Alja Mrak-Tadel - - EVE-dev - - * .SKEL-gedsubed.cxx: - Change callback in sub-editor skeleton file. - - * GridStepperEditor.cxx: - * GridStepperEditor.h: - New class GridStepperEditor/GridStepperSubEditor. - - * LinkDef.h: - Register new classes: GridStepperSubEditor and GridStepperEditor. - - * NLTProjectorEditor.cxx: - Add tool-tip in TGComboBox. - -2007-08-28 Matevz Tadel - - EVE-dev - - *es FrameBoxGL.cxx: - Disable back-face culling if enabled. - - * RMacro.cxx: - Revert back to gled-style checking if a macro is loaded. The - Axel's method spits blood with latest cint. - -2007-08-27 Alja Mrak-Tadel - - EVE-dev - - * QuadSetEditor.cxx: - * QuadSetEditor.h: - Create extra tab to show histograms. - - * RGBAPalette.cxx: - * RGBAPalette.h: - New function SetLimitsScaleMinMax(Int_t low, Int_t high). - -2007-08-27 Matevz Tadel - - EVE-dev - - * RGTopFrame.cxx: - Use gClient->GetRoot() for creation of embedded gl viewer. - - * RGValuators.cxx: - During construction of label frame use fName instead of GetName(), - which is used for saving gui into a macro. - - * TrackRnrStyleEditor.cxx: - Fix labels, now that we can have spaces. - -2007-08-27 Matevz Tadel - - EVE-dev - - * FrameBox.cxx: - * FrameBox.h: - * FrameBoxGL.cxx: - Added option to render a filled-frame so that a client can be - selected even by pressing into an empty area. - - * GridStepper.h: - Added SetOs() to set origin. - - * RGEditor.cxx: - * RGEditor.h: - Implemented SetModel() from TGedEditor so that it can cross check - if the edited object is a render element. This is needed when the - model is set from somewhere else the reve, like TGLViewer. - - * ZTrans.cxx: - * ZTrans.h: - Added Float_t* versions of Get/SetPos(). - -2007-08-26 Alja Mrak-Tadel - - EVE-dev - - * NLTProjector.cxx: - * NLTProjector.h: - * NLTProjectorEditor.cxx: - * NLTProjectorEditor.h: - Add member fFixedRadius. It defines distance from center, where - projected value is not dependent of distortion. Introduce z-depth - which defines the z coordinate of projected points. - - * NLTBases.h: - * PointSet.cxx: - * NLTPolygonSet.cxx: - * NLTPolygonSet.h: - * NLTPolygonSetEditor.cxx: - * NLTPolygonSetEditor.h: - NLTProjected new member z-depth. - - * NLTTrack.cxx: - Improve algorithm in GetBreakpoint(). - - * PODs.h: - Add function Vector::Set(const Vector& v). - -2007-08-26 Matevz Tadel - - EVE-dev - - * RGTopFrame.cxx: - * RGTopFrame.h: - Added FullRedraw3D() forcing complete redraw of scenes and - viewers. - - * Scene.cxx: - * Scene.h: - Added RepaintAllScenes(). - - * Viewer.cxx: - * Viewer.h: - Added RepaintAllViewers(). - When camera reset is requested call viewer->PostSceneBuildSetup() - instead of ResetCamerasAfterNextUpdate(). - -2007-08-26 Matevz Tadel - - EVE-dev - - * RenderElement.cxx: - * RenderElement.h: - Added new optional argument Bool_t redraw to ElementChanged(). - USe the above method consistently throughout the code. - -2007-08-26 Matevz Tadel - - EVE-dev - - * NLTProjector.cxx: - NLTProjection::GetValForScreenPos(): use projected values during - calculation of inital bisection bounds. - - * PODs.cxx: - * PODs.h: - Added Vector::Mult(). Whitespace. - - * RGBrowser.cxx: - * RGBrowser.h: - RGLTEFrame: added functions ReconfToHorizontal/Vertical() and menu - entry to invoke them. - - * RGTopFrame.cxx: - * RGTopFrame.h: - Added GetLTEFrame(). - Setup TGLSAViewer to edit external objects by default. - At startup show editor of default viewer. - - * RenderElement.cxx: - In RemoveFromListTrees() rewrite list-tree-item loop to avoid - backward iteration during item removal. - - * Viewer.cxx: - Setup TGLSAViewer to edit external objects by default. - -2007-08-24 Alja Mrak-Tadel - - EVE-dev - - * NLTProjector.cxx: - * NLTProjector.h: - * NLTProjectorGL.cxx: - * NLTProjectorGL.h: - Improve algorithm for tick-mark positioning and configuration. - - * NLTProjectorEditor.cxx: - * NLTProjectorEditor.h: - Add widgets to configure scale info. - - * PODs.h: - Add index operator to Vector class. - - * RenderElement.cxx: - * RenderElement.h: - Add GetRnrElName()/GetRnrElTitle() in RenderElement class. - -2007-08-24 Matevz Tadel - - EVE-dev - - * LinkDef.h: - Register new class NLTPointSetGL. - - * NLTPointSetGL.cxx: - * NLTPointSetGL.h: - New files: hack to disable display-lists for NLTPointSet (bug in - fglrx driver, takes forever). - - * NLTProjector.cxx: - Set fProjection = 0 after destruction. - - * .SKEL-gl.cxx: - * NLTTrackGL.cxx: - Fix a commented line for display-list disabling. - -2007-08-24 Matevz Tadel - - EVE-dev - - * LinkDef.h: - Register class RGLTEFrame. - - * RGBrowser.cxx: - * RGBrowser.h: - Subclass RGBrowser from TNewBrowser, add new class RGLTEFrame to - encapsulate list-tree editor combo. - This is a major change, basically no code left unchanged. - - * RGEditor.cxx: - * RGEditor.h: - Added width, height ctor args. - Use RenderElement::GetEditorObject() instead of GetObject(). - - * RGTopFrame.cxx: - * RGTopFrame.h: - Removed inheritance from TGmainFrame, use RGBrowser as top-level - GUI element. Whole initalization rewritten to reflect that. - RGTopFrame class is now ripe to be renamed to Application, Manager - or something similar. - - For consistency renamed ElementChanged() to RenderElementChanged(). - - * RenderElement.cxx: - * RenderElement.h: - Added virtual GetEditorObject() that can return an alternate - object to be edited when rnr-el is selected (eg. Viewer passes its - TGLViewer). - - Added virtual CheckReferenceCount() (code taken from - RemoveParent()) that is now also called from RemoveFromListTree() - when a top-level list-tree-entry is removed. - - Replaced all calls gClient->NeedRedraw(listtree) with - listtree->ClearViewPort() [changes in root]. - - Added optional arguments Bool_t rnr_self/children to - En/DisableListElements(). - - * Reve.cxx: - Moved mime-type init for RMacro from RGTopFrame to SetupGUI(). - - * Scene.cxx: - Report scene destruction to global viewer-list. - - * SceneInfo.cxx: - * SceneInfo.h: - Overrode AcceptRenderElement() and HandleElementPaste() to deny - addition of elements. - - * Viewer.cxx: - * Viewer.h: - Viewer: overrode GetEditorObject() to return fGLViewer. - ViewerList: added SceneDestructing(Scene* scene) method to - unregister a scene from all existing viewers. - - * GeoNode.cxx: - Remove obsolete root-version ifdef. - - * VSDSelector.h: - Add missing include. - -2007-08-22 Alja Mrak-Tadel - - EVE-dev - - * NLTBases.cxx: - * NLTBases.h: - Implementation of NLTGeoProjectable class, to be a common base of - GeoNode and GeoShapeRnrEl for non-linear projections. - - * GeoNode.cxx: - * GeoNode.h: - GeoShapeRnrEl inherited from NLTGeoProjectable class. - - * LinkDef.h: - Register new class NLTGeoProjectable. - - * NLTPolygonSet.cxx: - * NLTPolygonSet.h: - * NLTProjector.cxx: - * NLTProjector.h: - Non-linear transformation of TBuffer3D moved in NLTPolygonSet. - - * NLTPolygonSetGL.cxx: - NLTPolygons in NLTPolygonSet stored in std::list. - - * NLTProjectorEditor.cxx: - Use NLTProjector Getters and Setters. - - * NLTTrack.h: - Remove PrintLineSegments() from popup menu. - - * NLTTrack.cxx: - In UpdateProjection disable recursive behavior. Recursive calls - already done by NLTProjector. - -2007-08-21 Alja Mrak-Tadel - - EVE-dev - - * GLUtilNS.cxx: - * GLUtilNS.h: - * LineGL.cxx: - Add function RenderLine() to draw a float array with given - TAttLine. In RenderCorsses() and RenderPoints() fix bug => leave - second argument to point to the same location. - - * TrackGL.cxx: - Use GLUtilNS::RenderLine(). Do check of PathMarks boundaries in - DirectDraw(). - - * Track.cxx: - * Track.h: - TrackList and Track become NLTProjectable classes. In Track remove - vector fVisPathMarks. It was unnecessary, since fPathMarks have - the required data. - - * LinkDef.h: - Register new classes NLTTrack, NLTTrackGL, NLTTrackList. - - * NLTTrack.cxx: - * NLTTrack.h: - * NLTTrackGL.cxx: - * NLTTrackGL.h: - New files: new classes for management and rendering of projected - tracks. - - * NLTProjector.cxx: - * NLTProjector.h: - Remove obsolete management for PointSet and Track. Fix bug in RhoZ::AcceptSegment(). - - * TrackRnrStyleEditor.cxx: - Fix interval in fMaxOrbits RGValuator. - -2007-08-20 Matevz Tadel - - EVE-dev - - * NLTProjector.cxx: - * NLTProjector.h: - * Viewer.cxx: - * Viewer.h: - Method HandleElementPaste() now returns Bool_t. - - * NLTProjector.cxx: - Use new method CollectSceneParentsFromChildren() to optimize - update of all related scenes. - - * RGBrowser.cxx: - * RGBrowser.h: - Conform to convention that change initiator is responsible for - calling redraw. Added method ItemChecked() to act as a mediator to - gReve. - - * RGTopFrame.cxx: - * RGTopFrame.h: - * RenderElement.cxx: - * RenderElement.h: - Added method CollectSceneParentsFromChildren(). - Changed return value of HandleElementPaste() from void to Bool_t. - Renamed Changed() to ElementChanged(). - - * TriangleSet.cxx: - Fixed gcc-4 warnings. - -2007-08-20 Matevz Tadel - - EVE-dev - - * RGBrowser.cxx: - * RGBrowser.h: - Added handling of key-presses in list-tree; in particular delete - key removes render element from specific parent. - - * RGTopFrame.cxx: - RemoveRenderElement now properly untangles the element from all - list-trees. - - * RenderElement.cxx: - * RenderElement.h: - Implemented RemoveFromListTrees(RenderElement* parent) that - removes items from all list trees where parent is equal to the one - passed as argument. - -2007-08-20 Matevz Tadel - - EVE-dev - - * NLTProjector.cxx: - * NLTProjector.h: - Bind element-paste to ImportElements. - Prefix imported render-element names with "NLT ". - - * PointSet.cxx: - * PointSet.h: - Implemented virtual ComputeBBox() to enforce minimal bounding-box - size. - - * RGBrowser.cxx: - * RGBrowser.h: - * RGTopFrame.cxx: - * RGTopFrame.h: - Removed obsolete code for "classic-look". - -2007-08-19 Matevz Tadel - - EVE-dev - - * LinkDef.h: - Register new class NLTProjectorEditor. - - * NLTProjector.cxx: - * NLTProjector.h: - Added methods for (recursive) import and update of projected - elements. - - * NLTProjectorEditor.cxx: - * NLTProjectorEditor.h: - New files, editor class for NLTProjection. - - * PointSet.cxx: - * PointSet.h: - PointSet: implemented virtual SetRnrElNameTitle(); - NLTPointSet: implemented virtual SetProjection(). - - * RenderElement.cxx: - * RenderElement.h: - Added virtual functions SetRnrElNameTitle() and Changed(). - -2007-08-19 Matevz Tadel - - EVE-dev - - * FrameBoxGL.h: - * NLTProjector.cxx: - * NLTProjector.h: - Fix gcc-4 warnings. - - * LinkDef.h: - Register new classes NLTProjectable, NLTProjected and NLTPointSet. - - * NLTBases.cxx: - * NLTBases.h: - New files: new abstract bases NLTProjectable and NLTProjected. - - * PointSet.cxx: - * PointSet.h: - New class NLTPointSet; add NLTProjectable as a base of PointSet. - - * RGBrowser.cxx: - Resize widgets to obtain resonable starting size. - -2007-08-19 Matevz Tadel - - EVE-dev - - * RGTopFrame.cxx: - * RGTopFrame.h: - Default start-up mode now embedded gl viewer; - added function SpawnNewScene(). - -2007-08-18 Alja Mrak-Tadel - - EVE-dev - - * LinkDef.h: - Registere new classes TrackEditor, TrackRnrStyleEditor and - TrackRnrStyleSubEditor. - - * Track.cxx: - * Track.h: - * TrackEditors.cxx: - * TrackEditors.h: - * TrackGL.cxx: - * TrackRnrStyleEditor.cxx: - * TrackRnrStyleEditor.h: - Configuration of track rendering has two sources. First is done by - TrackRnrStyle which can be shared. Second type of configuration - goes via TrackList container, a RenderElement parent of a track. - - TrackList handles only track line attributes. These attributes are - set recursively by default. The remaining configuration is dane - with referenced TrackRnrStyle. - - * GLUtilNS.cxx: - * GLUtilNS.h: - Change argument TAttMatker& in RenderPoints(), RenderCrosses() and - RenderPolymarkers() to const TAttMatker&. - - * LineEditor.cxx: - Put checkbox fRnrMarkers before checkbox fRnrLine. - - * Cascade.cxx: - * V0.cxx: - * VSDSelector.cxx: - * NLTProjector.cxx: - Set line color in tracks to TrackList main color. Remove call - MakeMarkers(). Rendering of fist vertex is done in - TrackGL::DirectDraw(). - -2007-08-18 Matevz Tadel - - EVE-dev - - * RenderElement.cxx: - * RenderElement.h: - Added virtual HandleElementPaste(RenderElement* el) that is called - on mouse-paste into list-tree-item representing the element. - - * Viewer.cxx: - * Viewer.h: - Override HandleElementPaste() to try and add a scene to the viewer. - - * RGTopFrame.cxx: - * RGTopFrame.h: - Added methods RenderElementSelect/Paste(). - - * RGBrowser.cxx: - In ItemClicked also check for middle button. - - * RGEditor.cxx: - * RGEditor.h: - Added new state data-memebr to cross-check if fRenderElement is - still correct; - hack to set priority of TAttMArkerEditor to one. - -2007-08-17 Matevz Tadel - - EVE-dev - - * EventBase.cxx: - * EventBase.h: - Subclass directly from RenderElementList instead of PadPrimitive. - - * Pad.cxx: - * Pad.h: - Override virtuals IsBatch(), Update() and GetViewer3D() to allow - Reve::Pad - GLViewer link to survive without a canvas. - - * RGBrowser.cxx: - * RGBrowser.h: - Removed all usage of pad during construction of editor and - gl-viewer. - - * RGEditor.cxx: - * RGEditor.h: - In Update() propagate the change to gReve so that it can deduce - which scenes need to be repainted. GUI size change. - - * RGTopFrame.cxx: - * RGTopFrame.h: - Major restructuring of basic state representation: use new - Viewer/Scene classes to allow many simoultaneous GL-viewers with - shared scenes; update mechanism changed accordingly. - - * RenderElement.cxx: - * RenderElement.h: - Added virtual CollectSceneParents() for update steering; - generalized methods for adding elements into list-trees; removed - obsolete class PadPrimitive. - - * Scene.cxx: - * Scene.h: - * SceneInfo.cxx: - * SceneInfo.h: - * Viewer.cxx: - * Viewer.h: - New files implementing classes for representation of - GL-viewer/scene classes in Reve. - - * LinkDef.h: - Register new classes Scene, SceneList, SceneInfo, Viewer and - ViewerList; remove PadPrimitive. - - * VSDSelector.cxx: - Removed obsolete protection of gPad. - -2007-08-13 Matevz Tadel - - EVE-dev - - * GeoNode.cxx: - * NLTProjector.cxx: - * PointSet.cxx: - * RGTopFrame.cxx: - * RGTopFrame.h: - * VSDSelector.cxx: - Consistent ordering of arguments to AddRenderElement(), - AddGlobalRenderElement() and RemoveRenderElement(). - -2007-08-09 Alja Mrak-Tadel - - EVE-dev - - * GLUtilNS.cxx: - * GLUtilNS.h: - * StraightLineSetGL.cxx: - In RederPolymarkers()/RederCorssess()/RederPoints() argument - sec_sel has default value false. RenderPolyMarkers() now also - applies color from TAttMarker. - - * Track.cxx: - * Track.h: - * TrackGL.cxx: - MakeTrack()/MakeTracks() are recursive by default. - - * LinkDef.h: - * NLTProjectorGL.h: - * NLTProjectorGL.cxx: - New files. - Draw axis to define bounding box of non-linear projected geometry. - - * NLTProjector.cxx: - * NLTProjector.h: - Fix inconsistent checking of polygon duplicates. Enable dynamic - configuration of TrackRenderStyle. - - * ZTrans.cxx: - * ZTrans.h: - Add multiply functions with Double_t* as an argument. - - * NLTPolygonSet.cxx: - * NLTPolygonSet.h: - * NLTPolygonSetGL.cxx: - NLTPolygonSetGL inherited from RenderElementList. Add Getters for - vertices and polygons. - - * NLTPolygonSetEditor.cxx: - * NLTPolygonSetEditor.h: - Edit transparency of main color. - -2007-07-23 Matevz Tadel - - * Track.h: - * TrackGL.cxx: - Whitespace. - - * MCHelixLine.hi: - * Track.cxx: - Set limit on number of steps in track extrapolation. - -2007-07-19 Matevz Tadel - - * RGBrowser.cxx: - From Bertrand: improve setup of single-window mode so that it - works on windows, too. - -2007-07-10 Matevz Tadel - - * CascadeEditors.cxx: - * Reve.cxx: - * Track.cxx: - * V0Editors.cxx: - From Bertrand: windows fixes. - - * TriangleSet.cxx: - * TriangleSet.h: - From Bertrand: windows fixes, added transparency. - -2007-07-02 Matevz Tadel - - * .SKEL-gl.cxx: - * .SKEL-gl.h: - * BoxSetGL.cxx: - * BoxSetGL.h: - * FrameBoxGL.cxx: - * GLUtilNS.cxx: - * GLUtilNS.h: - * LineGL.cxx: - * LineGL.h: - * NLTPolygonSetGL.cxx: - * NLTPolygonSetGL.h: - * QuadSetGL.cxx: - * QuadSetGL.h: - * StraightLineSetGL.cxx: - * StraightLineSetGL.h: - * TrackGL.cxx: - * TrackGL.h: - * TriangleSetGL.cxx: - * TriangleSetGL.h: - Follow-up on gl/ changes introduced in ROOT-5.16. - - * RMacro.cxx: - * RMacro.h: - Migrate to the new signature of TMacro::Exec. - - * GeoNode.cxx: - * GridStepper.cxx: - * NLTPolygonSet.cxx: - * NLTPolygonSet.h: - * NLTProjector.cxx: - * PODs.h: - * QuadSet.cxx: - * QuadSet.h: - Fix effc++ warnings. - - * RGTopFrame.cxx: - Remove unnecessary includes. - - * Reve.cxx: - * TrackEditors.cxx: - Add includes needed due to changes in ROOT. - - * Makefile: - Link also against libFTGL. - -2007-06-18 Matevz Tadel - - * StraightLineSet.cxx: - * StraightLineSet.h: - White-space. - - * StraightLineSetGL.cxx: - Bugfix: wrong size passed to marker renderer. - -2007-05-30 Alja Mrak-Tadel - - * LinkDef.h: - * NLTPolygonSet.cxx: - * NLTPolygonSet.h: - * NLTPolygonSetEditor.cxx: - * NLTPolygonSetEditor.h: - * NLTPolygonSetGL.cxx: - * NLTPolygonSetGL.h: - * NLTProjector.cxx: - * NLTProjector.h: - New files for non-linear projections. FishEye and RhoZ - projections are implemeted with NLTProjection::fDistortion value - varying from 0. to 0.001. NLTProjector functions ProjectGeoShape(), - ProjectPointSet() and ProjectTrackList() are used to build non-linear - projected scene with detector geometry, hits and tracks. - - * PODs.h: - New functions in Vector class. - - * Track.cxx: - * Track.h: - * TrackEditors.cxx: - * TrackEditors.h: - Enable line style modification in TrackList/TrackListEditor. - -2007-05-24 Alja Mrak-Tadel - - * RGTopFrame.cxx: - Fix palette handling according to new TColorWheel. - -2007-04-19 Alja Mrak-Tadel - - * GeoNode.cxx: - * GeoNode.h: - * RGeoNodeEditors.cxx: - Map SetRnrSelf and SetRnrChildren to node visibility and to node - daughters visibility. - -2007-04-19 Matevz Tadel - - * GeoNode.cxx: - Do not transpose rotation part of geo-shape-extract transformation. - - * ZTrans.cxx: - Transpose rotation part when copying data to TBuffer3D (as it is - transposed again in TGLPhysicalShape ctor). - -2007-04-18 Matevz Tadel - - * QuadSet.cxx: - * QuadSet.h: - * QuadSetEditor.cxx: - * QuadSetEditor.h: - Add support for creation/display of quad-value histograms. - - * RGBAPalette.cxx: - * RGBAPalette.h: - Added limit-getters, in ctor set limits to match min/max values. - -2007-04-17 Matevz Tadel - - * QuadSet.cxx: - * QuadSet.h: - * QuadSetGL.cxx: - Add support for all variations of y-z plane rectangles. - -2007-04-17 Matevz Tadel - - * Track.cxx: - Bogdan: fix calculation of squared momentum. - -2007-04-11 Alja Mrak-Tadel - - * StraightLineSet.cxx: - * StraightLineSet.h: - * StraightLineSetEditor.cxx: - * StraightLineSetEditor.h: - * StraightLineSetGL.cxx: - * StraightLineSetGL.h: - New class StraightLineSet with accompanying GL and Editor classes. - - * LinkDef.h: - Register new StraightLineSetXyzz classes. - - * GLUtilNS.h: - * GLUtilNS.cxx: - Add a function to render polymarkers from float array and - TAttMarker. - - * RGTopFrame.cxx: - * RenderElement.cxx: - * RenderElement.h: - Reimplement callback of the Checked() signal from - RGBrowser::fListTree; function in RenderElement renamed from - ToggleRnrState to SetRnrState. - -2007-04-11 Matevz Tadel - - * FrameBox.cxx: - * FrameBox.h: - Added setup function SetAABoxCenterHalfSize(). - -2007-04-10 Matevz Tadel - - * Track.cxx: - * Track.h: - Make Track::MakeTrack() virtual; Bogdan: add - TrackList::SelectByP() and supporting variables. - - * TrackEditors.cxx: - * TrackEditors.h: - Bogdan: add controls for TrackList::SelectByP(). - -2007-03-25 Alja Mrak-Tadel - - * GLTextNS.cxx: - * GLTextNS.h: - New namespace GLTextNS: produce text using texture maps. - - * GLUtilNS.h: - Helper classes/functions for GL state handling. - -2007-03-25 Matevz Tadel - - * Track.cxx: - * Track.h: - Improve handling of multi-level track containers for kinematic - trees. - -2007-03-24 Matevz Tadel - - * RenderElement.h: - * RenderElementEditor.cxx: - * RenderElementEditor.h: - Add virtual interface allowing sub-classes to request editor for - transparency and transformation-matrix via RenderElement. - - * ZTrans.cxx: - * ZTrans.h: - Added method SetGeoHMatrix(), initializing TGeoHMatrix from - ZTrans. - - * GeoNode.cxx: - * GeoNode.h: - Use transparency/transf-matrix service from RenderElement for - classes GeoTopNodeRnrEl and GeoShapeRnrEl; use ZTrans for storage - of transforamtion matrix in class GeoTopNodeRnrEl. - - * RGeoNodeEditors.cxx: - Removed unneeded widget association. - -2007-03-21 Alja Mrak-Tadel - - * QuadSet.h: - Add getter for fValueIsColor. - -2007-03-22 Matevz Tadel - - * TGeoShapeExtract.cxx: - * TGeoShapeExtract.h: - New files: class TGeoShapeExtract that allows import of exact - image of geometry as exported from gled. - - * GeoNode.cxx: - * GeoNode.h: - * LinkDef.h: - New classes TGeoShapeExtract and Reve::GeoShapeRnrEl. - - * RGBrowser.cxx: - Disable ROOT's auto-update of TGListTree's checkboxes. - - * RenderElement.cxx: - Setup check-box pictures when inserting in a list-tree. - - * Track.h: - Fix typo, swap of R/Z. - - * ZTrans.cxx: - * ZTrans.h: - Add ctors/setters from float/double arrays. - - * ZTransEditor.cxx: - Align position, rotation and scale widgets. - - * QuadSet.cxx: - * QuadSetGL.cxx: - * TrackEditors.cxx: - White-space. - -2007-03-15 Alja Mrak-Tadel - - * GridStepper.h: - * GridStepper.cxx: - * LinkDef.h: - New class GridStepper. - - * QuadSet.cxx: - Check ownership of quad-ids in Reset(). - -2007-03-15 Matevz Tadel - - * RGTopFrame.cxx: - * RGTopFrame.h: - Add an optional flag to Redraw3D() issuing a request for dropping - of logical-shapes on this redraw (temporary hack until we get new - gl stuff and can do it right). Fix in RemoveRenderElement() where - wrong argument was used when unregistering the item from the - browser. - -2007-03-08 Alja Mrak-Tadel - - * Track.cxx: - * Track.h: - Added method SortPathMarksByTime(). - - * TrackGL.cxx: - Fix for checking boundaries of path-marks. - -2007-03-08 Matevz Tadel - - * Track.cxx: - Missing initialization; fiddle with the track marker-style a bit - more. - -2007-03-06 Matevz Tadel - - * RenderElement.cxx: - In PadPrimitive::Paint() test fRnrChildren instead of fRnrSelf. - Some formatting changes while searching for the above bug. - -2007-03-04 Alja Mrak-Tadel - - * RenderElement.cxx: - * RenderElement.h: - * LinkDef.h: - Classes RenderElement and RenderElementListBase have been merged, - RenderElementListBase class is removed. - - Since RenderElement supports hierarchical structure fRnrElement is - replaced to fRnrSelf and fRnrChildren. RnrSelf/RnrDaughters - callbacks from editor set check box picture according to the for - possible states. - - New class PadPrimitve. Objects of the classes enable recursive - rendering as they are added in TPad fListOfPrimitives. - - * RGTopFrame.cxx: - * RGTopFrame.h: - Changes from RenderElement. Added Bool_t fKeepEmptyCont - determining behaviour of zero-count rnr-element imports. - - * Reve.cxx: - * Reve.h: - Added function to create 4 check box pictures which mark fRnrSelf - and fRnrChildren state of RenderElement. - - * EventBase.cxx: - * EventBase.h: - Inherit from PadPrimitve instead of from RenderElementList. - - * RenderElementEditor.cxx: - * RenderElementEditor.h: - * GeoNode.cxx: - * GeoNode.h: - * Cascade.cxx: - * Cascade.h: - * PointSet.cxx: - * PointSet.h: - * V0.cxx: - * V0.h: - * RGBrowser.cxx: - Changes from RenderElement. - - * Track.cxx: - * Track.h: - Changes from RenderElement; change import functions to - add hits, clusters, kinematic to selected object. - -2007-02-26 Matevz Tadel - - * Track.cxx: - * Track.h: - In class Track: renamed ImportDaughters() to ImportKine(), added - ImportKineWithArgs(), both accessible from ctx-menu. - -2007-02-26 Alja Mrak-Tadel - - * Track.cxx: - * Track.h: - * TrackEditors.cxx: - TrackRnrStyle: add pt-range memebers. - -2007-02-21 Alja Mrak-Tadel - - * PODs.cxx: - * PODs.h: - Add function to return PathMark type-name. - - * RenderElement.cxx: - Call redraw after Enable/DisableListElements. - - * Track.cxx: - * Track.h: - Two new items for context menu: PrintPathMarks and - ImportDaughters. - - * TrackGL.cxx: - Make consistent alignment. - -2007-02-20 Matevz Tadel - - * Cascade.cxx: - * Cascade.h: - * V0.cxx: - * V0.h: - Fix Ludovic's strange const-method syntax. - -2007-02-19 Alja Mrak-Tadel - - * PODs.h: - Add member time to class PathMark. Set values in enum - PathMark::Type_e. - - * Track.cxx: - Add callbacks to set path marks. In Track::MakeTrack() implement - fitting of track references and daughter particles. - - * Track.h: - Add Getters and Setters in TrackRnrStyle and TrackList to define - rendering of path marks. - - * TrackEditors.cxx: - * TrackEditors.h: - Add widgets to control rendering and fiting of pathmarks. - - * TrackGL.cxx: - * TrackGL.h: - Override LineGL::DirectDraw() to draw path marks. - -2007-01-19 Matevz Tadel - - * RGTopFrame.h: - Added nested class RedrawDisabler allowing exception-safe - disabling of 3d-redraw. - -2007-01-17 Matevz Tadel - - * TrackEditors.cxx: - * TrackEditors.h: - TrackCounterEditor: add number-entry to directly set the event - number. - -2007-01-12 Matevz Tadel - - * Track.cxx: - * Track.h: - TrackCounter: added method OutputEventTracks() for storing - scanning results. - - * TrackEditors.cxx: - * TrackEditors.h: - TrackCounterEditor: added buttons to print/file scanning results - and to display current histograms. - -2006-12-19 Matevz Tadel - - * Track.cxx: - * Track.h: - Added method Track::PrintKineStack(); added global TrackCounter - pointer to overcome resets of CINT globals in macros. - -2006-12-18 Matevz Tadel - - * FrameBox.h: - Added getters for frame-point details. - - * QuadSet.cxx: - If frame-box is set, use it for determination of bounding-box. - -2006-12-15 Matevz Tadel - - * FrameBox.h: - Subclass from ReferenceBackPtr instead of ReferenceCount. - - * RenderElement.cxx: - * RenderElement.h: - * Reve.cxx: - * Reve.h: - * LinkDef.h: - Moved declaration/definition of ReferenceBackPtr from - RenderElement.h/cxx to Reve.h/cxx. - - * PODs.h: - Added index data-member to MC/RecTrack. - - * QuadSet.cxx: - * QuadSet.h: - Added signal-emitting 'void CtrlClicked()' and 'Bool_t - fEmitSignals' that controls if signals are emitted on secondary - selection hit. - Fixed handling of main-color which is in fact - forwarded to shared frame. - - * Track.cxx: - * Track.h: - Added method 'void ImportClustersFromIndex()' and data-member - 'Int_t fIndex'. - - * TrackEditors.cxx: - Increase range of track extrapolation precision. - -2006-12-13 Matevz Tadel - - * QuadSet.cxx: - * QuadSet.h: - Added per-quad TRef, implemented virtual callback QuadSelected() - for secondary selection from GL. - - * QuadSetGL.cxx: - * QuadSetGL.h: - Added support for secondary selection. Sacrificed some speed for - simplicity / clarity. - -2006-12-08 Matevz Tadel - - * LinkDef.h: - * Plex.h: - Added inner struct VoidCPlex::iterator; increase constness. - - * QuadSet.cxx: - * QuadSet.h: - * QuadSetGL.cxx: - Slight simplification of heavy-duty loops over elements. - -2006-12-06 Matevz Tadel - - * QuadSet.cxx: - * QuadSet.h: - * QuadSetGL.cxx: - * QuadSetGL.h: - Added support for rendering hexagons (needed by PMD). - -2006-12-04 Matevz Tadel - - * RenderElement.cxx: - * RenderElement.h: - Renamed typedef lpRE_t/i to List_t/i. - Added method groups Begin/End/GetN-Parents/Children(). - - * Cascade.cxx: - * GeoNode.cxx: - * PointSet.cxx: - * V0.cxx: - Renamed typedef lpRE_t/i to List_t/i. - - * LinkDef.h: - New class TrackCounter[Editor]; added RenderElement typedefs. - - * QuadSetGL.cxx: - Render frame before checking if QuadSet is empty and exiting. - - * RMacro.cxx: - * RMacro.h: - Added a hack that restores CINT state if macro execution ends with - an exception. - - * Track.cxx: - * Track.h: - Added class TrackCounter; - Track now inherits from TQObject and emits a Clicked() signal; - Renamed typedef lpRE_t/i to List_t/i. - - * TrackEditors.cxx: - * TrackEditors.h: - Added class TrackCounterEditor. - - * TrackGL.cxx: - In TrackGL::ProcessSelection(): make model-track emit Clicked signal. - -2006-11-21 Matevz Tadel - - * Line.cxx: - * Line.h: - * LineEditor.cxx: - * LineEditor.h: - * LineGL.cxx: - * LineGL.h: - New files: line representation with per-point selection. - - * TrackGL.cxx: - * TrackGL.h: - New files: allow interaction with the track, more configurability - (render as line, points or both). - - * Track.cxx: - * Track.h: - Derive Track from Line (before was TPolyLine3D, RenderElement); - this allowed me to remove a lot of code actually shared with - PointSet. - - * LinkDef.h: - Register new classes. - - * MCHelixLine.hi: - Some points were duplicated during track construction. - - * QuadSet.cxx: - * QuadSet.h: - * QuadSetEditor.cxx: - * QuadSetGL.cxx: - * QuadSetGL.h: - Use better names for QuadTypes (enum and internal structs). - - * PointSet.h: - * TTreeTools.h: - Style/comment changes. - -2006-11-17 Matevz Tadel - - * RGBAPalette.cxx: - * RGBAPalette.h: - Removed unnecessary constructor. - -2006-11-17 Matevz Tadel - - * QuadSetGL.cxx: - Bugfix: loop variable was not increased in case of a continue - statement. - - * RGBAPalette.cxx: - * RGBAPalette.h: - Rename over/undershoot to over/underflow. - - * RGBAPaletteEditor.cxx: - * RGBAPaletteEditor.h: - Beautify editor; rename over/undershoot to over/underflow. - -2006-11-16 Matevz Tadel - - * Cascade.cxx: - * Cascade.h: - * CascadeEditors.cxx: - * CascadeEditors.h: - From Ludovic, new files for visualization of cascades. - - * LinkDef.h: - From Ludovic: register new classes. Reorganize some entries so - that a class, editor and gl-renderer are listed together. - - * V0.cxx: - * V0Editors.cxx: - * V0Editors.h: - From Ludovic: updates for V0 visualization. - - * QuadSet.cxx: - * QuadSet.h: - Main color now set from frame-box (instead of default palette - color). - - * QuadSetGL.cxx: - Use new color-query function from RGBAPalette; validity of digit - value was not honoured in line-drawing modes. - - * RGBAPalette.cxx: - * RGBAPalette.h: - * RGBAPaletteEditor.cxx: - * RGBAPaletteEditor.h: - Reimplementation of over/undershoot handling with separate modes - for both ends (cut, mark, clip and wrap); this works marvelously. - - * QuadSetEditor.cxx: - * QuadSetEditor.h: - New files, editor for QuadSet gluing together translation and - palette sub-editors. - - * RGValuators.cxx: - * RGValuators.h: - Added int version of SetLimits for RGDoubleValuator; added - getters for value limits (Ludovic). - - * Plex.cxx: - * TriangleSet.cxx: - Added some comments. - -2006-11-14 Matevz Tadel - - * BoxSet.cxx: - * BoxSetGL.h: - * QuadSet.cxx: - * QuadSet.h: - * QuadSetGL.h: - * RGBAPalette.cxx: - * RGBAPaletteEditor.cxx: - * RGEditor.cxx: - * RGEditor.h: - * RGValuators.h: - * RenderElement.cxx: - * RenderElement.h: - * TriangleSet.cxx: - * TriangleSet.h: - * ZTrans.cxx: - * ZTrans.h: - * ZTransEditor.cxx: - * ZTransEditor.h: - Fix effc++ warnings. - -2006-11-14 Matevz Tadel - - * RGValuators.h: - Added getters for limits of the RGValuator. - -2006-11-14 Matevz Tadel - - * BoxSet.cxx: - Removed support for old ROOT versions. - - * RenderElement.cxx: - * RenderElement.h: - Added base-interface ReferenceBackPtr (reference-counted object - with back references to render elements); to be used for shared - markup classes (color-palettes, frames) that need to update their - consumers once their state is changed. - - * Reve.cxx: - * Reve.h: - Removed code for RGBAPalette; now in its own file. - - * TrackEditors.cxx: - * TrackEditors.h: - Cleaned-up by using RGValuators instead of raw ROOT GUI (partial). - - * QuadSet.cxx: - * QuadSet.h: - * QuadSetGL.cxx: - * QuadSetGL.h: - Very optimized in sense of speed / memory usage as it supports - several orientations of rectangles and all possible variants of - default sizes / third coordinate; also added pointers to - color-palette and frame-box/rectangle so that these elements can - be shared among instances of the same type (eg. silicon strip - detectors). Means more code in this class ... but hopefully much - less code elsewhere. - - * LinkDef.h: - Register new classes FrameBox, Plex, RGBAPalette and V0 stuff. - - * FrameBox.cxx: - * FrameBox.h: - * FrameBoxGL.cxx: - * FrameBoxGL.h: - New files: provide a surrounding box/rectangle with a given - size/color; can be shared among many instances of render-elements - (eg. silicon strip detectors). - - * Plex.cxx: - * Plex.h: - New files: container with chunked memory allocation (to avoid - frequent re-allocation on creation time) and ability to refit - itself into a contiguous array. - - * RGBAPalette.cxx: - * RGBAPalette.h: - * RGBAPaletteEditor.cxx: - * RGBAPaletteEditor.h: - New files: a generic color palette with value to color mapping; to - be used by most digit/raw-data classes; can be shared among many - instances of render-elements (eg. silicon strip detectors). - - * V0.cxx: - * V0.h: - * V0Editors.cxx: - * V0Editors.h: - From Ludovic: new files for visualization of V0s. - - * RenderElementEditor.cxx: - * TriangleSet.cxx: - Formatting changes. - -2006-10-31 Matevz Tadel - - * LinkDef.h: - * QuadSet.cxx: - * QuadSet.h: - * QuadSetGL.cxx: - * QuadSetGL.h: - Started to work on reimplementation of the quad-set, renamed the - old one to OldQuadSet; i'm checking this in because another change is - needed for the new muon code and i already changed several things. - -2006-10-27 Matevz Tadel - - * BoxSetGL.cxx: - * BoxSetGL.h: - In Line render-mode really render boxes as lines to allow - selection to proceed through the box walls; removed pre-processor - ifs for old root version. - -2006-10-26 Matevz Tadel - - * Reve.cxx: - Fixed operator+ functions for exceptions (forgot to change them - when migrated from std::string to TString as exception base-class). - -2006-10-25 Matevz Tadel - - * BoxSet.cxx: - * BoxSet.h: - Changed inheritance to include Reve::RenderElement; - use ZTrans to store transformation matrix; - added render-mode state (to force line/fill drawing). - - In class Box added ctor and function MakeAxisAlignedBox() to - facilitate creation of regular boxes. - - * BoxSetGL.cxx: - Support different render modes. - - * LinkDef.h: - * Reve.cxx: - * Reve.h: - New class Reve::RGBAPalette: allow easier creation of color - paletts mapped to integer-value range. - - * Track.cxx: - * Track.h: - * TrackEditors.cxx: - * TrackEditors.h: - Added parameter 'Width_t fWidth' to TrackRnrStyle and a method to - change width of all tracks in TrackList. - - * TriangleSet.cxx: - * TriangleSet.h: - Added method method GenerateZNormalColors() that uses - Reve::RGBAPalette to set-up triangle color based on z-component of - the normal. - -2006-10-18 Matevz Tadel - - * ZTrans.cxx: - * ZTrans.h: - * ZTransEditor.cxx: - * ZTransEditor.h: - New files: implementation of homogeneous transformation matrix - with accompanying geditor. - - * TriangleSet.cxx: - * TriangleSet.h: - * TriangleSetEditor.cxx: - * TriangleSetEditor.h: - * TriangleSetGL.cxx: - * TriangleSetGL.h: - New files: arbitrary triangulated surface. - - * RGTopFrame.cxx: - Create a dummy event directory if none exists on AddRenderElement. - - * RGValuators.cxx: - * RGValuators.h: - Added class RGTriVecValuator, a composite widget for editing - three-vectors. Used by ZTransEditor. - - * LinkDef.h: - List new classes. - -2006-10-13 Matevz Tadel - - * Track.cxx: - * Track.h: - Added contructor from TPartice. - -2006-10-12 Matevz Tadel - - EVE-dev - - * BoxSet.h: - Fix wrong numerical constant in transformation assignment. - - * RGBrowser.cxx: - Added comment about problems with getting context-menu for - pointed-to object. - - * RGTopFrame.cxx: - * RGTopFrame.h: - Added data-members for important GUI elements (master-frame, - master-tab); added method 'AddCanvasTab(const char* name)'. - - * Reve.cxx: - * Reve.h: - Use TString as exception base instead of std::string. - - * VSDSelector.cxx: - * VSDSelector.h: - Brought in sync with changes in render-element - management/conventions. - -2006-10-04 Matevz Tadel - - EVE-dev - - * RenderElement.cxx: - * RenderElement.h: - Made RenderElement::ExportToCINT() virtual and reimplemented it in - RenderElementObjPtr. - - * Track.cxx: - * Track.h: - Added optional TrackRnrStyle* argument to TrackList constructors; - renamed mRnrStyle to fRnrStyle. - -2006-10-02 Matevz Tadel - - EVE-dev - - * .SKEL-ged.cxx: - * .SKEL-ged.h: - * .SKEL-gl.cxx: - * .SKEL-gl.h: - * .SKEL.h: - Changes for new geditor and gl two-level selection; added - delarations of private copy-ctor and assignment-op. - - * RGEditor.h: - Added method GetRnrElement(). - - * RGTopFrame.cxx: - * RGTopFrame.h: - * RenderElement.cxx: - Added RGTopFrame::PreDeleteRenderElement() and calls to it; so far - it checks if the object is being displayed in the editor but can - in principle check other things as well. - - * RenderElementEditor.cxx: - Assgined RenderElementEditor fPriority 0 (to appear on top). - -2006-09-27 Matevz Tadel - - * RGTopFrame.cxx: - * RGTopFrame.h: - * VSDSelector.cxx: - Made GLCanvas un-editable to prevent users from drawing things - over 3D scene; renamed the canvas data member from fCC to - fGLCanvas. Renamed local variables not to dress-up as - data-members. - -2006-09-26 Matevz Tadel - - * RGBrowser.cxx: - Hack to fix RenderElementObjPtr's colors in tree-view is no longer - needed. - - * RGEditor.cxx: - * RGEditor.h: - Properly update items of render-elements; call gReve::Redraw3D() - instead of pad modified/update. Added separate method - DisplayRenderElement() that caches the render-element in a - data-member to update it on change (needed for RenderElementObjPtr). - - * RGTopFrame.cxx: - Use RGEditor::DisplayRenderElement() instead of - DisplayObject(). Removed some never-used static structures. - - * RenderElement.cxx: - Removed Redraw3D() from UpdateItems() as it can now be called from - RGEditor::Update(); optimized item-updates in SetRnrElement() and - SetMainColor(). - - * PointSetArrayEditor.cxx: - * TrackEditors.cxx: - Added call to Update() in SetRange() methods. - -2006-09-26 Matevz Tadel - - * RGBrowser.cxx: - * RGEditor.cxx: - * RGEditor.h: - Use new functionality from TGedEditor. - - * PointSetArrayEditor.cxx: - * PointSetArrayEditor.h: - * RGeoNodeEditors.cxx: - * RGeoNodeEditors.h: - * RenderElementEditor.cxx: - * RenderElementEditor.h: - * TrackEditors.cxx: - * TrackEditors.h: - Conform to new TGedFrame paradigm in ROOT. - -2006-09-04 Matevz Tadel - - * MCHelixLine.hi: - Fix effc++ warnings and most blatant coding-convention violations. - -2006-08-30 Matevz Tadel - - * GeoNode.h: - * PODs.h: - * PointSet.cxx: - * PointSet.h: - * PointSetArrayEditor.cxx: - * PointSetArrayEditor.h: - * QuadSet.cxx: - * QuadSet.h: - * RGTopFrame.cxx: - * RGTopFrame.h: - * RGValuators.h: - * RGeoNodeEditors.cxx: - * RGeoNodeEditors.h: - * RenderElement.cxx: - * RenderElement.h: - * RenderElementEditor.cxx: - * RenderElementEditor.h: - * Reve.h: - * TTreeTools.h: - * Track.cxx: - * Track.h: - * TrackEditors.cxx: - * TrackEditors.h: - * VSD.cxx: - * VSD.h: - * VSDEvent.cxx: - * VSDEvent.h: - * VSDSelector.cxx: - * VSDSelector.h: - Fix effc++ warnings. - - * LinkDef.h: - * RGBrowser.cxx: - * RGBrowser.h: - Removed code for gled-like object editors (obsolete, somewhat - decayed); fix effc++ warnings. - -2006-08-29 Matevz Tadel - - EVE-dev - - * BoxSetGL.cxx: - * QuadSetGL.cxx: - Added ifdefs for post root-5.11.0 prototype of SetModelCheckClass(). - - * PointSet.cxx: - In Reset: added call to PointSet3D::ClearIds(). - - * RGTopFrame.cxx: - * RGTopFrame.h: - Added support for control of camera-reset to Redraw3D(); when - opening GL window disable automatic camera reset on update and on - double-click. - -2006-08-04 Matevz Tadel - - * PointSet.cxx: - * RGBrowser.cxx: - Commented-out info print statements. - -2006-07-11 Matevz Tadel - - * RMacro.cxx: - * RMacro.h: - Bypass buggy TMacro ctor (caused problems on paths including '.', - like /afs/cern.ch/). - -2006-07-11 Matevz Tadel - - * RenderElement.cxx: - * RenderElement.h: - Added method RenderElementListBase::DestroyElements(). - -2006-07-10 Matevz Tadel - - * Event.cxx: - * Event.h: - Removed files: the contents moved to VSDEvent and renamed - accordingly. - - * EventBase.cxx: - * EventBase.h: - New files: common base class for an event object (VSDEvent and - Alieve::Event). - - * VSDEvent.cxx: - * VSDEvent.h: - New files: rename of class Reve::Event, now subclassed from - EventBase. - - * LinkDef.h: - Reflect changes in event classes. - - * Reve.h: - Added include TError.h. - - * RGTopFrame.cxx: - * RGTopFrame.h: - Changed current-event pointer from TObject to EventBase; made - global-store and event-stores render elements; improved interface - for adding/removing render-elements. - - * RenderElement.cxx: - * RenderElement.h: - Implemented proper reference management accross render-elements, - render-element-lists and tree-items; implemented methods for - removal and destruction of render-elements. - - * GeoNode.cxx: - * GeoNode.h: - * PointSet.cxx: - * PointSet.h: - * RGeoNodeEditors.cxx: - * Track.cxx: - * Track.h: - Proper management of dependent render-elements, renamed - FullUpdate() to UpdateItems() and changed inheritance order - (derive RenderElement first). - -2006-07-03 Matevz Tadel - - * TTreeTools.cxx: - * TTreeTools.h: - * LinkDef.h: - Added new classes TPointSelector and TPointSelectorConsumer - allowing more natural extraction of point-data from trees. - - * PointSet.cxx: - * PointSet.h: - Implemented the TPointSelectorConsumer interface for PointSet and - PointSetArray; in PointSetArray removed obsolete methods - MakeScrollbar() and HandleScrollEvent(). - -2006-06-27 Matevz Tadel - - * BoxSetGL.cxx: - Skip render-state initialization if no boxes present. - - * GeoNode.cxx: - * GeoNode.h: - Added option to render GeoTopNodeRnrEl at a given global position - (requires ROOT > 5.11.7). - - * RGBrowser.cxx: - * RGBrowser.h: - * RGTopFrame.cxx: - Fixed creation of editor frame so that it uses X client's - SetRoot() functionality. This should (finally) close the issue. - - * RMacro.cxx: - Check for macro via full-path (fTitle); save macro as '.C' not - '.Cexec'. - - * Reve.cxx: - In CheckMacro() use TInterpreter::IsLoaded(mac) instead of - searching the list of global functions. - - * VSDSelector.cxx: - Fixed code for hit and cluster import to work with 'new' render - element registration mechanism. - -2006-06-21 Matevz Tadel - - * LinkDef.h: - * RMacro.cxx: - * RMacro.h: - New class Reve::RMacro: a sub-class of TMacro that tries to unload - the macros properly before/after the operation. - - * RGTopFrame.cxx: - * RGTopFrame.h: - Provide TFoler fMacroFolder to all consumers, register - Reve::RMacro mime type on start-up. - - * Reve.cxx: - * Reve.h: - Added global function Bool_t Reve:CheckMacro(). - -2006-06-20 Matevz Tadel - - * Track.cxx: - * Track.h: - In TrackList: added ImportHits/Clusters(); removed obsolete - MkPtScrollBar(). - -2006-06-19 Matevz Tadel - - * PointSet.cxx: - * PointSet.h: - In PointSetArray: added member for default daughter PointSet - capacity (fDefPointSetCapacity) and method DeleteBins(). Set - daughter polymarker stuff in InitBins() instead of CloseBins(). - - * RGValuators.cxx: - * RGValuators.h: - Consistently use nuber of slider positions in RGValuator. - - * RenderElement.h: - Added method RenderElementListBase::RemoveElements(). - -2006-06-14 Matevz Tadel - - * BoxSetGL.h: - Added non-protected wrapper Render() for DirectDraw(). - - * PointSet.cxx: - * PointSet.h: - Subclassed point-set-array from TAttMarker, propagate changes to - all children. - - * PointSetArrayEditor.cxx: - Removed stale printout. - - * RGTopFrame.cxx: - Print exceptions to terminal also. - -2006-06-13 Matevz Tadel - - * Track.cxx: - Draw charged tracks as straight lines when magnetic field is near - zero. - -2006-06-12 Matevz Tadel - - * MCHelixLine.hi: - Formatting changes. - - * RenderElement.cxx: - * RenderElement.h: - Renamed RenderElement::SetMainColorByPixel(Pixel_t) back to - RenderElement::SetMainColor(Pixel_t); there seemed to be a problem - when dependencies were not generated properly. - - * Track.cxx: - * Track.h: - Added methods Track::ImportHits() and Track::ImportClusters(); - fixed a charge value inconsistency yielding reconstructed - track charge to be 1/3. - -2006-06-09 Matevz Tadel - - * PointSet.h: - Added friend PointSetArrayEditor. - - * PointSetArrayEditor.cxx: - * PointSetArrayEditor.h: - * TrackEditors.cxx: - * TrackEditors.h: - Use RGDoubleValuator for range-selection widget. - - * RGTopFrame.cxx: - Accept -mode cmd-line option as an alias for -revemode. - - * RGValuators.cxx: - Added some padding for labels. - -2006-06-02 Matevz Tadel - - * RGTopFrame.cxx: - * RGTopFrame.h: - Added method UndrawRenderElement(). - - * RenderElement.cxx: - * RenderElement.h: - Implemented dtor for RenderElement removing all instances from - browsers. - - * RGValuators.cxx: - * RGValuators.h: - Added method RGValuator::SetEnabled(). - -2006-06-01 Matevz Tadel - - * BoxSet.cxx: - * BoxSetGL.cxx: - * QuadSet.cxx: - * QuadSet.h: - * QuadSetGL.cxx: - Added preprocessor conditionals to support ROOT > 5.11.2. - -2006-05-31 Matevz Tadel - - EVE-dev branch - - * LinkDef.h: - * RGValuators.cxx: - * RGValuators.h: - New valuator widget classes RGValuator and RGDoubleValuator. - -2006-05-31 Matevz Tadel - - EVE-dev branch - - * BoxSet.h: - Added method ArrTrans(). - - * Reve.cxx: - Added setup of macro/include paths into function - SetupEnvironment(). - - * reve_main/reve_main.cxx: - Removed macro/include path setup. - -2006-05-23 Matevz Tadel - - EVE-dev branch - - * RGBrowser.cxx: - * RGTopFrame.cxx: - Use RenderElement* as user-data of list-tree entries (it was - TObject* before). - - * LinkDef.h: - * RenderElement.cxx: - * RenderElement.h: - Added class RenderElementObjPtr to allow display and control of - pure TObjects (see alice-macros/region_marker.C for an - example). This is not perfect as there is no way to get - color-change updates from the editor (can fix this when i get - control over TGedEditor::Update()). RenderElement::GetObject() is - now virtual. - - * Reve.cxx: - * Reve.h: - Added function FindColorVar() to allow RenderElementObjPtr objects - to peek into appropriate color. - -2006-05-23 Matevz Tadel - - EVE-dev branch - - * BoxSet.cxx: - * BoxSet.h: - Do not initialize bbox in ctor. Moved ctor to cxx file, removed - Init(). - - * RGBrowser.cxx: - * RGBrowser.h: - Fix for editor window not appearing under some window - managers. For me it was working OK under fvwm and KDE (any focus - policy) but not at all under Gnome. This fixed my gnome problem - but it's quite likely the problem is not completely solved. - -2006-05-18 Matevz Tadel - - EVE-dev branch - - * RGTopFrame.cxx: - Added missing initializations. In particular, fCurrentEvent, - fCurrentEventLTI and fGeometryLTI were not initialized and this - caused segvs for usage without bootstrap with alieve_init.C macro. - -2006-05-17 Matevz Tadel - - EVE-dev branch - - * LinkDef.h: - * Reve.h: - New class Reve::ReferenceCount; to be used as secondary base class. - -2006-05-15 Matevz Tadel - - EVE-dev branch - - * Reve.cxx: - * Reve.h: - New function ColorFromIdx(). - - * BoxSet.cxx: - * BoxSet.h: - * BoxSetGL.cxx: - * BoxSetGL.h: - New files: a set of boxes with direct GL rendering. - - * LinkDef.h: - Pragmas for BoxSet/GL. - - * ChangeLog: - New file. diff --git a/EVE/Reve/DigitSet.cxx b/EVE/Reve/DigitSet.cxx deleted file mode 100644 index 720e99abe13..00000000000 --- a/EVE/Reve/DigitSet.cxx +++ /dev/null @@ -1,294 +0,0 @@ -// $Header$ - -#include "DigitSet.h" - -#include "ReveManager.h" - -#include - -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________________ -// DigitSet -// -// Base-class for displaying a digit collection. -// Provdies common services for: -// - specifying signal / color per digit -// - specifying object reference per digit -// - controlling palette and thresholds (external object RGBAPalette) -// - showing a frame around the digits (external object FrameBox) -// - specifying transformation matrix for the whole collection -// by data-member of class ZTrans. -// -// See also: -// QuadSet: rectangle, hexagon or line per digit -// BoxSet a 3D box per digit - -ClassImp(DigitSet) - -//______________________________________________________________________________ -DigitSet::DigitSet(const Text_t* n, const Text_t* t) : - RenderElement (), - TNamed (n, t), - - fDefaultValue (kMinInt), - fValueIsColor (kFALSE), - fOwnIds (kFALSE), - fPlex (), - fLastDigit (0), - - fFrame (0), - fPalette (0), - fRenderMode (RM_Fill), - fDisableLigting (kTRUE), - fEmitSignals (kFALSE), - fHistoButtons (kTRUE), - fHMTrans () -{ - // Constructor. -} - -//______________________________________________________________________________ -DigitSet::~DigitSet() -{ - // Destructor. - // Unreference frame and palette. Destroy referenced objects if they - // are owned by the DigitSet. - - SetFrame(0); - SetPalette(0); - if (fOwnIds) - ReleaseIds(); -} - -/******************************************************************************/ - -//______________________________________________________________________________ -DigitSet::DigitBase* DigitSet::NewDigit() -{ - // Protected method called whenever a new digit is added. - - fLastDigit = new (fPlex.NewAtom()) DigitBase(fDefaultValue); - return fLastDigit; -} - -//______________________________________________________________________________ -void DigitSet::ReleaseIds() -{ - // Protected method. Release and delete the referenced objects, the - // ownership is *NOT* checked. - - VoidCPlex::iterator qi(fPlex); - while (qi.next()) { - DigitBase& q = * (DigitBase*) qi(); - if (q.fId.GetObject()) { - delete q.fId.GetObject(); - q.fId = 0; - } - } -} - -/******************************************************************************/ -/******************************************************************************/ - -//______________________________________________________________________________ -void DigitSet::SetMainColor(Color_t color) -{ - // Override from RenderElement, forward to Frame. - - if (fFrame) { - fFrame->SetFrameColor(color); - fFrame->UpdateBackPtrItems(); - } - gReve->Redraw3D(); -} - -/******************************************************************************/ -/******************************************************************************/ - -//______________________________________________________________________________ -void DigitSet::RefitPlex() -{ - // Instruct underlying memory allocator to regroup itself into a - // contiguous memory chunk. - - fPlex.Refit(); -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void DigitSet::ScanMinMaxValues(Int_t& min, Int_t& max) -{ - // Iterate over the digits and detmine min and max signal values. - - if (fValueIsColor || fPlex.Size() == 0) return; - min = kMaxInt; - max = kMinInt; - for (Int_t c=0; cfValue; - if (v < min) min = v; - if (v > max) max = v; - a += fPlex.S(); - } - } - if (min == max) - --min; -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void DigitSet::DigitValue(Int_t value) -{ - // Set signal value for the last digit added. - - fLastDigit->fValue = value; -} - -//______________________________________________________________________________ -void DigitSet::DigitColor(Color_t ci) -{ - // Set color for the last digit added. - - ColorFromIdx(ci, (UChar_t*) & fLastDigit->fValue, kTRUE); -} - -//______________________________________________________________________________ -void DigitSet::DigitColor(UChar_t r, UChar_t g, UChar_t b, UChar_t a) -{ - // Set color for the last digit added. - - UChar_t* x = (UChar_t*) & fLastDigit->fValue; - x[0] = r; x[1] = g; x[2] = b; x[3] = a; -} - -//______________________________________________________________________________ -void DigitSet::DigitColor(UChar_t* rgba) -{ - // Set color for the last digit added. - - UChar_t* x = (UChar_t*) & fLastDigit->fValue; - x[0] = rgba[0]; x[1] = rgba[1]; x[2] = rgba[2]; x[3] = rgba[3]; -} - -//______________________________________________________________________________ -void DigitSet::DigitId(TObject* id) -{ - // Set external object reference for the last digit added. - - fLastDigit->fId = id; -} - -/******************************************************************************/ -/******************************************************************************/ - -//______________________________________________________________________________ -void DigitSet::Paint(Option_t* /*option*/) -{ - // Paint this object. Only direct rendering is supported. - - static const Exc_t eH("DigitSet::Paint "); - - TBuffer3D buff(TBuffer3DTypes::kGeneric); - - // Section kCore - buff.fID = this; - buff.fColor = fFrame ? fFrame->GetFrameColor() : 1; - buff.fTransparency = 0; - fHMTrans.SetBuffer3D(buff); - buff.SetSectionsValid(TBuffer3D::kCore); - - Int_t reqSections = gPad->GetViewer3D()->AddObject(buff); - if (reqSections != TBuffer3D::kNone) - Error(eH, "only direct GL rendering supported."); -} - -//______________________________________________________________________________ -void DigitSet::DigitSelected(Int_t idx) -{ - // Called from renderer when a digit with index idx is selected. - - if (fEmitSignals) { - CtrlClicked(this, idx); - } else { - DigitBase* qb = GetDigit(idx); - TObject* obj = qb->fId.GetObject(); - printf("DigitSet::DigitSelected idx=%d, value=%d, obj=0x%lx\n", - idx, qb->fValue, (ULong_t)obj); - if (obj) - obj->Print(); - } -} - -//______________________________________________________________________________ -void DigitSet::CtrlClicked(DigitSet* qs, Int_t idx) -{ - // Emit a CtrlClicked signal. - - Long_t args[2]; - args[0] = (Long_t) qs; - args[1] = (Long_t) idx; - - Emit("CtrlClicked(Reve::DigitSet*, Int_t)", args); -} - -/******************************************************************************/ -// Getters / Setters for Frame, RGBAPalette, ZTrans -/******************************************************************************/ - -//______________________________________________________________________________ -void DigitSet::SetFrame(FrameBox* b) -{ - // Set FrameBox pointer. - - if (fFrame == b) return; - if (fFrame) fFrame->DecRefCount(this); - fFrame = b; - if (fFrame) { - fFrame->IncRefCount(this); - SetMainColorPtr(fFrame->PtrFrameColor()); - } else { - SetMainColorPtr(0); - } -} - -//______________________________________________________________________________ -void DigitSet::SetPalette(RGBAPalette* p) -{ - // Set RGBAPalette pointer. - - if (fPalette == p) return; - if (fPalette) fPalette->DecRefCount(); - fPalette = p; - if (fPalette) fPalette->IncRefCount(); -} - -//______________________________________________________________________________ -RGBAPalette* DigitSet::AssertPalette() -{ - // Make sure the RGBAPalette pointer is not null. - // If it is not set, a new one is instantiated and the range is set - // to current min/max signal values. - - if (fPalette == 0) { - fPalette = new RGBAPalette; - if (!fValueIsColor) { - Int_t min, max; - ScanMinMaxValues(min, max); - fPalette->SetLimits(min, max); - fPalette->SetMinMax(min, max); - } - } - return fPalette; -} diff --git a/EVE/Reve/DigitSet.h b/EVE/Reve/DigitSet.h deleted file mode 100644 index 5187bac40a3..00000000000 --- a/EVE/Reve/DigitSet.h +++ /dev/null @@ -1,132 +0,0 @@ -// $Header$ - -#ifndef REVE_DigitSetBase_H -#define REVE_DigitSetBase_H - -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include - -#include - -namespace Reve { - -class DigitSet : public RenderElement, - public TNamed, public TQObject, - public TAtt3D, - public TAttBBox -{ - friend class DigitSetEditor; - - DigitSet(const DigitSet&); // Not implemented - DigitSet& operator=(const DigitSet&); // Not implemented - -public: - enum RenderMode_e { RM_AsIs, RM_Line, RM_Fill }; - -protected: - struct DigitBase - { - // Base-class for digit representation classes. - - Int_t fValue; // signal value of a digit (can be direct RGBA color) - TRef fId; // external object reference - - DigitBase(Int_t v=0) : fValue(v), fId() {} - }; - - Int_t fDefaultValue; // Default signal value. - Bool_t fValueIsColor; // Interpret signal value as RGBA color. - Bool_t fOwnIds; // Flag specifying if id-objects are owned by the DigitSet - VoidCPlex fPlex; // Container of digit data. - DigitBase* fLastDigit; //! The last digit added to collection. - - FrameBox* fFrame; // Pointer to frame structure. - RGBAPalette* fPalette; // Pointer to signal-color palette. - RenderMode_e fRenderMode; // Render mode: as-is / line / filled. - Bool_t fDisableLigting; // Disable lighting for rendering. - Bool_t fEmitSignals; // Emit signals on secondary-select. - Bool_t fHistoButtons; // Show histogram buttons in object editor. - ZTrans fHMTrans; // Overall transformation of whole collection. - - DigitBase* NewDigit(); - void ReleaseIds(); - -public: - DigitSet(const Text_t* n="DigitSet", const Text_t* t=""); - virtual ~DigitSet(); - - virtual Bool_t CanEditMainColor() { return kTRUE; } - virtual void SetMainColor(Color_t color); - - // Implemented in sub-classes: - // virtual void Reset(QuadType_e quadType, Bool_t valIsCol, Int_t chunkSize); - - void RefitPlex(); - void ScanMinMaxValues(Int_t& min, Int_t& max); - - // -------------------------------- - - void DigitValue(Int_t value); - void DigitColor(Color_t ci); - void DigitColor(UChar_t r, UChar_t g, UChar_t b, UChar_t a=255); - void DigitColor(UChar_t* rgba); - - void DigitId(TObject* id); - - Bool_t GetOwnIds() const { return fOwnIds; } - void SetOwnIds(Bool_t o) { fOwnIds = o; } - - DigitBase* GetDigit(Int_t n) { return (DigitBase*) fPlex.Atom(n); } - TObject* GetId(Int_t n) { return GetDigit(n)->fId.GetObject(); } - - // -------------------------------- - - // Implemented in subclasses: - // virtual void ComputeBBox(); - - virtual void Paint(Option_t* option=""); - - virtual void DigitSelected(Int_t idx); - virtual void CtrlClicked(DigitSet* qs, Int_t idx); // *SIGNAL* - - // -------------------------------- - - VoidCPlex* GetPlex() { return &fPlex; } - - FrameBox* GetFrame() const { return fFrame; } - void SetFrame(FrameBox* b); - - Bool_t GetValueIsColor() const { return fValueIsColor; } - - RGBAPalette* GetPalette() const { return fPalette; } - void SetPalette(RGBAPalette* p); - RGBAPalette* AssertPalette(); - - RenderMode_e GetRenderMode() const { return fRenderMode; } - void SetRenderMode(RenderMode_e rm) { fRenderMode = rm; } - - Bool_t GetEmitSignals() const { return fEmitSignals; } - void SetEmitSignals(Bool_t f) { fEmitSignals = f; } - - Bool_t GetHistoButtons() const { return fHistoButtons; } - void SetHistoButtons(Bool_t f) { fHistoButtons = f; } - - ZTrans& RefHMTrans() { return fHMTrans; } - void SetTransMatrix(Double_t* carr) { fHMTrans.SetFrom(carr); } - void SetTransMatrix(const TGeoMatrix& mat) { fHMTrans.SetFrom(mat); } - - ClassDef(DigitSet, 1); // Base-class for visual digit collections. -}; // endclass DigitSet - -} - -#endif diff --git a/EVE/Reve/DigitSetEditor.cxx b/EVE/Reve/DigitSetEditor.cxx deleted file mode 100644 index 66645191756..00000000000 --- a/EVE/Reve/DigitSetEditor.cxx +++ /dev/null @@ -1,181 +0,0 @@ -// $Header$ - -#include "DigitSetEditor.h" -#include - -#include -#include -#include -#include - -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________________ -// DigitSetEditor -// -// GUI editor for class DigitSet. -// - -ClassImp(DigitSetEditor) - -//______________________________________________________________________________ -DigitSetEditor::DigitSetEditor(const TGWindow *p, Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - fM(0), - fHMTrans (0), - fPalette (0), - - fHistoButtFrame(0), - fInfoFrame(0) -{ - // Constructor. - - MakeTitle("Transformation matrix"); - - fHMTrans = new ZTransSubEditor(this); - fHMTrans->Connect("UseTrans()", "Reve::DigitSetEditor", this, "Update()"); - fHMTrans->Connect("TransChanged()", "Reve::DigitSetEditor", this, "Update()"); - AddFrame(fHMTrans, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 2, 0, 0, 0)); - - - MakeTitle("Palette controls"); - - fPalette = new RGBAPaletteSubEditor(this); - fPalette->Connect("Changed", "Reve::DigitSetEditor", this, "Update()"); - AddFrame(fPalette, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 2, 0, 0, 0)); - - CreateInfoTab(); -} - -//______________________________________________________________________________ -DigitSetEditor::~DigitSetEditor() -{ - // Destructor. Noop. -} - -/*************************************************************************/ - -//______________________________________________________________________________ -void DigitSetEditor::CreateInfoTab() -{ - // Create information tab. - - fInfoFrame = CreateEditorTabSubFrame("Info"); - - TGCompositeFrame *title1 = new TGCompositeFrame(fInfoFrame, 180, 10, - kHorizontalFrame | - kLHintsExpandX | - kFixedWidth | - kOwnBackground); - - title1->AddFrame(new TGLabel(title1, "DigitSet Info"), - new TGLayoutHints(kLHintsLeft, 1, 1, 0, 0)); - title1->AddFrame(new TGHorizontal3DLine(title1), - new TGLayoutHints(kLHintsExpandX, 5, 5, 7, 7)); - fInfoFrame->AddFrame(title1, new TGLayoutHints(kLHintsTop, 0, 0, 2, 0)); - - - fHistoButtFrame = new TGHorizontalFrame(fInfoFrame); - TGTextButton* b = 0; - b = new TGTextButton(fHistoButtFrame, "Histo"); - b->SetToolTipText("Show histogram over full range."); - fHistoButtFrame->AddFrame(b, new TGLayoutHints(kLHintsLeft|kLHintsExpandX, 1, 1, 0, 0)); - b->Connect("Clicked()", "Reve::DigitSetEditor", this, "DoHisto()"); - - b = new TGTextButton(fHistoButtFrame, "Range Histo"); - b->SetToolTipText("Show histogram over selected range."); - fHistoButtFrame->AddFrame(b, new TGLayoutHints(kLHintsLeft|kLHintsExpandX, 1, 1, 0, 0)); - b->Connect("Clicked()", "Reve::DigitSetEditor", this, "DoRangeHisto()"); - fInfoFrame->AddFrame(fHistoButtFrame, new TGLayoutHints(kLHintsExpandX, 2, 0, 0, 0)); -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void DigitSetEditor::SetModel(TObject* obj) -{ - // Set model object. - - fM = dynamic_cast(obj); - - fHMTrans->SetDataFromTrans(&fM->fHMTrans); - - if (fM->fValueIsColor || fM->fPalette == 0) { - fPalette->UnmapWindow(); - } else { - fPalette->SetModel(fM->fPalette); - fPalette->MapWindow(); - } - - if (fM->fHistoButtons) - fHistoButtFrame->MapWindow(); - else - fHistoButtFrame->UnmapWindow(); -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void DigitSetEditor::DoHisto() -{ - // Show histogram slot. - - Int_t min, max; - if (fM->fPalette) { - min = fM->fPalette->GetLowLimit(); - max = fM->fPalette->GetHighLimit(); - } else { - fM->ScanMinMaxValues(min, max); - } - PlotHisto(min, max); -} - -//______________________________________________________________________________ -void DigitSetEditor::DoRangeHisto() -{ - // Show ranged histogram slot. - - Int_t min, max; - if (fM->fPalette) { - min = fM->fPalette->GetMinVal(); - max = fM->fPalette->GetMaxVal(); - } else { - fM->ScanMinMaxValues(min, max); - } - PlotHisto(min, max); -} - -//______________________________________________________________________________ -void DigitSetEditor::PlotHisto(Int_t min, Int_t max) -{ - // Plots a histogram from digit vales with given range. - - Int_t nbins = max-min+1; - while (nbins > 200) - nbins /= 2; - - TH1F* h = new TH1F(fM->GetName(), fM->GetTitle(), nbins, min-0.5, max+0.5); - h->SetDirectory(0); - h->SetBit(kCanDelete); - VoidCPlex::iterator qi(fM->fPlex); - while (qi.next()) - h->Fill(((DigitSet::DigitBase*)qi())->fValue); - - gStyle->SetOptStat(1111111); - h->Draw(); - gPad->Modified(); - gPad->Update(); -} diff --git a/EVE/Reve/DigitSetEditor.h b/EVE/Reve/DigitSetEditor.h deleted file mode 100644 index 48c8676b5d8..00000000000 --- a/EVE/Reve/DigitSetEditor.h +++ /dev/null @@ -1,56 +0,0 @@ -// $Header$ - -#ifndef REVE_DigitSetEditor_H -#define REVE_DigitSetEditor_H - -#include - -class TGCheckButton; -class TGNumberEntry; -class TGColorSelect; - -namespace Reve { - -class DigitSet; - -class RGValuator; -class RGDoubleValuator; -class ZTransSubEditor; - -// It would be better to have button to change model to the palette -// object itself. -class RGBAPaletteSubEditor; - -class DigitSetEditor : public TGedFrame -{ -private: - DigitSetEditor(const DigitSetEditor&); // Not implemented - DigitSetEditor& operator=(const DigitSetEditor&); // Not implemented - - void CreateInfoTab(); -protected: - DigitSet * fM; // Model object. - - ZTransSubEditor *fHMTrans; // ZTrans sub-editor. - RGBAPaletteSubEditor *fPalette; // Palette sub-editor. - - TGHorizontalFrame *fHistoButtFrame; // Frame holding histogram display buttons. - TGVerticalFrame *fInfoFrame; // Frame displaying basic digit statistics. - -public: - DigitSetEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, UInt_t options = kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - virtual ~DigitSetEditor(); - - virtual void SetModel(TObject* obj); - - // Declare callback/slot methods - void DoHisto(); - void DoRangeHisto(); - void PlotHisto(Int_t min, Int_t max); - - ClassDef(DigitSetEditor, 1); // Editor for DigitSet class. -}; // endclass DigitSetEditor - -} - -#endif diff --git a/EVE/Reve/EventBase.cxx b/EVE/Reve/EventBase.cxx deleted file mode 100644 index c8ea5ee52e1..00000000000 --- a/EVE/Reve/EventBase.cxx +++ /dev/null @@ -1,37 +0,0 @@ -// $Header$ - -#include "EventBase.h" - -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// Reve::EventBase -// - -ClassImp(EventBase) - -EventBase::EventBase(const Text_t* n, const Text_t* t) : - RenderElementList(n, t), - fNewEventCommands() -{} - -/**************************************************************************/ - -void EventBase::AfterNewEventLoaded() -{ - TIter next(&fNewEventCommands); - TObject* o; - while ((o = next())) { - TObjString* s = dynamic_cast(o); - if (s) - gInterpreter->ProcessLine(s->String()); - } -} - -void EventBase::AddNewEventCommand(const Text_t* cmd) -{ - fNewEventCommands.Add(new TObjString(cmd)); -} diff --git a/EVE/Reve/EventBase.h b/EVE/Reve/EventBase.h deleted file mode 100644 index 578a593bbf8..00000000000 --- a/EVE/Reve/EventBase.h +++ /dev/null @@ -1,38 +0,0 @@ -// $Header$ - -#ifndef REVE_EventBase_H -#define REVE_EventBase_H - -#include - -#include - -namespace Reve { - -class EventBase : public RenderElementList -{ -protected: - TList fNewEventCommands; - -public: - EventBase(const Text_t* n="EventBase", const Text_t* t=""); - virtual ~EventBase() {} - - TList& GetNewEventCommands() { return fNewEventCommands; } - - virtual void Open() {} - virtual void GotoEvent(Int_t /*event*/) {} - virtual void NextEvent() {} - virtual void PrevEvent() {} - virtual void Close() {} - - virtual void AfterNewEventLoaded(); - virtual void AddNewEventCommand(const Text_t* cmd); - - - ClassDef(EventBase, 1); -}; // endclass Event - -} - -#endif diff --git a/EVE/Reve/FrameBox.cxx b/EVE/Reve/FrameBox.cxx deleted file mode 100644 index 1f0a4d9057b..00000000000 --- a/EVE/Reve/FrameBox.cxx +++ /dev/null @@ -1,149 +0,0 @@ -// $Header$ - -#include - -#include - -using namespace Reve; - -//______________________________________________________________________ -// FrameBox -// - -ClassImp(FrameBox) - -FrameBox::FrameBox() : - fFrameType (FT_None), - fFrameSize (0), - fFramePoints (0), - - fFrameWidth (1), - fFrameColor (1), - fBackColor (0), - fFrameFill (kFALSE), - fDrawBack (kFALSE) -{ - fFrameRGBA[0] = fFrameRGBA[1] = fFrameRGBA[2] = 0; fFrameRGBA[3] = 255; - fBackRGBA [0] = fBackRGBA [1] = fBackRGBA [2] = 255; fBackRGBA [3] = 255; -} - -FrameBox::~FrameBox() -{ - delete [] fFramePoints; -} - -/**************************************************************************/ - -void FrameBox::SetAAQuadXY(Float_t x, Float_t y, Float_t z, - Float_t dx, Float_t dy) -{ - fFrameType = FT_Quad; - fFrameSize = 12; - delete [] fFramePoints; - fFramePoints = new Float_t [fFrameSize]; - Float_t* p = fFramePoints; - p[0] = x; p[1] = y; p[2] = z; p += 3; - p[0] = x+dx; p[1] = y; p[2] = z; p += 3; - p[0] = x+dx; p[1] = y+dy; p[2] = z; p += 3; - p[0] = x ; p[1] = y+dy; p[2] = z; p += 3; -} - -void FrameBox::SetAAQuadXZ(Float_t x, Float_t y, Float_t z, - Float_t dx, Float_t dz) -{ - fFrameType = FT_Quad; - fFrameSize = 12; - delete [] fFramePoints; - fFramePoints = new Float_t [fFrameSize]; - Float_t* p = fFramePoints; - p[0] = x; p[1] = y; p[2] = z; p += 3; - p[0] = x+dx; p[1] = y; p[2] = z; p += 3; - p[0] = x+dx; p[1] = y; p[2] = z+dz; p += 3; - p[0] = x ; p[1] = y; p[2] = z+dz; p += 3; -} - -void FrameBox::SetAABox(Float_t x, Float_t y, Float_t z, - Float_t dx, Float_t dy, Float_t dz) -{ - fFrameType = FT_Box; - fFrameSize = 24; - delete [] fFramePoints; - fFramePoints = new Float_t [fFrameSize]; - - Float_t* p = fFramePoints; - //bottom - p[0] = x; p[1] = y + dy; p[2] = z; p += 3; - p[0] = x + dx; p[1] = y + dy; p[2] = z; p += 3; - p[0] = x + dx; p[1] = y; p[2] = z; p += 3; - p[0] = x; p[1] = y; p[2] = z; p += 3; - //top - p[0] = x; p[1] = y + dy; p[2] = z + dz; p += 3; - p[0] = x + dx; p[1] = y + dy; p[2] = z + dz; p += 3; - p[0] = x + dx; p[1] = y; p[2] = z + dz; p += 3; - p[0] = x; p[1] = y; p[2] = z + dz; -} - -void FrameBox::SetAABoxCenterHalfSize(Float_t x, Float_t y, Float_t z, - Float_t dx, Float_t dy, Float_t dz) -{ - fFrameType = FT_Box; - fFrameSize = 24; - delete [] fFramePoints; - fFramePoints = new Float_t [fFrameSize]; - - Float_t* p = fFramePoints; - //bottom - p[0] = x - dx; p[1] = y + dy; p[2] = z - dz; p += 3; - p[0] = x + dx; p[1] = y + dy; p[2] = z - dz; p += 3; - p[0] = x + dx; p[1] = y - dy; p[2] = z - dz; p += 3; - p[0] = x - dx; p[1] = y - dy; p[2] = z - dz; p += 3; - //top - p[0] = x - dx; p[1] = y + dy; p[2] = z + dz; p += 3; - p[0] = x + dx; p[1] = y + dy; p[2] = z + dz; p += 3; - p[0] = x + dx; p[1] = y - dy; p[2] = z + dz; p += 3; - p[0] = x - dx; p[1] = y - dy; p[2] = z + dz; -} - -/**************************************************************************/ - -void FrameBox::SetFrameColor(Color_t ci) -{ - fFrameColor = ci; - ColorFromIdx(ci, fFrameRGBA, kTRUE); -} - -void FrameBox::SetFrameColor(Pixel_t pix) -{ - SetFrameColor(Color_t(TColor::GetColor(pix))); -} - -void FrameBox::SetFrameColor(UChar_t r, UChar_t g, UChar_t b, UChar_t a) -{ - fFrameColor = Color_t(TColor::GetColor(r, g, b)); - fFrameRGBA[0] = r; - fFrameRGBA[1] = g; - fFrameRGBA[2] = b; - fFrameRGBA[3] = a; -} - -/**************************************************************************/ - -void FrameBox::SetBackColor(Color_t ci) -{ - fBackColor = ci; - ColorFromIdx(ci, fBackRGBA, kTRUE); -} - -void FrameBox::SetBackColor(Pixel_t pix) -{ - SetBackColor(Color_t(TColor::GetColor(pix))); -} - -void FrameBox::SetBackColor(UChar_t r, UChar_t g, UChar_t b, UChar_t a) -{ - fBackColor = Color_t(TColor::GetColor(r, g, b)); - fBackRGBA[0] = r; - fBackRGBA[1] = g; - fBackRGBA[2] = b; - fBackRGBA[3] = a; -} diff --git a/EVE/Reve/FrameBox.h b/EVE/Reve/FrameBox.h deleted file mode 100644 index 0194760477f..00000000000 --- a/EVE/Reve/FrameBox.h +++ /dev/null @@ -1,85 +0,0 @@ -// $Header$ - -#ifndef REVE_FrameBox_H -#define REVE_FrameBox_H - -#include - -#include - -namespace Reve { - -class FrameBox : public TObject, public ReferenceBackPtr -{ - friend class FrameBoxGL; - -public: - enum FrameType_e { FT_None, FT_Quad, FT_Box }; - -private: - FrameBox(const FrameBox&); // Not implemented - FrameBox& operator=(const FrameBox&); // Not implemented - -protected: - FrameType_e fFrameType; - Int_t fFrameSize; - Float_t *fFramePoints; //[fFrameSize] - - Float_t fFrameWidth; - Color_t fFrameColor; - Color_t fBackColor; - UChar_t fFrameRGBA[4]; - UChar_t fBackRGBA[4]; - Bool_t fFrameFill; - Bool_t fDrawBack; - -public: - FrameBox(); - virtual ~FrameBox(); - - void SetAAQuadXY(Float_t x, Float_t y, Float_t z, Float_t dx, Float_t dy); - void SetAAQuadXZ(Float_t x, Float_t y, Float_t z, Float_t dx, Float_t dz); - - void SetAABox(Float_t x, Float_t y, Float_t z, - Float_t dx, Float_t dy, Float_t dz); - - void SetAABoxCenterHalfSize(Float_t x, Float_t y, Float_t z, - Float_t dx, Float_t dy, Float_t dz); - - // ---------------------------------------------------------------- - - FrameType_e GetFrameType() const { return fFrameType; } - Int_t GetFrameSize() const { return fFrameSize; } - Float_t* GetFramePoints() const { return fFramePoints; } - - Float_t GetFrameWidth() const { return fFrameWidth; } - void SetFrameWidth(Float_t f) { fFrameWidth = f; } - - Color_t GetFrameColor() const { return fFrameColor; } - Color_t* PtrFrameColor() { return &fFrameColor; } - UChar_t* GetFrameRGBA() { return fFrameRGBA; } - - void SetFrameColor(Color_t ci); - void SetFrameColor(Pixel_t pix); - void SetFrameColor(UChar_t r, UChar_t g, UChar_t b, UChar_t a=255); - - Color_t GetBackColor() const { return fBackColor; } - Color_t* PtrBackColor() { return &fBackColor; } - UChar_t* GetBackRGBA() { return fBackRGBA; } - - void SetBackColor(Color_t ci); - void SetBackColor(Pixel_t pix); - void SetBackColor(UChar_t r, UChar_t g, UChar_t b, UChar_t a=255); - - Bool_t GetFrameFill() const { return fFrameFill; } - void SetFrameFill(Bool_t f) { fFrameFill = f; } - - Bool_t GetDrawBack() const { return fDrawBack; } - void SetDrawBack(Bool_t f) { fDrawBack = f; } - - ClassDef(FrameBox, 1); -}; // endclass FrameBox - -} - -#endif diff --git a/EVE/Reve/FrameBoxGL.cxx b/EVE/Reve/FrameBoxGL.cxx deleted file mode 100644 index 7ae8390a4f5..00000000000 --- a/EVE/Reve/FrameBoxGL.cxx +++ /dev/null @@ -1,92 +0,0 @@ -// $Header$ - -#include "FrameBoxGL.h" -#include - -#include - -#include - -using namespace Reve; - -//______________________________________________________________________ -// FrameBoxGL -// -// A class encapsulating GL rendering of Reve::FrameBox via a static -// meber function. - -ClassImp(FrameBoxGL) - -void FrameBoxGL::RenderFrame(const FrameBox& b, Bool_t fillp) -{ - const Float_t* p = b.fFramePoints; - - if (b.fFrameType == FrameBox::FT_Quad) - { - glBegin(fillp ? GL_POLYGON : GL_LINE_LOOP); - glVertex3fv(p); glVertex3fv(p + 3); - glVertex3fv(p + 6); glVertex3fv(p + 9); - glEnd(); - } - else if (b.fFrameType == FrameBox::FT_Box) - { - // !!! frame-fill not implemented for 3D frame. - glBegin(GL_LINE_STRIP); - glVertex3fv(p); glVertex3fv(p + 3); - glVertex3fv(p + 6); glVertex3fv(p + 9); - glVertex3fv(p); - glVertex3fv(p + 12); glVertex3fv(p + 15); - glVertex3fv(p + 18); glVertex3fv(p + 21); - glVertex3fv(p + 12); - glEnd(); - glBegin(GL_LINES); - glVertex3fv(p + 3); glVertex3fv(p + 15); - glVertex3fv(p + 6); glVertex3fv(p + 18); - glVertex3fv(p + 9); glVertex3fv(p + 21); - glEnd(); - } -} - -void FrameBoxGL::Render(const FrameBox* box) -{ - const FrameBox& b = *box; - - glPushAttrib(GL_POLYGON_BIT | GL_LINE_BIT | GL_ENABLE_BIT); - - glColorMaterial(GL_FRONT_AND_BACK, GL_DIFFUSE); - glEnable(GL_COLOR_MATERIAL); - glDisable(GL_CULL_FACE); - - if (b.fFrameType == FrameBox::FT_Quad && b.fDrawBack) - { - GLboolean lmts; - glGetBooleanv(GL_LIGHT_MODEL_TWO_SIDE, &lmts); - if (!lmts) glLightModeli(GL_LIGHT_MODEL_TWO_SIDE, GL_TRUE); - - glEnable(GL_POLYGON_OFFSET_FILL); - glPolygonOffset(2, 2); - glPolygonMode(GL_FRONT_AND_BACK, GL_FILL); - - const Float_t* p = b.fFramePoints; - Float_t normal[3]; - TMath::Normal2Plane(p, p+3, p+6, normal); - glNormal3fv(normal); - - glColor4ubv(b.fBackRGBA); - RenderFrame(b, kTRUE); - - if (!lmts) glLightModeli(GL_LIGHT_MODEL_TWO_SIDE, GL_FALSE); - } - - glDisable(GL_LIGHTING); - glPolygonMode(GL_FRONT_AND_BACK, GL_LINE); - glEnable(GL_BLEND); - glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); - glEnable(GL_LINE_SMOOTH); - - glLineWidth(b.fFrameWidth); - glColor4ubv(b.fFrameRGBA); - RenderFrame(b, b.fFrameFill); - - glPopAttrib(); -} diff --git a/EVE/Reve/FrameBoxGL.h b/EVE/Reve/FrameBoxGL.h deleted file mode 100644 index 1beacb5c3e8..00000000000 --- a/EVE/Reve/FrameBoxGL.h +++ /dev/null @@ -1,31 +0,0 @@ -// $Header$ - -#ifndef REVE_FrameBoxGL_H -#define REVE_FrameBoxGL_H - -#include - -namespace Reve { - -class FrameBox; - -class FrameBoxGL -{ -private: - FrameBoxGL(); // Not implemented - FrameBoxGL(const FrameBoxGL&); // Not implemented - FrameBoxGL& operator=(const FrameBoxGL&); // Not implemented - - static void RenderFrame(const FrameBox& b, Bool_t fillp); - -public: - virtual ~FrameBoxGL() {} - - static void Render(const FrameBox* box); - - ClassDef(FrameBoxGL, 0); -}; // endclass FrameBoxGL - -} - -#endif diff --git a/EVE/Reve/GLTextNS.cxx b/EVE/Reve/GLTextNS.cxx deleted file mode 100644 index 1a92f0b0ffb..00000000000 --- a/EVE/Reve/GLTextNS.cxx +++ /dev/null @@ -1,700 +0,0 @@ -// The following implementation is based on TexFont API, -// implementation and accompanying programs by Mark J. Kilgard. -// Original license: - -/* Copyright (c) Mark J. Kilgard, 1997. */ -/* This program is freely distributable without licensing fees and is - provided without guarantee or warrantee expressed or implied. This - program is -not- in the public domain. */ - -#include "GLTextNS.h" - -#include -#include - -#include - -#include -#include -#include -#include - -#include -#include - -using Reve::Exc_t; - -namespace GLTextNS { - -TexFont* fgDefaultFont = 0; - -#if 0 -/* Uncomment to debug various scenarios. */ -#undef GL_VERSION_1_1 -#undef GL_EXT_texture_object -#undef GL_EXT_texture -#endif - -int useLuminanceAlpha = 1; - -/* byte swap a 32-bit value */ -#define SWAPL(x, n) { \ - n = ((char *) (x))[0]; \ - ((char *) (x))[0] = ((char *) (x))[3]; \ - ((char *) (x))[3] = n; \ - n = ((char *) (x))[1]; \ - ((char *) (x))[1] = ((char *) (x))[2]; \ - ((char *) (x))[2] = n; } - -/* byte swap a short */ -#define SWAPS(x, n) { \ - n = ((char *) (x))[0]; \ - ((char *) (x))[0] = ((char *) (x))[1]; \ - ((char *) (x))[1] = n; } - -/**************************************************************************/ - -static TexGlyphVertexInfo* getTCVI(TexFont * txf, int c) -{ - TexGlyphVertexInfo *tgvi; - - /* Automatically substitute uppercase letters with lowercase if not - uppercase available (and vice versa). */ - if ((c >= txf->min_glyph) && (c < txf->min_glyph + txf->range)) { - tgvi = txf->lut[c - txf->min_glyph]; - if (tgvi) { - return tgvi; - } - if (islower(c)) { - c = toupper(c); - if ((c >= txf->min_glyph) && (c < txf->min_glyph + txf->range)) { - return txf->lut[c - txf->min_glyph]; - } - } - if (isupper(c)) { - c = tolower(c); - if ((c >= txf->min_glyph) && (c < txf->min_glyph + txf->range)) { - return txf->lut[c - txf->min_glyph]; - } - } - } - - //fprintf(stderr, "texfont: tried to access unavailable font character \"%c\" (%d)\n", - // isprint(c) ? c : ' ', c); - - tgvi = txf->lut[' ' - txf->min_glyph]; - if (tgvi) return tgvi; - tgvi = txf->lut['_' - txf->min_glyph]; - if (tgvi) return tgvi; - - return 0; -} - -/**************************************************************************/ - -static char *lastError; - -char* txfErrorString(void) -{ - return lastError; -} - -/**************************************************************************/ - -TexFont* txfLoadFont(const char *filename) -{ - TexFont *txf; - FILE *file; - GLfloat w, h, xstep, ystep; - char fileid[4], tmp; - unsigned char *texbitmap; - int min_glyph, max_glyph; - int endianness, swap, format, stride, width, height; - int i, j, got; - - txf = NULL; - file = fopen(filename, "rb"); - if (file == NULL) { - lastError = "file open failed."; - goto error; - } - txf = (TexFont *) malloc(sizeof(TexFont)); - if (txf == NULL) { - lastError = "out of memory."; - goto error; - } - /* For easy cleanup in error case. */ - txf->texobj = 0; // MT add - txf->tgi = NULL; - txf->tgvi = NULL; - txf->lut = NULL; - txf->teximage = NULL; - - got = fread(fileid, 1, 4, file); - if (got != 4 || strncmp(fileid, "\377txf", 4)) { - lastError = "not a texture font file."; - goto error; - } - assert(sizeof(int) == 4); /* Ensure external file format size. */ - got = fread(&endianness, sizeof(int), 1, file); - if (got == 1 && endianness == 0x12345678) { - swap = 0; - } else if (got == 1 && endianness == 0x78563412) { - swap = 1; - } else { - lastError = "not a texture font file."; - goto error; - } -#define EXPECT(n) if (got != n) { lastError = "premature end of file."; goto error; } - got = fread(&format, sizeof(int), 1, file); - EXPECT(1); - got = fread(&txf->tex_width, sizeof(int), 1, file); - EXPECT(1); - got = fread(&txf->tex_height, sizeof(int), 1, file); - EXPECT(1); - got = fread(&txf->max_ascent, sizeof(int), 1, file); - EXPECT(1); - got = fread(&txf->max_descent, sizeof(int), 1, file); - EXPECT(1); - got = fread(&txf->num_glyphs, sizeof(int), 1, file); - EXPECT(1); - - if (swap) { - SWAPL(&format, tmp); - SWAPL(&txf->tex_width, tmp); - SWAPL(&txf->tex_height, tmp); - SWAPL(&txf->max_ascent, tmp); - SWAPL(&txf->max_descent, tmp); - SWAPL(&txf->num_glyphs, tmp); - } - txf->tgi = (TexGlyphInfo *) malloc(txf->num_glyphs * sizeof(TexGlyphInfo)); - if (txf->tgi == NULL) { - lastError = "out of memory."; - goto error; - } - assert(sizeof(TexGlyphInfo) == 12); /* Ensure external file format size. */ - got = fread(txf->tgi, sizeof(TexGlyphInfo), txf->num_glyphs, file); - EXPECT(txf->num_glyphs); - - if (swap) { - for (i = 0; i < txf->num_glyphs; i++) { - SWAPS(&txf->tgi[i].c, tmp); - SWAPS(&txf->tgi[i].x, tmp); - SWAPS(&txf->tgi[i].y, tmp); - } - } - txf->tgvi = (TexGlyphVertexInfo *) - malloc(txf->num_glyphs * sizeof(TexGlyphVertexInfo)); - if (txf->tgvi == NULL) { - lastError = "out of memory."; - goto error; - } - w = txf->tex_width; - h = txf->tex_height; - txf->max_width = 0; - xstep = 0.5 / w; - ystep = 0.5 / h; - for (i = 0; i < txf->num_glyphs; i++) { - TexGlyphInfo *tgi; - - tgi = &txf->tgi[i]; - txf->tgvi[i].t0[0] = tgi->x / w - xstep; // MT - xstep - txf->tgvi[i].t0[1] = tgi->y / h - ystep; // MT - ystep - txf->tgvi[i].v0[0] = tgi->xoffset; - txf->tgvi[i].v0[1] = tgi->yoffset; - txf->tgvi[i].t1[0] = (tgi->x + tgi->width) / w + xstep; - txf->tgvi[i].t1[1] = tgi->y / h - ystep; // MT - ystep - txf->tgvi[i].v1[0] = tgi->xoffset + tgi->width; - txf->tgvi[i].v1[1] = tgi->yoffset; - txf->tgvi[i].t2[0] = (tgi->x + tgi->width) / w + xstep; - txf->tgvi[i].t2[1] = (tgi->y + tgi->height) / h + ystep; - txf->tgvi[i].v2[0] = tgi->xoffset + tgi->width; - txf->tgvi[i].v2[1] = tgi->yoffset + tgi->height; - txf->tgvi[i].t3[0] = tgi->x / w - xstep; // MT - xstep - txf->tgvi[i].t3[1] = (tgi->y + tgi->height) / h + ystep; - txf->tgvi[i].v3[0] = tgi->xoffset; - txf->tgvi[i].v3[1] = tgi->yoffset + tgi->height; - txf->tgvi[i].advance = tgi->advance; - - if(tgi->width > txf->max_width) txf->max_width = tgi->width; - } - - min_glyph = txf->tgi[0].c; - max_glyph = txf->tgi[0].c; - for (i = 1; i < txf->num_glyphs; i++) { - if (txf->tgi[i].c < min_glyph) { - min_glyph = txf->tgi[i].c; - } - if (txf->tgi[i].c > max_glyph) { - max_glyph = txf->tgi[i].c; - } - } - txf->min_glyph = min_glyph; - txf->range = max_glyph - min_glyph + 1; - - txf->lut = (TexGlyphVertexInfo **) - calloc(txf->range, sizeof(TexGlyphVertexInfo *)); - if (txf->lut == NULL) { - lastError = "out of memory."; - goto error; - } - for (i = 0; i < txf->num_glyphs; i++) { - txf->lut[txf->tgi[i].c - txf->min_glyph] = &txf->tgvi[i]; - } - - switch (format) { - case TXF_FORMAT_BYTE: - if (useLuminanceAlpha) { - unsigned char *orig; - - orig = (unsigned char *) malloc(txf->tex_width * txf->tex_height); - if (orig == NULL) { - lastError = "out of memory."; - goto error; - } - got = fread(orig, 1, txf->tex_width * txf->tex_height, file); - EXPECT(txf->tex_width * txf->tex_height); - txf->teximage = (unsigned char *) - malloc(2 * txf->tex_width * txf->tex_height); - if (txf->teximage == NULL) { - lastError = "out of memory."; - goto error; - } - for (i = 0; i < txf->tex_width * txf->tex_height; i++) { - txf->teximage[i * 2] = orig[i]; - txf->teximage[i * 2 + 1] = orig[i]; - } - free(orig); - } else { - txf->teximage = (unsigned char *) - malloc(txf->tex_width * txf->tex_height); - if (txf->teximage == NULL) { - lastError = "out of memory."; - goto error; - } - got = fread(txf->teximage, 1, txf->tex_width * txf->tex_height, file); - EXPECT(txf->tex_width * txf->tex_height); - } - break; - case TXF_FORMAT_BITMAP: - width = txf->tex_width; - height = txf->tex_height; - stride = (width + 7) >> 3; - texbitmap = (unsigned char *) malloc(stride * height); - if (texbitmap == NULL) { - lastError = "out of memory."; - goto error; - } - got = fread(texbitmap, 1, stride * height, file); - EXPECT(stride * height); - if (useLuminanceAlpha) { - txf->teximage = (unsigned char *) calloc(width * height * 2, 1); - if (txf->teximage == NULL) { - lastError = "out of memory."; - goto error; - } - for (i = 0; i < height; i++) { - for (j = 0; j < width; j++) { - if (texbitmap[i * stride + (j >> 3)] & (1 << (j & 7))) { - txf->teximage[(i * width + j) * 2] = 255; - txf->teximage[(i * width + j) * 2 + 1] = 255; - } - } - } - } else { - txf->teximage = (unsigned char *) calloc(width * height, 1); - if (txf->teximage == NULL) { - lastError = "out of memory."; - goto error; - } - for (i = 0; i < height; i++) { - for (j = 0; j < width; j++) { - if (texbitmap[i * stride + (j >> 3)] & (1 << (j & 7))) { - txf->teximage[i * width + j] = 255; - } - } - } - } - free(texbitmap); - break; - } - - fclose(file); - return txf; - -error: - - if (txf) { - if (txf->tgi) - free(txf->tgi); - if (txf->tgvi) - free(txf->tgvi); - if (txf->lut) - free(txf->lut); - if (txf->teximage) - free(txf->teximage); - free(txf); - } - if (file) - fclose(file); - return NULL; -} - -/**************************************************************************/ - -GLuint txfEstablishTexture(TexFont * txf, GLuint texobj, - GLboolean setupMipmaps) -{ - if (txf->texobj == 0) { - if (texobj == 0) { - glGenTextures(1, &txf->texobj); - } else { - txf->texobj = texobj; - } - } - glBindTexture(GL_TEXTURE_2D, txf->texobj); - - if (useLuminanceAlpha) { - if (setupMipmaps) { - gluBuild2DMipmaps(GL_TEXTURE_2D, GL_LUMINANCE_ALPHA, - txf->tex_width, txf->tex_height, - GL_LUMINANCE_ALPHA, GL_UNSIGNED_BYTE, txf->teximage); - } else { - glTexImage2D(GL_TEXTURE_2D, 0, GL_LUMINANCE_ALPHA, - txf->tex_width, txf->tex_height, 0, - GL_LUMINANCE_ALPHA, GL_UNSIGNED_BYTE, txf->teximage); - } - } else { - if (setupMipmaps) { - gluBuild2DMipmaps(GL_TEXTURE_2D, GL_INTENSITY4, - txf->tex_width, txf->tex_height, - GL_LUMINANCE, GL_UNSIGNED_BYTE, txf->teximage); - } else { - glTexImage2D(GL_TEXTURE_2D, 0, GL_INTENSITY4, - txf->tex_width, txf->tex_height, 0, - GL_LUMINANCE, GL_UNSIGNED_BYTE, txf->teximage); - } - } - - // MT: tried changing MIN/MAG filters ... bad idea. - - return txf->texobj; -} - -/**************************************************************************/ - -void txfBindFontTexture(TexFont * txf) -{ - glBindTexture(GL_TEXTURE_2D, txf->texobj); -} - -/**************************************************************************/ - -void txfUnloadFont(TexFont * txf) -{ - if (txf->texobj) { - glDeleteTextures(1, &txf->texobj); - } - if (txf->teximage) { - free(txf->teximage); - } - free(txf->tgi); - free(txf->tgvi); - free(txf->lut); - free(txf); -} - -/**************************************************************************/ - -void txfGetStringMetrics(TexFont * txf, const char *TString, int len, - int &width, int &max_ascent, int &max_descent) -{ - TexGlyphVertexInfo *tgvi; - int w, i; - int ma = 0, md = 0; - - w = 0; - for (i = 0; i < len; i++) { - if (TString[i] == 27) { - switch (TString[i + 1]) { - case 'M': - i += 4; - break; - case 'T': - i += 7; - break; - case 'L': - i += 7; - break; - case 'F': - i += 13; - break; - } - } else { - tgvi = getTCVI(txf, TString[i]); - w += int(tgvi->advance); - ma = TMath::Max(ma, (int)( tgvi->v3[1])); - md = TMath::Max(md, (int)(-tgvi->v0[1])); - } - } - width = w; - max_ascent = ma; // txf->max_ascent; - max_descent = md; // txf->max_descent; - // printf("%d %d %d %d\n", txf->max_ascent, txf->max_descent, ma, md); -} - -/**************************************************************************/ - -void txfRenderGlyph(TexFont * txf, int c) -{ - TexGlyphVertexInfo *tgvi; - - tgvi = getTCVI(txf, c); - glBegin(GL_QUADS); - glTexCoord2fv(tgvi->t0); - glVertex2sv(tgvi->v0); - glTexCoord2fv(tgvi->t1); - glVertex2sv(tgvi->v1); - glTexCoord2fv(tgvi->t2); - glVertex2sv(tgvi->v2); - glTexCoord2fv(tgvi->t3); - glVertex2sv(tgvi->v3); - glEnd(); - glTranslatef(tgvi->advance, 0.0, 0.0); -} - -void txfRenderString(TexFont * txf, const char *TString, int len, - bool keep_pos) -{ - int i; - if(keep_pos) glPushMatrix(); - for (i = 0; i < len; i++) { - txfRenderGlyph(txf, TString[i]); - } - if(keep_pos) glPopMatrix(); -} - -void txfRenderString(TexFont * txf, const char *TString, int len, - GLfloat maxx, GLfloat fadew, - bool keep_pos) -{ - GLfloat x = 0, xg0, xg1, yg0, yg1, f0, f1; - fadew *= txf->max_width; - GLfloat xfade = maxx - fadew; - - GLfloat col[4]; - glGetFloatv(GL_CURRENT_COLOR, col); - - glBegin(GL_QUADS); - for (int i = 0; i < len; i++) { - - TexGlyphVertexInfo *tgvi; - - tgvi = getTCVI(txf, TString[i]); - - xg0 = x + tgvi->v0[0]; - xg1 = x + tgvi->v1[0]; - yg0 = tgvi->v0[1]; - yg1 = tgvi->v2[1]; - - if(xg1 > xfade) { - f0 = 1; if(xg0 > xfade) f0 *= 1 - (xg0-xfade)/fadew; - f1 = 1 - (xg1-xfade)/fadew; - - // printf("XX %s %c %f %f x(%f,%f) y(%f,%f)\n", - // TString, TString[i], f0, f1, - // xg0, xg1,yg0, yg1); - - glColor4f(f0*col[0], f0*col[1], f0*col[2], f0*col[3]); - glTexCoord2fv(tgvi->t0); glVertex2f(xg0, yg0); - glColor4f(f1*col[0], f1*col[1], f1*col[2], f1*col[3]); - glTexCoord2fv(tgvi->t1); glVertex2f(xg1, yg0); - glTexCoord2fv(tgvi->t2); glVertex2f(xg1, yg1); - glColor4f(f0*col[0], f0*col[1], f0*col[2], f0*col[3]); - glTexCoord2fv(tgvi->t3); glVertex2f(xg0, yg1); - } else { - glTexCoord2fv(tgvi->t0); glVertex2f(xg0, yg0); - glTexCoord2fv(tgvi->t1); glVertex2f(xg1, yg0); - glTexCoord2fv(tgvi->t2); glVertex2f(xg1, yg1); - glTexCoord2fv(tgvi->t3); glVertex2f(xg0, yg1); - } - - x += tgvi->advance; - if(x > maxx) break; - } - glEnd(); - - if(!keep_pos) glTranslatef(x, 0.0, 0.0); -} - -/**************************************************************************/ - -void txfRenderGlyphZW(TexFont * txf, int c, float z, float w) -{ - TexGlyphVertexInfo *tgvi; - - tgvi = getTCVI(txf, c); - glBegin(GL_QUADS); - glTexCoord2fv(tgvi->t0); - glVertex4f(tgvi->v0[0], tgvi->v0[1], z, w); - glTexCoord2fv(tgvi->t1); - glVertex4f(tgvi->v1[0], tgvi->v1[1], z, w); - glTexCoord2fv(tgvi->t2); - glVertex4f(tgvi->v2[0], tgvi->v2[1], z, w); - glTexCoord2fv(tgvi->t3); - glVertex4f(tgvi->v3[0], tgvi->v3[1], z, w); - glEnd(); - glTranslatef(tgvi->advance, 0.0, 0.0); -} - -void txfRenderStringZW(TexFont * txf, const char *TString, int len, - float z, float w, bool keep_pos) -{ - int i; - - if(keep_pos) glPushMatrix(); - for (i = 0; i < len; i++) { - txfRenderGlyphZW(txf, TString[i], z, w); - } - if(keep_pos) glPopMatrix(); -} - -/**************************************************************************/ - -enum { - MONO, TOP_BOTTOM, LEFT_RIGHT, FOUR -}; - -/**************************************************************************/ - -void txfRenderFancyString(TexFont * txf, char *TString, int len) -{ - TexGlyphVertexInfo *tgvi; - GLubyte c[4][3]; - int mode = MONO; - int i; - - for (i = 0; i < len; i++) { - if (TString[i] == 27) { - switch (TString[i + 1]) { - case 'M': - mode = MONO; - glColor3ubv((GLubyte *) & TString[i + 2]); - i += 4; - break; - case 'T': - mode = TOP_BOTTOM; - memcpy(c, &TString[i + 2], 6); - i += 7; - break; - case 'L': - mode = LEFT_RIGHT; - memcpy(c, &TString[i + 2], 6); - i += 7; - break; - case 'F': - mode = FOUR; - memcpy(c, &TString[i + 2], 12); - i += 13; - break; - } - } else { - switch (mode) { - case MONO: - txfRenderGlyph(txf, TString[i]); - break; - case TOP_BOTTOM: - tgvi = getTCVI(txf, TString[i]); - glBegin(GL_QUADS); - glColor3ubv(c[0]); - glTexCoord2fv(tgvi->t0); - glVertex2sv(tgvi->v0); - glTexCoord2fv(tgvi->t1); - glVertex2sv(tgvi->v1); - glColor3ubv(c[1]); - glTexCoord2fv(tgvi->t2); - glVertex2sv(tgvi->v2); - glTexCoord2fv(tgvi->t3); - glVertex2sv(tgvi->v3); - glEnd(); - glTranslatef(tgvi->advance, 0.0, 0.0); - break; - case LEFT_RIGHT: - tgvi = getTCVI(txf, TString[i]); - glBegin(GL_QUADS); - glColor3ubv(c[0]); - glTexCoord2fv(tgvi->t0); - glVertex2sv(tgvi->v0); - glColor3ubv(c[1]); - glTexCoord2fv(tgvi->t1); - glVertex2sv(tgvi->v1); - glColor3ubv(c[1]); - glTexCoord2fv(tgvi->t2); - glVertex2sv(tgvi->v2); - glColor3ubv(c[0]); - glTexCoord2fv(tgvi->t3); - glVertex2sv(tgvi->v3); - glEnd(); - glTranslatef(tgvi->advance, 0.0, 0.0); - break; - case FOUR: - tgvi = getTCVI(txf, TString[i]); - glBegin(GL_QUADS); - glColor3ubv(c[0]); - glTexCoord2fv(tgvi->t0); - glVertex2sv(tgvi->v0); - glColor3ubv(c[1]); - glTexCoord2fv(tgvi->t1); - glVertex2sv(tgvi->v1); - glColor3ubv(c[2]); - glTexCoord2fv(tgvi->t2); - glVertex2sv(tgvi->v2); - glColor3ubv(c[3]); - glTexCoord2fv(tgvi->t3); - glVertex2sv(tgvi->v3); - glEnd(); - glTranslatef(tgvi->advance, 0.0, 0.0); - break; - } - } - } -} - -/**************************************************************************/ - -int txfInFont(TexFont * txf, int c) -{ - /* NOTE: No uppercase/lowercase substituion. */ - if ((c >= txf->min_glyph) && (c < txf->min_glyph + txf->range)) { - if (txf->lut[c - txf->min_glyph]) { - return 1; - } - } - return 0; -} - -/**************************************************************************/ - -bool LoadDefaultFont( TString file) -{ - static const Exc_t _eh("GLTextNS::LoadFont "); - - if(fgDefaultFont) { - txfUnloadFont(fgDefaultFont); - fgDefaultFont = 0; - } - - fgDefaultFont = GLTextNS::txfLoadFont(file.Data()); - if(fgDefaultFont != 0) { - txfEstablishTexture(fgDefaultFont, 0, GL_TRUE); - return true; - } - else { - throw(_eh + Form("Error loading font from file '%s': %s", - file.Data(), txfErrorString())); - } - - return false; -} - -} // end GLTextNS diff --git a/EVE/Reve/GLTextNS.h b/EVE/Reve/GLTextNS.h deleted file mode 100644 index 42b193d5177..00000000000 --- a/EVE/Reve/GLTextNS.h +++ /dev/null @@ -1,149 +0,0 @@ - -#ifndef Reve_GLTextNS_H -#define Reve_GLTextNS_H - -// The following implementation is based on TexFont API, -// implementation and accompanying programs by Mark J. Kilgard. -// Original license: - -/* Copyright (c) Mark J. Kilgard, 1997. */ -/* This program is freely distributable without licensing fees and is - provided without guarantee or warrantee expressed or implied. This - program is -not- in the public domain. */ - -#ifndef __CINT__ - -#include -#include - -class TString; - -namespace GLTextNS { - -#define TXF_FORMAT_BYTE 0 -#define TXF_FORMAT_BITMAP 1 - -struct TexGlyphInfo { - unsigned short c; /* Potentially support 16-bit glyphs. */ - unsigned char width; - unsigned char height; - signed char xoffset; - signed char yoffset; - signed char advance; - char dummy; /* Space holder for alignment reasons. */ - short x; - short y; -}; - -struct TexGlyphVertexInfo { - GLfloat t0[2]; - GLshort v0[2]; - GLfloat t1[2]; - GLshort v1[2]; - GLfloat t2[2]; - GLshort v2[2]; - GLfloat t3[2]; - GLshort v3[2]; - GLfloat advance; -}; - -class TexFont : public TObject { -public: - GLuint texobj; - int tex_width; - int tex_height; - int max_ascent; - int max_descent; - int max_width; // max glyph width (MT) - int num_glyphs; - int min_glyph; - int range; - unsigned char *teximage; - TexGlyphInfo *tgi; - TexGlyphVertexInfo *tgvi; - TexGlyphVertexInfo **lut; - - int max_height() { return max_ascent + max_descent; } -}; - - -extern char *txfErrorString(void); - -extern TexFont *txfLoadFont(const char *filename); - -extern void txfUnloadFont(TexFont* txf); - -extern GLuint txfEstablishTexture(TexFont* txf, GLuint texobj, - GLboolean setupMipmaps); - -extern void txfBindFontTexture(TexFont* txf); - -extern void txfGetStringMetrics(TexFont* txf, const char *TString, int len, - int &width, int &max_ascent, int &max_descent); - -extern void txfRenderGlyph(TexFont* txf, int c); -extern void txfRenderString(TexFont* txf, const char *TString, int len, - bool keep_pos=true); -extern void txfRenderString(TexFont* txf, const char *TString, int len, - GLfloat maxx, GLfloat fadew, - bool keep_pos=true); - -extern void txfRenderGlyphZW(TexFont* txf, int c, float z, float w); -extern void txfRenderStringZW(TexFont* txf, const char *TString, int len, - float z, float w, bool keep_pos=true); - -extern void txfRenderFancyString(TexFont* txf, char *TString, int len); - - -bool LoadDefaultFont(TString font_file); - -extern TexFont* fgDefaultFont; - -/**************************************************************************/ -// Here starts MT higher-level interface -/**************************************************************************/ -/* - struct BoxSpecs { - int lm, rm, tm, bm; - int lineskip; - char align; - TString pos; - - void _init() { align = 'l'; lineskip = 0; } - - BoxSpecs() - { lm = rm = 3; tm = 0; bm = 2; _init(); } - - BoxSpecs(int lr, int tb) - { lm = rm = lr; tm = bm = tb; _init(); } - - BoxSpecs(int l, int r, int t, int b) - { lm = l; rm = r; tm = t; bm = b; _init(); } - }; - struct TextLineData { - int width, ascent, descent, hfull; - TString text; - - TextLineData(TexFont *txf, TString line); - }; - - extern void RnrTextBar(RnrDriver* rd, const TString& text); - - extern void RnrTextBar(RnrDriver* rd, const TString& text, - BoxSpecs& bs, float zoffset=0); - - extern void RnrTextPoly(RnrDriver* rd, const TString& text); - - extern void RnrText(RnrDriver* rd, const TString& text, - int x, int y, float z, - const ZColor* front_col, const ZColor* back_col=0); - - extern void RnrTextAt(RnrDriver* rd, const TString& text, - int x, int yrow, float z, - const ZColor* front_col, const ZColor* back_col=0); -*/ - -} // namescape GLTextNS - -#endif // cint -#endif // Reve_GLTextNS_H diff --git a/EVE/Reve/GLUtilNS.cxx b/EVE/Reve/GLUtilNS.cxx deleted file mode 100644 index 641040d3239..00000000000 --- a/EVE/Reve/GLUtilNS.cxx +++ /dev/null @@ -1,200 +0,0 @@ -#include "GLUtilNS.h" -#include "Reve.h" - -#include -#include -#include - -namespace GLUtilNS { - -void RenderLine(const TAttLine& aline, Float_t* p, Int_t n, - Bool_t /*selection*/, Bool_t /*sec_selection*/) -{ - if(n == 0) return; - - glPushAttrib(GL_ENABLE_BIT | GL_LINE_BIT); - glDisable(GL_LIGHTING); - glColorMaterial(GL_FRONT_AND_BACK, GL_DIFFUSE); - glEnable(GL_COLOR_MATERIAL); - UChar_t color[4]; - Reve::ColorFromIdx(aline.GetLineColor(), color); - glColor4ubv(color); - glLineWidth(aline.GetLineWidth()); - if (aline.GetLineStyle() > 1) { - Int_t fac = 1; - UShort_t pat = 0xffff; - switch (aline.GetLineStyle()) { - case 2: pat = 0x3333; break; - case 3: pat = 0x5555; break; - case 4: pat = 0xf040; break; - case 5: pat = 0xf4f4; break; - case 6: pat = 0xf111; break; - case 7: pat = 0xf0f0; break; - case 8: pat = 0xff11; break; - case 9: pat = 0x3fff; break; - case 10: pat = 0x08ff; fac = 2; break; - } - - glLineStipple(1, pat); - glEnable(GL_LINE_STIPPLE); - } - - Float_t* tp = p; - glBegin(GL_LINE_STRIP); - for (Int_t i=0; i sPickRadius) - { - changePM = kTRUE; - glMatrixMode(GL_PROJECTION); - glPushMatrix(); - Float_t pm[16]; - glGetFloatv(GL_PROJECTION_MATRIX, pm); - Float_t scale = (Float_t) sPickRadius / size; - for (Int_t i=0; i<=12; i+=4) { - pm[i] *= scale; pm[i+1] *= scale; - } - glLoadMatrixf(pm); - } - - Float_t* p = op; - if (sec_selection) - { - glPushName(0); - for (Int_t i=0; i maxChunk) - { - glDrawArrays(GL_POINTS, ndone, maxChunk); - nleft -= maxChunk; - ndone += maxChunk; - } - glDrawArrays(GL_POINTS, ndone, nleft); - } - glPopClientAttrib(); - } - - if (changePM) - { - glPopMatrix(); - glMatrixMode(GL_MODELVIEW); - } - -} - -//______________________________________________________________________________ -void RenderCrosses(const TAttMarker& marker, Float_t* op, Int_t n, - Bool_t sec_selection) -{ - // Render markers as crosses. - // - if (marker.GetMarkerStyle() == 28) - { - glEnable(GL_BLEND); - glEnable(GL_LINE_SMOOTH); - glLineWidth(2); - } - else - { - glDisable(GL_LINE_SMOOTH); - } - - // cross dim - const Float_t d = 2*marker.GetMarkerSize(); - Float_t* p = op; - if (sec_selection) - { - glPushName(0); - for (Int_t i=0; i -#include - -class TAttMarker; -class TAttLine; - -namespace GLUtilNS -{ - -class GL_Capability_Switch { - GLenum fWhat; - GLboolean fState; - bool fFlip; - - void set_state(GLboolean s) - { if(s) glEnable(fWhat); else glDisable(fWhat); } - -public: - GL_Capability_Switch(GLenum what, GLboolean state) : - fWhat(what), fState(kFALSE), fFlip(kFALSE) - { - fState = glIsEnabled(fWhat); - fFlip = (fState != state); - if(fFlip) set_state(state); - } - ~GL_Capability_Switch() - { if(fFlip) set_state(fState); } -}; - -class GL_Float_Holder -{ - GL_Float_Holder(const GL_Float_Holder&); // Not implemented - GL_Float_Holder& operator=(const GL_Float_Holder&); // Not implemented - - GLenum fWhat; - GLfloat fState; - bool fFlip; - void (*fFoo)(GLfloat); - -public: - GL_Float_Holder(GLenum what, GLfloat state, void (*foo)(GLfloat)) : - fWhat(what), fState(kFALSE), fFlip(kFALSE), fFoo(foo) - { - glGetFloatv(fWhat, &fState); - fFlip = (fState != state); - if(fFlip) fFoo(state); - } - ~GL_Float_Holder() - { if(fFlip) fFoo(fState); } -}; - -void RenderLine(const TAttLine& al, Float_t* p, Int_t n, - Bool_t selection=kFALSE, Bool_t sec_selection=kFALSE); - -void RenderPolyMarkers(const TAttMarker& marker, Float_t* p, Int_t n, - Bool_t selection=kFALSE, Bool_t sec_selection=kFALSE); - -void RenderPoints(const TAttMarker& marker, Float_t* p, Int_t n, - Bool_t selection=kFALSE, Bool_t sec_selection=kFALSE); - -void RenderCrosses(const TAttMarker& marker, Float_t* p, Int_t n, Bool_t sec_selection=kFALSE); - -} - -#endif -#endif diff --git a/EVE/Reve/GeoNode.cxx b/EVE/Reve/GeoNode.cxx deleted file mode 100644 index de23c0c3ec3..00000000000 --- a/EVE/Reve/GeoNode.cxx +++ /dev/null @@ -1,536 +0,0 @@ -// $Header$ - -#include "GeoNode.h" -#include -#include - -#include "TGeoShapeExtract.h" -#include "TGeoMatrix.h" - -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include - -using namespace Reve; - - -//______________________________________________________________________ -// GeoNodeRnrEl -// - -ClassImp(GeoNodeRnrEl) - -GeoNodeRnrEl::GeoNodeRnrEl(TGeoNode* node) : - RenderElement(), - TObject(), - fNode(node) -{ - // Hack!! Should use cint to retrieve TAttLine::fLineColor offset. - char* l = (char*) dynamic_cast(node->GetVolume()); - SetMainColorPtr((Color_t*)(l + sizeof(void*))); - - fRnrSelf = fNode->TGeoAtt::IsVisible(); -} - -const Text_t* GeoNodeRnrEl::GetName() const { return fNode->GetName(); } -const Text_t* GeoNodeRnrEl::GetTitle() const { return fNode->GetTitle(); } - -/**************************************************************************/ - -Int_t GeoNodeRnrEl::ExpandIntoListTree(TGListTree* ltree, - TGListTreeItem* parent) -{ - // Checks if child-nodes have been imported ... imports them if not. - // Then calls RenderElement::ExpandIntoListTree. - - if(fChildren.empty() && fNode->GetVolume()->GetNdaughters() > 0) { - TIter next(fNode->GetVolume()->GetNodes()); - TGeoNode* dnode; - while((dnode = (TGeoNode*) next()) != 0) { - GeoNodeRnrEl* node_re = new GeoNodeRnrEl(dnode); - AddElement(node_re); - } - } - return RenderElement::ExpandIntoListTree(ltree, parent); -} - -/**************************************************************************/ - -void GeoNodeRnrEl::SetRnrSelf(Bool_t rnr) -{ - RenderElement::SetRnrSelf(rnr); - fNode->SetVisibility(rnr); -} - -void GeoNodeRnrEl::SetRnrChildren(Bool_t rnr) -{ - RenderElement::SetRnrChildren(rnr); - fNode->VisibleDaughters(rnr); -} - -void GeoNodeRnrEl::SetRnrState(Bool_t rnr) -{ - RenderElement::SetRnrState(rnr); - fNode->SetVisibility(rnr); - fNode->VisibleDaughters(rnr); -} - -/**************************************************************************/ - -void GeoNodeRnrEl::SetMainColor(Color_t color) -{ - fNode->GetVolume()->SetLineColor(color); - UpdateItems(); -} - -void GeoNodeRnrEl::SetMainColor(Pixel_t pixel) -{ - // This one needed for proper calling via CINT (signals). - - SetMainColor(Color_t(TColor::GetColor(pixel))); -} - -/**************************************************************************/ - -void GeoNodeRnrEl::UpdateNode(TGeoNode* node) -{ - // Updates all reve-browsers having the node in their contents. - // All 3D-pads updated if any change found. - // - // Should (could?) be optimized with some assumptions about - // volume/node structure (search for parent, know the same node can not - // reoccur on lower level once found). - - static const Exc_t eH("GeoNodeRnrEl::UpdateNode "); - - // printf("%s node %s %p\n", eH.Data(), node->GetName(), node); - - if(fNode == node) - UpdateItems(); - - for(List_i i=fChildren.begin(); i!=fChildren.end(); ++i) { - ((GeoNodeRnrEl*)(*i))->UpdateNode(node); - } - -} - -void GeoNodeRnrEl::UpdateVolume(TGeoVolume* volume) -{ - // Updates all reve-browsers having the volume in their contents. - // All 3D-pads updated if any change found. - // - // Should (could?) be optimized with some assumptions about - // volume/node structure (search for parent, know the same node can not - // reoccur on lower level once found). - - static const Exc_t eH("GeoNodeRnrEl::UpdateVolume "); - - // printf("%s volume %s %p\n", eH.Data(), volume->GetName(), volume); - - if(fNode->GetVolume() == volume) - UpdateItems(); - - for(List_i i=fChildren.begin(); i!=fChildren.end(); ++i) { - ((GeoNodeRnrEl*)(*i))->UpdateVolume(volume); - } -} - -/**************************************************************************/ - -void GeoNodeRnrEl::Draw(Option_t* option) -{ - TString opt("SAME"); - opt += option; - fNode->GetVolume()->Draw(opt); -} - -/**************************************************************************/ - -void GeoNodeRnrEl::Save(const char* file, const char* name) -{ - TGeoShapeExtract* gse = DumpShapeTree(this, 0, 0); - - TFile f(file, "RECREATE"); - gse->Write(name); - f.Close(); -} - -/**************************************************************************/ - -TGeoShapeExtract* GeoNodeRnrEl::DumpShapeTree(GeoNodeRnrEl* geon, TGeoShapeExtract* parent, Int_t level) -{ - printf("dump_shape_tree %s \n", geon->GetName()); - TGeoNode* tnode = 0; - TGeoVolume* tvolume = 0; - TGeoShape* tshape = 0; - - tnode = geon->GetNode(); - if(tnode == 0) { - printf("Null node for %s; assuming it's a holder and descending.\n", geon->GetName()); - goto do_dump; - } - - tvolume = tnode->GetVolume(); - if(tvolume == 0) { - printf("Null volume for %s; skipping.\n", geon->GetName()); - return 0; - } - - tshape = tvolume->GetShape(); - -do_dump: - // transformation - ZTrans trans; - if (parent) if (parent) trans.SetFromArray(parent->GetTrans()); - TGeoMatrix* gm = tnode->GetMatrix(); - const Double_t* rm = gm->GetRotationMatrix(); - const Double_t* tv = gm->GetTranslation(); - ZTrans t; - t(1,1) = rm[0]; t(1,2) = rm[1]; t(1,3) = rm[2]; - t(2,1) = rm[3]; t(2,2) = rm[4]; t(2,3) = rm[5]; - t(3,1) = rm[6]; t(3,2) = rm[7]; t(3,3) = rm[8]; - t(1,4) = tv[0]; t(2,4) = tv[1]; t(3,4) = tv[2]; - trans *= t; - - TGeoShapeExtract* gse = new TGeoShapeExtract(geon->GetName(), geon->GetTitle()); - gse->SetTrans(trans.Array()); - Int_t ci = 0; - if(tvolume) ci = tvolume->GetLineColor(); - TColor* c = gROOT->GetColor(ci); - Float_t rgba[4] = {1, 0, 0, 1}; - if (c) { - rgba[0] = c->GetRed(); - rgba[1] = c->GetGreen(); - rgba[2] = c->GetBlue(); - } - gse->SetRGBA(rgba); - Bool_t rnr = geon->GetRnrSelf(); - if(level > gGeoManager->GetVisLevel()) - rnr = kFALSE; - gse->SetRnrSelf(rnr); - gse->SetRnrElements(geon->GetRnrChildren()); - - if(dynamic_cast(tshape)){ - // printf("SetShape(tshape); - level ++; - if ( geon->GetNChildren()) - { - TList* ele = new TList(); - gse->SetElements(ele); - gse->GetElements()->SetOwner(true); - - RenderElement::List_i i = geon->BeginChildren(); - while (i != geon->EndChildren()) { - GeoNodeRnrEl* l = dynamic_cast(*i); - DumpShapeTree(l, gse, level+1); - i++; - } - } - - if(parent) - parent->GetElements()->Add(gse); - - return gse; -} -/**************************************************************************/ -//______________________________________________________________________ -// GeoTopNodeRnrEl -// -// A wrapper over a TGeoNode, possibly displaced with a global -// trasformation fGlobalTrans (the matrix is owned by this class). -/**************************************************************************/ - -ClassImp(GeoTopNodeRnrEl) - -GeoTopNodeRnrEl::GeoTopNodeRnrEl(TGeoManager* manager, TGeoNode* node, - Int_t visopt, Int_t vislvl) : - GeoNodeRnrEl (node), - fManager (manager), - fGlobalTrans (), - fVisOption (visopt), - fVisLevel (vislvl) -{ - fRnrSelf = true; -} - -GeoTopNodeRnrEl::~GeoTopNodeRnrEl() -{} - -/**************************************************************************/ - -void GeoTopNodeRnrEl::SetGlobalTrans(const TGeoHMatrix* m) -{ - fGlobalTrans.SetFrom(*m); -} - -void GeoTopNodeRnrEl::UseNodeTrans() -{ - fGlobalTrans.SetFrom(*fNode->GetMatrix()); -} - -/**************************************************************************/ - -void GeoTopNodeRnrEl::SetVisOption(Int_t visopt) -{ - fVisOption = visopt; - gReve->Redraw3D(); -} - -void GeoTopNodeRnrEl::SetVisLevel(Int_t vislvl) -{ - fVisLevel = vislvl; - gReve->Redraw3D(); -} - -/**************************************************************************/ - -void GeoTopNodeRnrEl::SetRnrSelf(Bool_t rnr) -{ - // Revert from GeoNode to back to standard behaviour. - RenderElement::SetRnrSelf(rnr); -} - -/**************************************************************************/ - -void GeoTopNodeRnrEl::Draw(Option_t* option) -{ - AppendPad(option); -} - -void GeoTopNodeRnrEl::Paint(Option_t* option) -{ - if(fRnrSelf) { - gGeoManager = fManager; - TVirtualPad* pad = gPad; - gPad = 0; - TGeoVolume* top_volume = fManager->GetTopVolume(); - fManager->SetVisOption(fVisOption); - fManager->SetVisLevel(fVisLevel); - fManager->SetTopVolume(fNode->GetVolume()); - gPad = pad; - TVirtualGeoPainter* vgp = fManager->GetGeomPainter(); - if(vgp != 0) { - TGeoHMatrix geomat; - fGlobalTrans.SetGeoHMatrix(geomat); - vgp->PaintNode(fNode, option, &geomat); - } - fManager->SetTopVolume(top_volume); - } -} - -/**************************************************************************/ - -void GeoTopNodeRnrEl::VolumeVisChanged(TGeoVolume* volume) -{ - static const Exc_t eH("GeoTopNodeRnrEl::VolumeVisChanged "); - printf("%s volume %s %p\n", eH.Data(), volume->GetName(), (void*)volume); - UpdateVolume(volume); -} - -void GeoTopNodeRnrEl::VolumeColChanged(TGeoVolume* volume) -{ - static const Exc_t eH("GeoTopNodeRnrEl::VolumeColChanged "); - printf("%s volume %s %p\n", eH.Data(), volume->GetName(), (void*)volume); - UpdateVolume(volume); -} - -void GeoTopNodeRnrEl::NodeVisChanged(TGeoNode* node) -{ - static const Exc_t eH("GeoTopNodeRnrEl::NodeVisChanged "); - printf("%s node %s %p\n", eH.Data(), node->GetName(), (void*)node); - UpdateNode(node); -} - - -/**************************************************************************/ -//______________________________________________________________________ -// GeoShapeRnrEl -// -// Minimal shape-wrapper allowing import of stuff from gled and retaining -// user-set visibility, colors and transparency. -/**************************************************************************/ - -ClassImp(GeoShapeRnrEl) - -GeoShapeRnrEl::GeoShapeRnrEl(const Text_t* name, const Text_t* title) : - RenderElement(), - TNamed (name, title), - fHMTrans (), - fColor (0), - fTransparency (0), - fShape (0) -{ - fMainColorPtr = &fColor; -} - -GeoShapeRnrEl::~GeoShapeRnrEl() -{ - if (fShape) { - fShape->SetUniqueID(fShape->GetUniqueID() - 1); - if (fShape->GetUniqueID() == 0) - delete fShape; - } -} - -/**************************************************************************/ - -void GeoShapeRnrEl::Paint(Option_t* /*option*/) -{ - if (fShape == 0) - return; - - TBuffer3D& buff = (TBuffer3D&) fShape->GetBuffer3D - (TBuffer3D::kCore, false); - - buff.fID = this; - buff.fColor = fColor; - buff.fTransparency = fTransparency; - fHMTrans.SetBuffer3D(buff); - buff.fLocalFrame = kTRUE; // Always enforce local frame (no geo manager). - - fShape->GetBuffer3D(TBuffer3D::kBoundingBox | TBuffer3D::kShapeSpecific, true); - - Int_t reqSec = gPad->GetViewer3D()->AddObject(buff); - - if (reqSec != TBuffer3D::kNone) { - fShape->GetBuffer3D(reqSec, true); - reqSec = gPad->GetViewer3D()->AddObject(buff); - } - - if (reqSec != TBuffer3D::kNone) - printf("spooky reqSec=%d for %s\n", reqSec, GetName()); -} - -/**************************************************************************/ - -void GeoShapeRnrEl::Save(const char* file, const char* name) -{ - TGeoShapeExtract* gse = DumpShapeTree(this, 0); - - TFile f(file, "RECREATE"); - gse->Write(name); - f.Close(); -} - -/**************************************************************************/ - -TGeoShapeExtract* GeoShapeRnrEl::DumpShapeTree(GeoShapeRnrEl* gsre, TGeoShapeExtract* parent) -{ - // printf("dump_shape_tree %s \n", gsre->GetName()); - TGeoShapeExtract* she = new TGeoShapeExtract(gsre->GetName(), gsre->GetTitle()); - she->SetTrans(gsre->RefHMTrans().Array()); - Int_t ci = gsre->GetColor(); - TColor* c = gROOT->GetColor(ci); - Float_t rgba[4] = {1, 0, 0, 1 - gsre->GetMainTransparency()/100.}; - if (c) - { - rgba[0] = c->GetRed(); - rgba[1] = c->GetGreen(); - rgba[2] = c->GetBlue(); - } - she->SetRGBA(rgba); - she->SetRnrSelf(gsre->GetRnrSelf()); - she->SetRnrElements(gsre->GetRnrChildren()); - she->SetShape(gsre->GetShape()); - if ( gsre->GetNChildren()) - { - TList* ele = new TList(); - she->SetElements(ele); - she->GetElements()->SetOwner(true); - RenderElement::List_i i = gsre->BeginChildren(); - while (i != gsre->EndChildren()) { - GeoShapeRnrEl* l = dynamic_cast(*i); - DumpShapeTree(l, she); - i++; - } - } - if(parent) - parent->GetElements()->Add(she); - - return she; -} - -GeoShapeRnrEl* GeoShapeRnrEl::ImportShapeExtract(TGeoShapeExtract * gse, - RenderElement * parent) -{ - gReve->DisableRedraw(); - GeoShapeRnrEl* gsre = SubImportShapeExtract(gse, parent); - gsre->ElementChanged(); - gReve->EnableRedraw(); - return gsre; -} - - -GeoShapeRnrEl* GeoShapeRnrEl::SubImportShapeExtract(TGeoShapeExtract * gse, - RenderElement * parent) -{ - GeoShapeRnrEl* gsre = new GeoShapeRnrEl(gse->GetName(), gse->GetTitle()); - gsre->fHMTrans.SetFromArray(gse->GetTrans()); - const Float_t* rgba = gse->GetRGBA(); - gsre->fColor = TColor::GetColor(rgba[0], rgba[1], rgba[2]); - gsre->fTransparency = (UChar_t) (100.0f*(1.0f - rgba[3])); - gsre->SetRnrSelf(gse->GetRnrSelf()); - gsre->SetRnrChildren(gse->GetRnrElements()); - gsre->fShape = gse->GetShape(); - if (gsre->fShape) - gsre->fShape->SetUniqueID(gsre->fShape->GetUniqueID() + 1); - - gReve->AddGlobalRenderElement(gsre, parent); - - if (gse->HasElements()) - { - TIter next(gse->GetElements()); - TGeoShapeExtract* chld; - while ((chld = (TGeoShapeExtract*) next()) != 0) - SubImportShapeExtract(chld, gsre); - } - - return gsre; -} - -/**************************************************************************/ - -TClass* GeoShapeRnrEl::ProjectedClass() const -{ - return NLTPolygonSet::Class(); -} - -/**************************************************************************/ - -TBuffer3D* GeoShapeRnrEl::MakeBuffer3D() -{ - if(fShape == 0) return 0; - - if(dynamic_cast(fShape)){ - // !!!! TGeoShapeAssembly makes a bad TBuffer3D - return 0; - } - - TBuffer3D* buff = fShape->MakeBuffer3D(); - if (fHMTrans.GetUseTrans()) - { - Reve::ZTrans& mx = RefHMTrans(); - Int_t N = buff->NbPnts(); - Double_t* pnts = buff->fPnts; - for(Int_t k=0; k -#include -#include - -class TGeoVolume; -class TGeoNode; -class TGeoHMatrix; -class TGeoManager; - -class TGeoShape; -class TGeoShapeExtract; - -namespace Reve { - -class GeoNodeRnrEl : public RenderElement, - public TObject -{ - friend class GeoNodeRnrElEditor; - - GeoNodeRnrEl(const GeoNodeRnrEl&); // Not implemented - GeoNodeRnrEl& operator=(const GeoNodeRnrEl&); // Not implemented - -protected: - TGeoNode *fNode; - TGeoShapeExtract* DumpShapeTree(GeoNodeRnrEl* geon, TGeoShapeExtract* parent = 0, Int_t level = 0); -public: - GeoNodeRnrEl(TGeoNode* node); - - virtual const Text_t* GetName() const; - virtual const Text_t* GetTitle() const; - - TGeoNode* GetNode() const { return fNode; } - - virtual Int_t ExpandIntoListTree(TGListTree* ltree, TGListTreeItem* parent); - - virtual Bool_t CanEditRnrElement() { return false; } - virtual void SetRnrSelf(Bool_t rnr); - virtual void SetRnrChildren(Bool_t rnr); - virtual void SetRnrState(Bool_t rnr); - - virtual Bool_t CanEditMainColor() { return true; } - virtual void SetMainColor(Color_t color); - virtual void SetMainColor(Pixel_t pixel); - - void UpdateNode(TGeoNode* node); - void UpdateVolume(TGeoVolume* volume); - - void Save(const char* file, const char* name="Extract"); - - virtual void Draw(Option_t* option=""); - - ClassDef(GeoNodeRnrEl, 1); -}; // endclass GeoNodeRnrEl - -//---------------------------------------------------------------- - -class GeoTopNodeRnrEl : public GeoNodeRnrEl -{ - GeoTopNodeRnrEl(const GeoTopNodeRnrEl&); // Not implemented - GeoTopNodeRnrEl& operator=(const GeoTopNodeRnrEl&); // Not implemented - -protected: - TGeoManager* fManager; - ZTrans fGlobalTrans; - Int_t fVisOption; - Int_t fVisLevel; - -public: - GeoTopNodeRnrEl(TGeoManager* manager, TGeoNode* node, Int_t visopt=1, Int_t vislvl=3); - virtual ~GeoTopNodeRnrEl(); - - virtual Bool_t CanEditMainHMTrans() { return kTRUE; } - virtual ZTrans* PtrMainHMTrans() { return &fGlobalTrans; } - - ZTrans& RefGlobalTrans() { return fGlobalTrans; } - void SetGlobalTrans(const TGeoHMatrix* m); - void UseNodeTrans(); - - Int_t GetVisOption() const { return fVisOption; } - void SetVisOption(Int_t visopt); - Int_t GetVisLevel() const { return fVisLevel; } - void SetVisLevel(Int_t vislvl); - - virtual Bool_t CanEditRnrElement() { return true; } - virtual void SetRnrSelf(Bool_t rnr); - - virtual void Draw(Option_t* option=""); - virtual void Paint(Option_t* option=""); - - // Signals from GeoManager. - // These are not available any more ... colors in list-tree not refreshed - // properly. - void VolumeVisChanged(TGeoVolume* volume); - void VolumeColChanged(TGeoVolume* volume); - void NodeVisChanged(TGeoNode* node); - - ClassDef(GeoTopNodeRnrEl, 1); -}; // endclass GeoTopNodeRnrEl - - -//---------------------------------------------------------------- -//---------------------------------------------------------------- - -class GeoShapeRnrEl : public RenderElement, - public TNamed, - public NLTProjectable -{ - GeoShapeRnrEl(const GeoShapeRnrEl&); // Not implemented - GeoShapeRnrEl& operator=(const GeoShapeRnrEl&); // Not implemented - -protected: - ZTrans fHMTrans; - Color_t fColor; - UChar_t fTransparency; - TGeoShape* fShape; - - static GeoShapeRnrEl* SubImportShapeExtract(TGeoShapeExtract* gse, RenderElement* parent); - TGeoShapeExtract* DumpShapeTree(GeoShapeRnrEl* geon, TGeoShapeExtract* parent = 0); - -public: - GeoShapeRnrEl(const Text_t* name="GeoShapeRnrEl", const Text_t* title=0); - virtual ~GeoShapeRnrEl(); - - virtual Bool_t CanEditMainColor() { return kTRUE; } - - virtual Bool_t CanEditMainTransparency() { return kTRUE; } - virtual UChar_t GetMainTransparency() const { return fTransparency; } - virtual void SetMainTransparency(UChar_t t) { fTransparency = t; } - - virtual Bool_t CanEditMainHMTrans() { return kTRUE; } - virtual ZTrans* PtrMainHMTrans() { return &fHMTrans; } - - ZTrans& RefHMTrans() { return fHMTrans; } - void SetTransMatrix(Double_t* carr) { fHMTrans.SetFrom(carr); } - void SetTransMatrix(const TGeoMatrix& mat) { fHMTrans.SetFrom(mat); } - - Color_t GetColor() { return fColor; } - TGeoShape* GetShape() { return fShape; } - - virtual void Paint(Option_t* option=""); - - void Save(const char* file, const char* name="Extract"); - static GeoShapeRnrEl* ImportShapeExtract(TGeoShapeExtract* gse, RenderElement* parent); - - // NLTGeoProjectable - virtual TBuffer3D* MakeBuffer3D(); - virtual TClass* ProjectedClass() const; - - ClassDef(GeoShapeRnrEl, 1); -}; - -} - -#endif diff --git a/EVE/Reve/GeoNodeEditor.cxx b/EVE/Reve/GeoNodeEditor.cxx deleted file mode 100644 index 0d55c9dbe65..00000000000 --- a/EVE/Reve/GeoNodeEditor.cxx +++ /dev/null @@ -1,202 +0,0 @@ -// $Header$ - -#include "GeoNodeEditor.h" -#include "RGValuators.h" - -#include -#include - -#include -#include - -#include -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// GeoNodeRnrElEditor -// - -ClassImp(GeoNodeRnrElEditor) - -GeoNodeRnrElEditor::GeoNodeRnrElEditor(const TGWindow *p, - Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p,width, height, options | kVerticalFrame, back), - - fNodeRE (0), - - fVizNode(0), - fVizNodeDaughters(0), - fVizVolume(0), - fVizVolumeDaughters(0), - - fTransparency(0) -{ - MakeTitle("GeoNode"); - - // --- Visibility control - - fVizNode = new TGCheckButton(this, "VizNode"); - AddFrame(fVizNode, new TGLayoutHints(kLHintsTop, 3, 1, 1, 0)); - fVizNode->Connect - ("Toggled(Bool_t)", - "Reve::GeoNodeRnrElEditor", this, "DoVizNode()"); - - fVizNodeDaughters = new TGCheckButton(this, "VizNodeDaughters"); - AddFrame(fVizNodeDaughters, new TGLayoutHints(kLHintsTop, 3, 1, 1, 0)); - fVizNodeDaughters->Connect - ("Toggled(Bool_t)", - "Reve::GeoNodeRnrElEditor", this, "DoVizNodeDaughters()"); - - fVizVolume = new TGCheckButton(this, "VizVolume"); - AddFrame(fVizVolume, new TGLayoutHints(kLHintsTop, 3, 1, 1, 0)); - fVizVolume->Connect - ("Toggled(Bool_t)", - "Reve::GeoNodeRnrElEditor", this, "DoVizVolume()"); - - fVizVolumeDaughters = new TGCheckButton(this, "VizVolumeDaughters"); - AddFrame(fVizVolumeDaughters, new TGLayoutHints(kLHintsTop, 3, 1, 1, 0)); - fVizVolumeDaughters->Connect - ("Toggled(Bool_t)", - "Reve::GeoNodeRnrElEditor", this, "DoVizVolumeDaughters()"); - - - // --- Color props - - { - TGHorizontalFrame* f = new TGHorizontalFrame(this); - TGLabel *l = new TGLabel(f, "Transparency:"); - f->AddFrame(l, new TGLayoutHints(kLHintsLeft | kLHintsCenterY, 1, 2, 1, 1)); - fTransparency = new TGNumberEntry(f, 0., 6, -1, - TGNumberFormat::kNESInteger, TGNumberFormat::kNEANonNegative, - TGNumberFormat::kNELLimitMinMax, 0, 100); - fTransparency->GetNumberEntry()->SetToolTipText("0 is opaque, 100 fully transparent."); - f->AddFrame(fTransparency, new TGLayoutHints(kLHintsLeft, 1, 1, 1, 1)); - fTransparency->Connect("ValueSet(Long_t)", - "Reve::GeoNodeRnrElEditor", this, "DoTransparency()"); - AddFrame(f, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - } -} - -/**************************************************************************/ - -void GeoNodeRnrElEditor::SetModel(TObject* obj) -{ - fNodeRE = dynamic_cast(obj); - TGeoNode* node = fNodeRE->fNode; - TGeoVolume* vol = node->GetVolume(); - - fVizNode->SetState(node->TGeoAtt::IsVisible() ? kButtonDown : kButtonUp); - fVizNodeDaughters->SetState(node->TGeoAtt::IsVisDaughters() ? kButtonDown : kButtonUp); - fVizVolume->SetState(vol->IsVisible() ? kButtonDown : kButtonUp); - fVizVolumeDaughters->SetState(vol->IsVisDaughters() ? kButtonDown : kButtonUp); - - fTransparency->SetNumber(vol->GetTransparency()); -} - -/**************************************************************************/ - -void GeoNodeRnrElEditor::DoVizNode() -{ - fNodeRE->SetRnrSelf(fVizNode->IsOn()); - Update(); -} - -void GeoNodeRnrElEditor::DoVizNodeDaughters() -{ - fNodeRE->SetRnrChildren(fVizNodeDaughters->IsOn()); - Update(); -} - -void GeoNodeRnrElEditor::DoVizVolume() -{ - fNodeRE->fNode->GetVolume()->SetVisibility(fVizVolume->IsOn()); - Update(); -} - -void GeoNodeRnrElEditor::DoVizVolumeDaughters() -{ - fNodeRE->fNode->GetVolume()->VisibleDaughters(fVizVolumeDaughters->IsOn()); - Update(); -} - -/**************************************************************************/ - -void GeoNodeRnrElEditor::DoTransparency() -{ - fNodeRE->fNode->GetVolume()->SetTransparency(char(fTransparency->GetNumber())); - Update(); -} - - -/**************************************************************************/ -/**************************************************************************/ - -//______________________________________________________________________ -// GeoTopNodeRnrElEditor -// - -ClassImp(GeoTopNodeRnrElEditor) - -GeoTopNodeRnrElEditor::GeoTopNodeRnrElEditor(const TGWindow *p, - Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - - fTopNodeRE (0), - fVisOption (0), - fVisLevel (0) -{ - MakeTitle("GeoTopNode"); - - Int_t labelW = 58; - - fVisOption = new RGValuator(this, "VisOption:", 90, 0); - fVisOption->SetLabelWidth(labelW); - fVisOption->SetShowSlider(kFALSE); - fVisOption->SetNELength(4); - fVisOption->Build(); - fVisOption->SetLimits(0, 2, 10, TGNumberFormat::kNESInteger); - fVisOption->SetToolTip("Visualization option passed to TGeoPainter."); - fVisOption->Connect("ValueSet(Double_t)", "Reve::GeoTopNodeRnrElEditor", this, "DoVisOption()"); - AddFrame(fVisOption, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - - fVisLevel = new RGValuator(this, "VisLevel:", 90, 0); - fVisLevel->SetLabelWidth(labelW); - fVisLevel->SetShowSlider(kFALSE); - fVisLevel->SetNELength(4); - fVisLevel->Build(); - fVisLevel->SetLimits(0, 10, 10, TGNumberFormat::kNESInteger); - fVisLevel->SetToolTip("Level (depth) to which the geometry is traversed."); - fVisLevel->Connect("ValueSet(Double_t)", "Reve::GeoTopNodeRnrElEditor", this, "DoVisLevel()"); - AddFrame(fVisLevel, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); -} - -/**************************************************************************/ - -void GeoTopNodeRnrElEditor::SetModel(TObject* obj) -{ - fTopNodeRE = dynamic_cast(obj); - - fVisOption->SetValue(fTopNodeRE->GetVisOption()); - fVisLevel ->SetValue(fTopNodeRE->GetVisLevel()); -} - -/**************************************************************************/ - -void GeoTopNodeRnrElEditor::DoVisOption() -{ - fTopNodeRE->SetVisOption(Int_t(fVisOption->GetValue())); - Update(); -} - -void GeoTopNodeRnrElEditor::DoVisLevel() -{ - fTopNodeRE->SetVisLevel(Int_t(fVisLevel->GetValue())); - Update(); -} diff --git a/EVE/Reve/GeoNodeEditor.h b/EVE/Reve/GeoNodeEditor.h deleted file mode 100644 index 580addce4c0..00000000000 --- a/EVE/Reve/GeoNodeEditor.h +++ /dev/null @@ -1,79 +0,0 @@ -// $Header$ - -#ifndef REVE_GeoNodeEditor_H -#define REVE_GeoNodeEditor_H - -#include - -class TGCheckButton; -class TGNumberEntry; -class TGColorSelect; - -namespace Reve { - -class GeoNodeRnrEl; -class GeoTopNodeRnrEl; - -class RGValuator; - -class GeoNodeRnrElEditor : public TGedFrame -{ - GeoNodeRnrElEditor(const GeoNodeRnrElEditor&); // Not implemented - GeoNodeRnrElEditor& operator=(const GeoNodeRnrElEditor&); // Not implemented - -protected: - GeoNodeRnrEl* fNodeRE; - - TGCheckButton* fVizNode; - TGCheckButton* fVizNodeDaughters; - TGCheckButton* fVizVolume; - TGCheckButton* fVizVolumeDaughters; - - TGNumberEntry* fTransparency; - -public: - GeoNodeRnrElEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, - UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - virtual ~GeoNodeRnrElEditor() {} - - virtual void SetModel(TObject* obj); - - void DoVizNode(); - void DoVizNodeDaughters(); - void DoVizVolume(); - void DoVizVolumeDaughters(); - - void DoTransparency(); - - ClassDef(GeoNodeRnrElEditor, 1); -}; - -/**************************************************************************/ - -class GeoTopNodeRnrElEditor : public TGedFrame -{ - GeoTopNodeRnrElEditor(const GeoTopNodeRnrElEditor&); // Not implemented - GeoTopNodeRnrElEditor& operator=(const GeoTopNodeRnrElEditor&); // Not implemented - -protected: - GeoTopNodeRnrEl* fTopNodeRE; - - Reve::RGValuator* fVisOption; - Reve::RGValuator* fVisLevel; - -public: - GeoTopNodeRnrElEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, - UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - virtual ~GeoTopNodeRnrElEditor() {} - - virtual void SetModel(TObject* obj); - - void DoVisOption(); - void DoVisLevel(); - - ClassDef(GeoTopNodeRnrElEditor, 1); -}; - -} - -#endif diff --git a/EVE/Reve/GridStepper.cxx b/EVE/Reve/GridStepper.cxx deleted file mode 100644 index 4efb821c3fe..00000000000 --- a/EVE/Reve/GridStepper.cxx +++ /dev/null @@ -1,87 +0,0 @@ -// $Header$ - -#include "GridStepper.h" -#include "ZTrans.h" - -using namespace Reve; - -//______________________________________________________________________ -// GridStepper -// -// Provide position coordinates for regular-grid placement of objects. -// - -ClassImp(GridStepper) - -GridStepper::GridStepper(Int_t sm) : - Mode(StepMode_e(sm)), - nx(0), ny(0), nz(0), Nx(0), Ny(0), Nz(0), - Dx(0), Dy(0), Dz(0), Ox(0), Oy(0), Oz(0) -{ - switch(Mode) { - default: - case SM_XYZ: - ls[0] = &Nx; ls[1] = &Ny; ls[2] = &Nz; - ns[0] = &nx; ns[1] = &ny; ns[2] = &nz; - break; - case SM_YXZ: - ls[0] = &Ny; ls[1] = &Nx; ls[2] = &Nz; - ns[0] = &ny; ns[1] = &nx; ns[2] = &nz; - break; - case SM_XZY: - ls[0] = &Nx; ls[1] = &Nz; ls[2] = &Ny; - ns[0] = &nx; ns[1] = &nz; ns[2] = &ny; - break; - } - - nx = ny = nz = 0; - Nx = Ny = Nz = 16; - Dx = Dy = Dz = 1; - Ox = Oy = Oz = 0; -} - -void GridStepper::Reset() -{ - nx = ny = nz = 0; -} - -void GridStepper::Subtract(GridStepper& s) -{ - Ox = -(s.Ox + s.nx*s.Dx); - Oy = -(s.Oy + s.ny*s.Dy); - Oz = -(s.Oz + s.nz*s.Dz); -} -/**************************************************************************/ - -Bool_t GridStepper::Step() -{ - (*ns[0])++; - if (*ns[0] >= *ls[0]) { - *ns[0] = 0; (*ns[1])++; - if (*ns[1] >= *ls[1]) { - *ns[1] = 0; (*ns[2])++; - if (*ns[2] >= *ls[2]) { - return kFALSE; - } - } - } - return kTRUE; -} - -/**************************************************************************/ - -void GridStepper::GetPosition(Float_t* p) -{ - p[0] = Ox + nx*Dx; p[1] = Oy + ny*Dy; p[2] = Oz + nz*Dz; -} - -void GridStepper::SetTrans(ZTrans* mx) -{ - mx->SetPos(Ox + nx*Dx, Oy + ny*Dy, Oz + nz*Dz); -} - -void GridStepper::SetTransAdvance(ZTrans* mx) -{ - SetTrans(mx); - Step(); -} diff --git a/EVE/Reve/GridStepper.h b/EVE/Reve/GridStepper.h deleted file mode 100644 index a3a5e335fa2..00000000000 --- a/EVE/Reve/GridStepper.h +++ /dev/null @@ -1,55 +0,0 @@ -// $Header$ - -#ifndef REVE_GridStepper_H -#define REVE_GridStepper_H - -#include - -#include - -namespace Reve { - -class ZTrans; - -class GridStepper : public TObject -{ -private: - Int_t *ls[3], *ns[3]; //! Internal traversal variables. - - GridStepper(const GridStepper&); // Not implemented - GridStepper& operator=(const GridStepper&); // Not implemented - -public: - enum StepMode_e { SM_XYZ, SM_YXZ, SM_XZY }; - StepMode_e Mode; // Stepping mode, order of filling. - - Int_t nx, ny, nz; // Current positions during filling / traversal. - Int_t Nx, Ny, Nz; // Number of slots in eaxh direction. - Float_t Dx, Dy, Dz; // Step size in each direction. - Float_t Ox, Oy, Oz; // Initial offset for each direction. - - GridStepper(Int_t sm=SM_XYZ); - virtual ~GridStepper() {} - - void Reset(); - void Subtract(GridStepper& s); - void SetNs(Int_t nx, Int_t ny, Int_t nz=1) - { Nx = nx; Ny = ny; Nz = nz; } - void SetDs(Float_t dx, Float_t dy, Float_t dz=0) - { Dx = dx; Dy = dy; Dz = dz; } - void SetOs(Float_t ox, Float_t oy, Float_t oz=0) - { Ox = ox; Oy = oy; Oz = oz; } - - Bool_t Step(); - - void GetPosition(Float_t* p); - - void SetTrans(ZTrans* mx); - void SetTransAdvance(ZTrans* mx); - - ClassDef(GridStepper, 1); -}; // end class GridStepper - -} // namespace Reve - -#endif diff --git a/EVE/Reve/GridStepperEditor.cxx b/EVE/Reve/GridStepperEditor.cxx deleted file mode 100644 index 84ef052c13f..00000000000 --- a/EVE/Reve/GridStepperEditor.cxx +++ /dev/null @@ -1,186 +0,0 @@ -// $Header$ - -#include "GridStepperEditor.h" -#include -#include - -#include -#include - -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// GridStepperSubEditor -// -// - -ClassImp(GridStepperSubEditor) - -//______________________________________________________________________ -GridStepperSubEditor::GridStepperSubEditor(const TGWindow *p) : - TGVerticalFrame(p), - fM (0), - - fNx (0), - fNy (0), - fNz (0), - fDx (0), - fDy (0), - fDz (0) -{ - Int_t labelW = 15; - - TGHorizontalFrame* VF = new TGHorizontalFrame(this); - - { - TGGroupFrame* f = new TGGroupFrame(VF, "NumRows", kVerticalFrame); - f->SetWidth(30); - VF->AddFrame(f, new TGLayoutHints(kLHintsTop, 1, 1, 1, 0)); - - fNx = new RGValuator(f,"X:", 200, 0); - fNx->SetNELength(3); - fNx->SetLabelWidth(labelW); - fNx->SetShowSlider(kFALSE); - fNx->Build(); - fNx->SetLimits(1, 15); - fNx->Connect("ValueSet(Double_t)", - "Reve::GridStepperSubEditor", this, "DoNs()"); - f->AddFrame(fNx, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - - fNy = new RGValuator(f,"Y:", 200, 0); - fNy->SetNELength(3); - fNy->SetLabelWidth(labelW); - fNy->SetShowSlider(kFALSE); - fNy->Build(); - fNy->SetLimits(1, 15); - fNy->Connect("ValueSet(Double_t)", - "Reve::GridStepperSubEditor", this, "DoNs()"); - f->AddFrame(fNy, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - - fNz = new RGValuator(f,"Z:", 200, 0); - fNz->SetNELength(3); - fNz->SetLabelWidth(labelW); - fNz->SetShowSlider(kFALSE); - fNz->Build(); - fNz->SetLimits(1, 15); - fNz->Connect("ValueSet(Double_t)", - "Reve::GridStepperSubEditor", this, "DoNs()"); - f->AddFrame(fNz, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - - //AddFrame(f, new TGLayoutHints(kLHintsExpandX, 2, 0, 0, 0)); - } - { - TGGroupFrame* f = new TGGroupFrame(VF, "Step", kVerticalFrame); - f->SetWidth(130); - VF->AddFrame(f, new TGLayoutHints(kLHintsTop, 1, 1, 1, 0)); - - fDx = new RGValuator(f,"X:", 200, 0); - fDx->SetNELength(5); - fDx->SetLabelWidth(labelW); - fDx->SetShowSlider(kFALSE); - fDx->Build(); - fDx->SetLimits(0.1, 100, 101, TGNumberFormat::kNESRealOne); - fDx->Connect("ValueSet(Double_t)", - "Reve::GridStepperSubEditor", this, "DoDs()"); - f->AddFrame(fDx, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - - fDy = new RGValuator(f,"Y:", 200, 0); - fDy->SetNELength(5); - fDy->SetLabelWidth(labelW); - fDy->SetShowSlider(kFALSE); - fDy->Build(); - fDy->SetLimits(0.1, 100, 101, TGNumberFormat::kNESRealOne); - fDy->Connect("ValueSet(Double_t)", - "Reve::GridStepperSubEditor", this, "DoDs()"); - f->AddFrame(fDy, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - - fDz = new RGValuator(f,"Z:", 200, 0); - fDz->SetNELength(5); - fDz->SetLabelWidth(labelW); - fDz->SetShowSlider(kFALSE); - fDz->Build(); - fDz->SetLimits(0.1, 100, 101, TGNumberFormat::kNESRealOne); - fDz->Connect("ValueSet(Double_t)", - "Reve::GridStepperSubEditor", this, "DoDs()"); - f->AddFrame(fDz, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - - //AddFrame(f, new TGLayoutHints(kLHintsExpandX, 2, 0, 0, 0)); - } - AddFrame(VF, new TGLayoutHints(kLHintsExpandX, 2, 0, 0, 0)); -} - -//______________________________________________________________________ -void GridStepperSubEditor::SetModel(GridStepper* m) -{ - // Set model object. - fM = m; - - fNx->SetValue(m->Nx); - fNy->SetValue(m->Ny); - fNz->SetValue(m->Nz); - - fDx->SetValue(m->Dx); - fDy->SetValue(m->Dy); - fDz->SetValue(m->Dz); -} - -//______________________________________________________________________ -void GridStepperSubEditor::Changed() -{ - // Emit Changed signal. - - Emit("Changed()"); -} - -//______________________________________________________________________ -void GridStepperSubEditor::DoNs() -{ - fM->SetNs((Int_t)fNx->GetValue(), (Int_t)fNy->GetValue(), (Int_t)fNz->GetValue()); - Changed(); -} - -//______________________________________________________________________ -void GridStepperSubEditor::DoDs() -{ - // Set some value from some widget - fM->SetDs(fDx->GetValue(), fDy->GetValue(), fDz->GetValue()); - Changed(); -} - -//______________________________________________________________________ -// GridStepperEditor -// -// - -ClassImp(GridStepperEditor) - -//______________________________________________________________________ -GridStepperEditor::GridStepperEditor(const TGWindow *p, Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - fM (0), - fSE (0) -{ - // Constructor. - - MakeTitle("GridStepper"); - - fSE = new GridStepperSubEditor(this); - AddFrame(fSE, new TGLayoutHints(kLHintsTop, 2, 0, 2, 2)); - fSE->Connect("Changed()", "GridStepperEditor", this, "Update()"); -} - -/**************************************************************************/ - -//______________________________________________________________________ -void GridStepperEditor::SetModel(TObject* obj) -{ - // Set model object. - fM = dynamic_cast(obj); - fSE->SetModel(fM); -} diff --git a/EVE/Reve/GridStepperEditor.h b/EVE/Reve/GridStepperEditor.h deleted file mode 100644 index 38f166bffd5..00000000000 --- a/EVE/Reve/GridStepperEditor.h +++ /dev/null @@ -1,70 +0,0 @@ -// $Header$ - -#ifndef REVE_GridStepperEditor_H -#define REVE_GridStepperEditor_H - -#include - -class TGButton; -class TGCheckButton; -class TGNumberEntry; -class TGColorSelect; - -namespace Reve { - -class GridStepper; -class RGValuator; - -class GridStepperSubEditor : public TGVerticalFrame -{ -private: - GridStepperSubEditor(const GridStepperSubEditor&); // Not implemented - GridStepperSubEditor& operator=(const GridStepperSubEditor&); // Not implemented - -protected: - GridStepper *fM; // Model object. - - RGValuator *fNx; // Number of slots along x. - RGValuator *fNy; // Number of slots along y. - RGValuator *fNz; // Number of slots along z. - RGValuator *fDx; // Step in the x direction. - RGValuator *fDy; // Step in the y direction. - RGValuator *fDz; // Step in the z direction. - -public: - GridStepperSubEditor(const TGWindow* p); - virtual ~GridStepperSubEditor() {} - - void SetModel(GridStepper* m); - - void Changed(); //*SIGNAL* - - void DoNs(); - void DoDs(); - - ClassDef(GridStepperSubEditor, 0) // Sub-editor for GridStepper class. -}; - - -class GridStepperEditor : public TGedFrame -{ -private: - GridStepperEditor(const GridStepperEditor&); // Not implemented - GridStepperEditor& operator=(const GridStepperEditor&); // Not implemented - -protected: - GridStepper *fM; // Model object. - GridStepperSubEditor *fSE; // Sub-editor containg GUI controls. - -public: - GridStepperEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - virtual ~GridStepperEditor() {} - - virtual void SetModel(TObject* obj); - - ClassDef(GridStepperEditor, 0) // Editor for GridStepper class. -}; - -} - -#endif diff --git a/EVE/Reve/Line.cxx b/EVE/Reve/Line.cxx deleted file mode 100644 index a8548e977f0..00000000000 --- a/EVE/Reve/Line.cxx +++ /dev/null @@ -1,31 +0,0 @@ -// $Header$ - -#include "Line.h" - -using namespace Reve; - -//______________________________________________________________________ -// Line -// - -ClassImp(Line) - - -Line::Line(Int_t n_points, TreeVarType_e tv_type) : - PointSet(n_points, tv_type), - fRnrLine (kTRUE), - fRnrPoints (kFALSE) -{ - fMainColorPtr = &fLineColor; -} - -Line::Line(const Text_t* name, Int_t n_points, TreeVarType_e tv_type) : - PointSet(name, n_points, tv_type), - fRnrLine (kTRUE), - fRnrPoints (kFALSE) -{ - fMainColorPtr = &fLineColor; -} - -Line::~Line() -{} diff --git a/EVE/Reve/Line.h b/EVE/Reve/Line.h deleted file mode 100644 index 5889f29c3d7..00000000000 --- a/EVE/Reve/Line.h +++ /dev/null @@ -1,47 +0,0 @@ -// $Header$ - -#ifndef REVE_Line_H -#define REVE_Line_H - -#include -#include - -#include - -namespace Reve { - -class Line : public PointSet, - public TAttLine -{ - friend class LineEditor; - friend class LineGL; - -private: - Line(const Line&); // Not implemented - Line& operator=(const Line&); // Not implemented - -protected: - Bool_t fRnrLine; - Bool_t fRnrPoints; - -public: - Line(Int_t n_points=0, TreeVarType_e tv_type=TVT_XYZ); - Line(const Text_t* name, Int_t n_points=0, TreeVarType_e tv_type=TVT_XYZ); - virtual ~Line(); - - virtual void SetMarkerColor(Color_t col) - { TAttMarker::SetMarkerColor(col); } - virtual void SetLineColor(Color_t col) - { SetMainColor(col); } - - Bool_t GetRnrLine() const { return fRnrLine; } - void SetRnrLine(Bool_t r) { fRnrLine = r; } - Bool_t GetRnrPoints() const { return fRnrPoints; } - void SetRnrPoints(Bool_t r) { fRnrPoints = r; } - - ClassDef(Line, 1); -}; // endclass Line - -} - -#endif diff --git a/EVE/Reve/LineEditor.cxx b/EVE/Reve/LineEditor.cxx deleted file mode 100644 index bf735a805f4..00000000000 --- a/EVE/Reve/LineEditor.cxx +++ /dev/null @@ -1,71 +0,0 @@ -// $Header$ - -#include "LineEditor.h" -#include - -#include -#include - -#include -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// LineEditor -// - -ClassImp(LineEditor) - - LineEditor::LineEditor(const TGWindow *p, Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - fM(0), - fRnrLine (0), - fRnrPoints (0) -{ - fPriority = 20; - { - TGHorizontalFrame* f = new TGHorizontalFrame(this); - - fRnrPoints = new TGCheckButton(f, "Draw Marker"); - f->AddFrame(fRnrPoints, new TGLayoutHints(kLHintsLeft, 2,1,0,0)); - fRnrPoints->Connect("Toggled(Bool_t)"," Reve::LineEditor", this, "DoRnrPoints()"); - - fRnrLine = new TGCheckButton(f, "Draw Line"); - f->AddFrame(fRnrLine, new TGLayoutHints(kLHintsLeft, 1,2,0,0)); - fRnrLine->Connect("Toggled(Bool_t)", "Reve::LineEditor", this, "DoRnrLine()"); - - AddFrame(f, new TGLayoutHints(kLHintsTop, 0,0,2,1)); - } -} - -LineEditor::~LineEditor() -{} - -/**************************************************************************/ - -void LineEditor::SetModel(TObject* obj) -{ - fM = dynamic_cast(obj); - - fRnrLine ->SetState(fM->fRnrLine ? kButtonDown : kButtonUp); - fRnrPoints->SetState(fM->fRnrPoints ? kButtonDown : kButtonUp); -} - -/**************************************************************************/ - -void LineEditor::DoRnrLine() -{ - fM->SetRnrLine(fRnrLine->IsOn()); - Update(); -} - -void LineEditor::DoRnrPoints() -{ - fM->SetRnrPoints(fRnrPoints->IsOn()); - Update(); -} diff --git a/EVE/Reve/LineEditor.h b/EVE/Reve/LineEditor.h deleted file mode 100644 index 48d9849061e..00000000000 --- a/EVE/Reve/LineEditor.h +++ /dev/null @@ -1,42 +0,0 @@ -// $Header$ - -#ifndef REVE_LineEditor_H -#define REVE_LineEditor_H - -#include - -class TGCheckButton; -class TGNumberEntry; -class TGColorSelect; - -namespace Reve { - -class Line; - -class LineEditor : public TGedFrame -{ -private: - LineEditor(const LineEditor&); // Not implemented - LineEditor& operator=(const LineEditor&); // Not implemented - -protected: - Line *fM; // Model object. - - TGCheckButton *fRnrLine; // Checkbox for line-rendering. - TGCheckButton *fRnrPoints; // Checkbox for point-rendering. - -public: - LineEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, UInt_t options = kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - virtual ~LineEditor(); - - virtual void SetModel(TObject* obj); - - void DoRnrLine(); - void DoRnrPoints(); - - ClassDef(LineEditor, 1); // Editor for Line class. -}; // endclass LineEditor - -} - -#endif diff --git a/EVE/Reve/LineGL.cxx b/EVE/Reve/LineGL.cxx deleted file mode 100644 index ce23c01c883..00000000000 --- a/EVE/Reve/LineGL.cxx +++ /dev/null @@ -1,57 +0,0 @@ -// $Header$ - -#include "LineGL.h" -#include - -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// LineGL -// - -ClassImp(LineGL) - -LineGL::LineGL() : TPointSet3DGL(), fM(0) -{ - // fDLCache = false; // Disable display list. -} - -LineGL::~LineGL() -{} - -/**************************************************************************/ - -Bool_t LineGL::SetModel(TObject* obj, const Option_t* /*opt*/) -{ - // TPointSet3DGL::SetModel(obj); - if(SetModelCheckClass(obj, Line::Class())) { - fM = dynamic_cast(obj); - return kTRUE; - } - return kFALSE; -} - -/**************************************************************************/ - -void LineGL::DirectDraw(TGLRnrCtx & rnrCtx) const -{ - // Direct GL rendering for Line. - - // printf("LineGL::DirectDraw Style %d, LOD %d\n", rnrCtx.Style(), rnrCtx.LOD()); - - if (rnrCtx.DrawPass() == TGLRnrCtx::kPassOutlineLine) - return; - - Line& q = *fM; - if (q.Size() <= 0) return; - - if (q.fRnrLine) - GLUtilNS::RenderLine(q, q.GetP(), q.Size()); - - if (q.fRnrPoints) - GLUtilNS::RenderPolyMarkers(q, q.GetP(), q.Size()); -} diff --git a/EVE/Reve/LineGL.h b/EVE/Reve/LineGL.h deleted file mode 100644 index b448d1fc712..00000000000 --- a/EVE/Reve/LineGL.h +++ /dev/null @@ -1,42 +0,0 @@ -// $Header$ - -#ifndef REVE_LineGL_H -#define REVE_LineGL_H - -#include -#include - -class TGLViewer; -class TGLScene; - -namespace Reve { - -class Line; - -class LineGL : public TPointSet3DGL -{ -private: - LineGL(const LineGL&); // Not implemented - LineGL& operator=(const LineGL&); // Not implemented - -protected: - Line* fM; // fModel dynamic-casted to LineGL - - virtual void DirectDraw(TGLRnrCtx & rnrCtx) const; - -public: - LineGL(); - virtual ~LineGL(); - - virtual Bool_t SetModel(TObject* obj, const Option_t* opt=0); - - // To support two-level selection - // virtual Bool_t SupportsSecondarySelect() const { return kTRUE; } - // virtual void ProcessSelection(UInt_t* ptr, TGLViewer*, TGLScene*); - - ClassDef(LineGL, 0); -}; // endclass LineGL - -} - -#endif diff --git a/EVE/Reve/LinkDef.h b/EVE/Reve/LinkDef.h deleted file mode 100644 index 1840895da17..00000000000 --- a/EVE/Reve/LinkDef.h +++ /dev/null @@ -1,211 +0,0 @@ -#pragma link off all functions; -#pragma link off all globals; -#pragma link off all classes; - -// Bertrand's new browser and helpers -#pragma link C++ class TGClassBrowser; -#pragma link C++ class TGCommandPlugin; -#pragma link C++ class TGFileBrowser; -#pragma link C++ class TGNewBrowser; - - -#pragma link C++ namespace Reve; -#pragma link C++ global gReve; // In ReveManager ... should move. - -//================================ -// base/ -//================================ - -// Reve -#pragma link C++ function Reve::SetupEnvironment; - -#pragma link C++ function Reve::CheckMacro; -#pragma link C++ function Reve::AssertMacro; -#pragma link C++ function Reve::Macro; -#pragma link C++ function Reve::LoadMacro; - -#pragma link C++ function Reve::PushPad; -#pragma link C++ function Reve::PopPad; -#pragma link C++ class Reve::Exc_t+; -#pragma link C++ class Reve::PadHolder+; -#pragma link C++ class Reve::GeoManagerHolder+; -#pragma link C++ class Reve::ReferenceCount+; -#pragma link C++ class Reve::ReferenceBackPtr+; - -#pragma link C++ function Reve::ColorFromIdx; -#pragma link C++ function Reve::FindColorVar; - -// PODs -#pragma link C++ class Reve::Vector+; -#pragma link C++ class Reve::PathMark+; -#pragma link C++ class Reve::MCTrack+; -#pragma link C++ class Reve::Hit+; -#pragma link C++ class Reve::Cluster+; -#pragma link C++ class Reve::RecTrack+; -#pragma link C++ class Reve::RecKink+; -#pragma link C++ class Reve::RecV0+; -#pragma link C++ class Reve::GenInfo+; - -// ZTrans -#pragma link C++ class Reve::ZTrans-; -#pragma link C++ class Reve::ZTransSubEditor+; -#pragma link C++ class Reve::ZTransEditor+; - -// Stepper -#pragma link C++ class Reve::GridStepper+; -#pragma link C++ class Reve::GridStepperSubEditor+; -#pragma link C++ class Reve::GridStepperEditor+; - -// RGBAPalette -#pragma link C++ class Reve::RGBAPalette+; -#pragma link C++ class Reve::RGBAPaletteEditor+; -#pragma link C++ class Reve::RGBAPaletteSubEditor+; - -// Plexes -#pragma link C++ class Reve::VoidCPlex+; -#pragma link C++ class Reve::VoidCPlex::iterator-; - -// EventBase, VSDEvent, VSD -#pragma link C++ class Reve::EventBase+; -#pragma link C++ class Reve::EvTree+; -#pragma link C++ class Reve::VSDEvent+; -#pragma link C++ class Reve::VSDTree+; -#pragma link C++ class Reve::VSD+; - -// TTreeTools -#pragma link C++ class TSelectorToEventList+; -#pragma link C++ class TTreeQuery+; -#pragma link C++ class TPointSelectorConsumer+; -#pragma link C++ class TPointSelector+; - -// RenderElement -#pragma link C++ class Reve::RenderElement+; -#pragma link C++ class Reve::RenderElement::ListTreeInfo+; -#pragma link C++ class Reve::RenderElementObjPtr+; -#pragma link C++ class Reve::RenderElementList+; -#pragma link C++ class Reve::RenderElementEditor+; - -#pragma link C++ class std::list; -#pragma link C++ class std::list::iterator; -#pragma link C++ typedef Reve::RenderElement::List_t; -#pragma link C++ typedef Reve::RenderElement::List_i; - -// GL-interface -#pragma link C++ class Reve::Scene+; -#pragma link C++ class Reve::SceneList+; -#pragma link C++ class Reve::SceneInfo+; -#pragma link C++ class Reve::Viewer+; -#pragma link C++ class Reve::ViewerList+; - -// Pad -#pragma link C++ class Reve::Pad+; - -// VSDSelector -#pragma link C++ class Reve::VSDSelector+; - -// RGBrowser -#pragma link C++ class Reve::RGLTEFrame+; -#pragma link C++ class Reve::RGBrowser+; - -// RGEditor -#pragma link C++ class Reve::RGEditor+; - -// RMacro -#pragma link C++ class Reve::RMacro+; - -// ReveManager -#pragma link C++ class Reve::ReveManager+; - -// RGValuators -#pragma link C++ class Reve::RGValuatorBase+; -#pragma link C++ class Reve::RGValuator+; -#pragma link C++ class Reve::RGDoubleValuator+; -#pragma link C++ class Reve::RGTriVecValuator+; - -// Non-linear transformations -#pragma link C++ class Reve::NLTProjectable+; -#pragma link C++ class Reve::NLTProjected+; -#pragma link C++ class Reve::NLTProjection+; -#pragma link C++ class Reve::NLTRhoZ+; -#pragma link C++ class Reve::NLTCircularFishEye+; - -#pragma link C++ class Reve::NLTProjector+; -#pragma link C++ class Reve::NLTProjectorEditor+; -#pragma link C++ class Reve::NLTProjectorGL+; - -#pragma link C++ class Reve::NLTTrack+; -#pragma link C++ class Reve::NLTTrackGL+; -#pragma link C++ class Reve::NLTTrackList+; - -#pragma link C++ class Reve::NLTPolygon+; -#pragma link C++ class Reve::NLTPolygonSet+; -#pragma link C++ class Reve::NLTPolygonSetEditor+; -#pragma link C++ class Reve::NLTPolygonSetGL+; - -#pragma link C++ class Reve::NLTPointSet+; -#pragma link C++ class Reve::NLTPointSetGL+; - -//===================================== -// Graphical elements (with renderers) -//===================================== - -// Track -#pragma link C++ class Reve::Track+; -#pragma link C++ class Reve::TrackGL+; -#pragma link C++ class Reve::TrackEditor+; -#pragma link C++ class Reve::TrackRnrStyle+; -#pragma link C++ class Reve::TrackList+; -#pragma link C++ class Reve::TrackListEditor+; -#pragma link C++ class Reve::TrackRnrStyleSubEditor+; -#pragma link C++ class Reve::TrackRnrStyleEditor+; -#pragma link C++ class Reve::TrackCounter+; -#pragma link C++ class Reve::TrackCounterEditor+; - -// PointSet -#pragma link C++ class Reve::PointSet+; -#pragma link C++ class Reve::PointSetArray+; -#pragma link C++ class Reve::PointSetArrayEditor+; - -// Line -#pragma link C++ class Reve::Line+; -#pragma link C++ class Reve::LineEditor+; -#pragma link C++ class Reve::LineGL+; - -// FrameBox -#pragma link C++ class Reve::FrameBox+; -#pragma link C++ class Reve::FrameBoxGL+; - -// DigitSet -#pragma link C++ class Reve::DigitSet+; -#pragma link C++ class Reve::DigitSetEditor+; - -// QuadSet -#pragma link C++ class Reve::Quad+; -#pragma link C++ class Reve::OldQuadSet+; -#pragma link C++ class Reve::OldQuadSetGL+; -#pragma link C++ class Reve::QuadSet+; -#pragma link C++ class Reve::QuadSetGL+; - -// BoxSet -#pragma link C++ class Reve::BoxSet+; -#pragma link C++ class Reve::BoxSetGL+; - -// GeoNode -#pragma link C++ class Reve::GeoNodeRnrEl+; -#pragma link C++ class Reve::GeoTopNodeRnrEl+; -#pragma link C++ class Reve::GeoNodeRnrElEditor+; -#pragma link C++ class Reve::GeoTopNodeRnrElEditor+; - -#pragma link C++ class TGeoShapeExtract+; -#pragma link C++ class Reve::GeoShapeRnrEl+; - -// TrianlgeSet -#pragma link C++ class Reve::TriangleSet+; -#pragma link C++ class Reve::TriangleSetEditor+; -#pragma link C++ class Reve::TriangleSetGL+; - -// StraightLineSet -#pragma link C++ class Reve::StraightLineSet+; -#pragma link C++ class Reve::StraightLineSetGL+; -#pragma link C++ class Reve::StraightLineSetEditor+; -#pragma link C++ class Reve::NLTSLineSet+; diff --git a/EVE/Reve/MCHelixLine.hi b/EVE/Reve/MCHelixLine.hi deleted file mode 100644 index 71c6c54160e..00000000000 --- a/EVE/Reve/MCHelixLine.hi +++ /dev/null @@ -1,315 +0,0 @@ -#ifndef REVE_MCHelixLine_H -#define REVE_MCHelixLine_H - -#include -#include -#include - -namespace Reve { - -struct MCVertex -{ - Float_t x,y,z,t; - - MCVertex() : x(0), y(0), z(0), t(0) {} - MCVertex(Float_t _x, Float_t _y, Float_t _z, Float_t _t=0) : - x(_x), y(_y), z(_z), t(_t) {} - - Float_t Mag() const { return TMath::Sqrt(x*x+y*y+z*z);} - Float_t Mag2() const { return x*x+y*y+z*z;} - - Float_t Perp() const { return TMath::Sqrt(x*x+y*y);} - Float_t Perp2() const { return x*x+y*y;} - Float_t R() const { return Perp(); } - - MCVertex operator + (const MCVertex & b) - { return MCVertex(x + b.x, y + b.y, z + b.z, t + b.t); } - - MCVertex operator - (const MCVertex & b) - { return MCVertex(x - b.x, y - b.y, z - b.z, t - b.t); } - - MCVertex operator * (Float_t a) - { return MCVertex(a*x, a*y, a*z, a*t); } - - MCVertex& operator +=(const MCVertex & b) - { x += b.x; y += b.y; z += b.z; t += b.t; return *this; } -}; - - -struct MCStruct -{ - MCStruct(const MCStruct&); // Not implemented - MCStruct& operator=(const MCStruct&); // Not implemented - - TrackRnrStyle* fRnrMod; - std::vector* fPoints; - MCVertex fV; - Float_t fVelocity; // size of particle velocity - - MCStruct(TrackRnrStyle* rs, MCVertex* v0 , Float_t vel, std::vector* tpv) : - fRnrMod (rs), - fPoints (tpv), - fV (*v0), - fVelocity (vel) - { - fPoints->push_back(fV); - } - virtual ~MCStruct() {} -}; - -/**************************************************************************/ -// HELIX -/**************************************************************************/ - -struct MCHelix : public MCStruct -{ - // constant - Float_t fA; // contains charge and magnetic field data - - //parameters dependend pT and pZ size, set in init function - Float_t fLam; // momentum ratio pT/pZ - Float_t fR; // a/pT - Float_t fPhiStep; // step size in xy projection, dependent of RnrMode and momentum - Float_t fTimeStep; - - Int_t fN; // step number in helix; - Int_t NMax; // max number of points in helix - Float_t x_off, y_off; // offset for fitting daughters - Float_t sin, cos; - Bool_t crosR; - - MCHelix(TrackRnrStyle* rs, MCVertex* v0, Float_t vel, - std::vector* tpv, Float_t a) : - MCStruct(rs, v0 , vel, tpv), - fA (a), - fLam (0), fR (0), fPhiStep (0), fTimeStep (0), - fN (0), NMax (0), - x_off(0), y_off(0), - sin (0), cos (0), crosR (0) - {} - - void Init(Float_t pT, Float_t pZ) - { - fN = 0; - crosR = false; - x_off = 0; - y_off = 0; - fLam = pZ/pT; - fR = pT/fA; - - fPhiStep = fRnrMod->fMinAng * TMath::DegToRad(); - if (fRnrMod->fDelta < TMath::Abs(fR)) - { - Float_t ang = 2*TMath::ACos(1 - fRnrMod->fDelta/TMath::Abs(fR)); - if (ang < fPhiStep) fPhiStep = ang; - } - if (fA < 0) fPhiStep = -fPhiStep; - - // printf("MCHelix::init (%f/%f) labda %f time step %e phi step %f \n", pT, pZ,fLam, fTimeStep,fPhiStep); - fTimeStep = TMath::Abs(fR*fPhiStep)*TMath::Sqrt(1+fLam*fLam)/fVelocity; - fTimeStep *= 0.01; //cm->m - - sin = TMath::Sin(fPhiStep); - cos = TMath::Cos(fPhiStep); - } - - void SetBounds() - { - // check steps for max orbits - NMax = Int_t(fRnrMod->fMaxOrbs*TMath::TwoPi()/TMath::Abs(fPhiStep)); - // check steps for Z boundaries - Float_t nz; - if(fLam > 0) { - nz = (fRnrMod->fMaxZ - fV.z)/(fLam*TMath::Abs(fR*fPhiStep)); - } else { - nz = (-fRnrMod->fMaxZ - fV.z)/(fLam*TMath::Abs(fR*fPhiStep)); - } - // printf("steps in helix line %d nz %f vz %f\n", NMax, nz, fV.z); - if (nz < NMax) NMax = Int_t(nz + 1); - - // check steps if circles intersect - if(TMath::Sqrt(fV.x*fV.x+fV.y*fV.y) < fRnrMod->fMaxR + TMath::Abs(fR)) - { - crosR = true; - } - // printf("end steps in helix line %d \n", NMax); - } - - - void Step(Float_t &px, Float_t &py, Float_t &/*pz*/) - { - fV.t += fTimeStep; - fV.x += (px*sin - py*(1 - cos))/fA + x_off; - fV.y += (py*sin + px*(1 - cos))/fA + y_off; - fV.z += fLam*TMath::Abs(fR*fPhiStep); - fPoints->push_back(fV); - Float_t px_t = px*cos - py*sin; - Float_t py_t = py*cos + px*sin; - px = px_t; - py = py_t; - ++fN; - } - - - Bool_t LoopToVertex(Float_t &px, Float_t &py, Float_t &pz, - Float_t ex, Float_t ey, Float_t ez) - { - Float_t p0x = px, p0y = py; - Float_t zs = fLam*TMath::Abs(fR*fPhiStep); - Float_t maxrsq = fRnrMod->fMaxR * fRnrMod->fMaxR; - Float_t fnsteps = (ez - fV.z)/zs; - Int_t nsteps = Int_t((ez - fV.z)/zs); - Float_t sinf = TMath::Sin(fnsteps*fPhiStep); - Float_t cosf = TMath::Cos(fnsteps*fPhiStep); - - { - if (nsteps > 0) - { - Float_t xf = fV.x + (px*sinf - py*(1 - cosf))/fA; - Float_t yf = fV.y + (py*sinf + px*(1 - cosf))/fA; - x_off = (ex - xf)/fnsteps; - y_off = (ey - yf)/fnsteps; - Float_t xforw, yforw, zforw; - for (Int_t l=0; l maxrsq || - TMath::Abs(zforw) > fRnrMod->fMaxZ) - { - return false; - } - Step(px, py, pz); - if (fN > NMax) - break; - } - - } - // set time to the end point - fV.t += TMath::Sqrt((fV.x-ex)*(fV.x-ex)+(fV.y-ey)*(fV.y-ey) +(fV.z-ez)*(fV.z-ez))/fVelocity; - fV.x = ex; fV.y = ey; fV.z = ez; - fPoints->push_back(fV); - } - - { // fix momentum in the remaining part - Float_t cosr = TMath::Cos((fnsteps-nsteps)*fPhiStep); - Float_t sinr = TMath::Sin((fnsteps-nsteps)*fPhiStep); - Float_t px_t = px*cosr - py*sinr; - Float_t py_t = py*cosr + px*sinr; - px = px_t; - py = py_t; - } - { // calculate direction of faked px,py - Float_t pxf = (p0x*cosf - p0y*sinf)/TMath::Abs(fA) + x_off/fPhiStep; - Float_t pyf = (p0y*cosf + p0x*sinf)/TMath::Abs(fA) + y_off/fPhiStep; - Float_t fac = TMath::Sqrt((p0x*p0x + p0y*p0y) / (pxf*pxf + pyf*pyf)); - px = fac*pxf; - py = fac*pyf; - } - return true; - } - - Bool_t LoopToBounds(Float_t &px, Float_t &py, Float_t &pz) - { - // printf("MC helix loop_to_bounds\n"); - SetBounds(); - if (NMax > 0) - { - // printf("NMax MC helix loop_to_bounds\n"); - MCVertex forw; - Float_t maxrsq = fRnrMod->fMaxR * fRnrMod->fMaxR; - while (fN < NMax) - { - forw.x = fV.x + (px*sin - py*(1 - cos))/fA + x_off; - forw.y = fV.y + (py*sin + px*(1 - cos))/fA + y_off; - forw.z = fV.z + fLam*TMath::Abs(fR*fPhiStep); - forw.t = fV.t + fTimeStep; - - if (crosR && forw.Perp2() > maxrsq) - { - Float_t t = (fRnrMod->fMaxR - fV.R()) / (forw.R() - fV.R()); - assert(t >= 0 && t <= 1); - fPoints->push_back(fV + (forw-fV)*t); - return false; - } - if (TMath::Abs(forw.z) > fRnrMod->fMaxZ) - { - Float_t t = (fRnrMod->fMaxZ - TMath::Abs(fV.z)) / TMath::Abs((forw.z - fV.z)); - assert(t >= 0 && t <= 1); - fPoints->push_back(fV + (forw-fV)*t); - return false; - } - - Step(px, py, pz); - } - return true; - } - return false; - } -}; - -/**************************************************************************/ -// LINE -/**************************************************************************/ - -struct MCLine : public MCStruct -{ - MCLine(TrackRnrStyle* rs, MCVertex* v0 ,Float_t vel, std::vector* tpv): - MCStruct(rs, v0 , vel, tpv) - {} - - Bool_t InBounds(Float_t ex, Float_t ey, Float_t ez) - { - if(TMath::Abs(ez) > fRnrMod->fMaxZ || - ex*ex + ey*ey > fRnrMod->fMaxR*fRnrMod->fMaxR) - return false; - else - return true; - } - - void GotoVertex(Float_t x1, Float_t y1, Float_t z1) - { - fV.t += TMath::Sqrt((fV.x-x1)*(fV.x-x1)+(fV.y-y1)*(fV.y-y1)+(fV.z-z1)*(fV.z-z1))/fVelocity; - fV.x=x1; fV.y=y1; fV.z=z1; - fPoints->push_back(fV); - } - - - void GotoBounds( Float_t px, Float_t py, Float_t pz) - { - Float_t tZ = 0,Tb = 0; - // time where particle intersect +/- fMaxZ - if (pz > 0) { - tZ = (fRnrMod->fMaxZ - fV.z)/pz; - } - else if (pz < 0 ) { - tZ = (-1)*(fRnrMod->fMaxZ + fV.z)/pz; - } - // time where particle intersects cylinder - Float_t tR=0; - Double_t a = px*px + py*py; - Double_t b = 2*(fV.x*px + fV.y*py); - Double_t c = fV.x*fV.x + fV.y*fV.y - fRnrMod->fMaxR*fRnrMod->fMaxR; - Double_t D = b*b - 4*a*c; - if(D >= 0) { - Double_t D_sqrt=TMath::Sqrt(D); - tR = ( -b - D_sqrt )/(2*a); - if( tR < 0) { - tR = ( -b + D_sqrt )/(2*a); - } - - // compare the two times - Tb = tR < tZ ? tR : tZ; - } else { - Tb = tZ; - } - - GotoVertex(fV.x+px*Tb, fV.y+py*Tb, fV.z+ pz*Tb); - } -}; // struct Line - - -} // namespace Reve - -#endif diff --git a/EVE/Reve/Makefile b/EVE/Reve/Makefile deleted file mode 100644 index 250da71893a..00000000000 --- a/EVE/Reve/Makefile +++ /dev/null @@ -1,33 +0,0 @@ -# $Header$ - -# MODULE ~include sub-directory, namespace -# NAME ~ name of the library - -MODULE = Reve -NAME = Reve -LIBNAME = lib${NAME}.${LDEXT} -DICTSTEM = ${NAME}_Dict - -HDRS = $(filter-out %LinkDef.h %_Dict.h, $(wildcard *.h)) -SRCS = $(wildcard *.cxx) -OBJS = $(SRCS:.cxx=.o) -LIBOBJS = ${OBJS} ${DICTSTEM}.o -ALLOBJS = ${LIBOBJS} reve_main/reve_main.o - -LIBS = ${LIBNAME} -EXES = reve - -ROOTLIBS = $(shell root-config --libs) -ROOTGLIBS = $(shell root-config --glibs) - -include ../make_base.inc - -${LIBNAME}: ${LIBOBJS} - ${LD} ${LDFLAGS} -o $@ $^ - -${DICTSTEM}.cc: ${HDRS} LinkDef.h - ${ROOTCINT} -f $@ -c ${ROOTCINTFLAGS} $^ - -reve: reve_main/reve_main.o ${LIBNAME} - ${CXX} ${CPPFLAGS} -o $@ ${CXXFLAGS} $< -L. -lReve \ - ${ROOTGLIBS} -lTreePlayer -lEG -lGeom -lGeomPainter -lGed -lRGL -lFTGL diff --git a/EVE/Reve/NLTBases.cxx b/EVE/Reve/NLTBases.cxx deleted file mode 100644 index 505251f95b8..00000000000 --- a/EVE/Reve/NLTBases.cxx +++ /dev/null @@ -1,87 +0,0 @@ -// $Header$ - -#include -#include - -using namespace Reve; - -//______________________________________________________________________________ -// NLTProjectable -// -// Abstract base-class for non-linear projectable objects. Creates TClass instance -// for the projected class and keeps references to the projected objects. -// -// See also NLTProjector::ImportElements(). - -ClassImp(NLTProjectable) - -//______________________________________________________________________________ -NLTProjectable::NLTProjectable() -{ - // Comstructor. -} - -//______________________________________________________________________________ -NLTProjectable::~NLTProjectable() -{ - // Destructor. - // Force projected replicas to unreference *this. - - while ( ! fProjectedList.empty()) - { - fProjectedList.front()->UnRefProjectable(this); - } -} - - -//______________________________________________________________________________ -// NLTProjected -// -// - -ClassImp(NLTProjected) - -//______________________________________________________________________________ -NLTProjected::NLTProjected() : - fProjector (0), - fProjectable (0), - fDepth (0) -{ - // Constructor. -} - -//______________________________________________________________________________ -NLTProjected::~NLTProjected() -{ - // Destructor. - // If fProjectable is non-null, *this is removed from its list of - // projected replicas. - - if (fProjectable) fProjectable->RemoveProjected(this); -} - -//______________________________________________________________________________ -void NLTProjected::SetProjection(NLTProjector* proj, NLTProjectable* model) -{ - fProjector = proj; - if (fProjectable) fProjectable->RemoveProjected(this); - fProjectable = model; - if (fProjectable) fProjectable->AddProjected(this); -} - -//______________________________________________________________________________ -void NLTProjected::UnRefProjectable(NLTProjectable* assumed_parent) -{ - static const Exc_t eH("NLTProjected::UnRefProjectable "); - - if (fProjectable != assumed_parent) { - Warning(eH, "mismatch between assumed and real model. This is a bug."); - assumed_parent->RemoveProjected(this); - return; - } - - if (fProjectable) { - fProjectable->RemoveProjected(this); - fProjectable = 0; - } -} diff --git a/EVE/Reve/NLTBases.h b/EVE/Reve/NLTBases.h deleted file mode 100644 index 0616cd86d9a..00000000000 --- a/EVE/Reve/NLTBases.h +++ /dev/null @@ -1,81 +0,0 @@ -// $Header$ - -#ifndef REVE_NLTBases_H -#define REVE_NLTBases_H - -#include - -#include - -class TBuffer3D; - -namespace Reve { - -class NLTProjected; -class NLTProjector; - -//////////////////////////////////////////////////////////////// -// // -// NLTProjectable // -// // -// Abstract base class for non-linear projectable objects. // -// // -//////////////////////////////////////////////////////////////// - -class NLTProjectable -{ -private: - NLTProjectable(const NLTProjectable&); // Not implemented - NLTProjectable& operator=(const NLTProjectable&); // Not implemented - -protected: - std::list fProjectedList; // references to projected instances. - -public: - NLTProjectable(); - virtual ~NLTProjectable(); - - virtual TClass* ProjectedClass() const = 0; - - virtual void AddProjected(NLTProjected* p) { fProjectedList.push_back(p); } - virtual void RemoveProjected(NLTProjected* p) { fProjectedList.remove(p); } - - ClassDef(NLTProjectable, 0); // Abstract base class for non-linear projectable objects. -}; // endclass NLTProjectable - -//////////////////////////////////////////////////////////////// -// // -// NLTProjected // -// // -// Abstract base class for non-linear projected objects. // -// // -//////////////////////////////////////////////////////////////// - -class NLTProjected -{ -private: - NLTProjected(const NLTProjected&); // Not implemented - NLTProjected& operator=(const NLTProjected&); // Not implemented - -protected: - NLTProjector *fProjector; // manager - NLTProjectable *fProjectable; // link to original object - Float_t fDepth; // z coordinate - -public: - NLTProjected(); - virtual ~NLTProjected(); - - virtual void SetProjection(NLTProjector* proj, NLTProjectable* model); - virtual void UnRefProjectable(NLTProjectable* assumed_parent); - - virtual void SetDepth(Float_t d) { fDepth = d; } - - virtual void UpdateProjection() = 0; - - ClassDef(NLTProjected, 0); // Abstract base class for non-linear projected object. -}; // endclass NLTProjected - -} - -#endif diff --git a/EVE/Reve/NLTPointSetGL.cxx b/EVE/Reve/NLTPointSetGL.cxx deleted file mode 100644 index e0ce297d96b..00000000000 --- a/EVE/Reve/NLTPointSetGL.cxx +++ /dev/null @@ -1,21 +0,0 @@ -// $Header$ - -#include "NLTPointSetGL.h" - -using namespace Reve; - -//______________________________________________________________________ -// NLTPointSetGL -// -// A hack around a bug in fglrx that makes rendering of projected pointsets -// terribly slow with display-lists on and rendering as crosses. - -ClassImp(NLTPointSetGL) - -NLTPointSetGL::NLTPointSetGL() : TPointSet3DGL() -{ - fDLCache = kFALSE; // Disable display list. -} - -NLTPointSetGL::~NLTPointSetGL() -{} diff --git a/EVE/Reve/NLTPointSetGL.h b/EVE/Reve/NLTPointSetGL.h deleted file mode 100644 index 684d38af21b..00000000000 --- a/EVE/Reve/NLTPointSetGL.h +++ /dev/null @@ -1,32 +0,0 @@ -// $Header$ - -#ifndef REVE_NLTPointSetGL_H -#define REVE_NLTPointSetGL_H - -#include - -class TGLViewer; -class TGLScene; - -namespace Reve { - -class NLTPointSet; - -class NLTPointSetGL : public TPointSet3DGL -{ -private: - NLTPointSetGL(const NLTPointSetGL&); // Not implemented - NLTPointSetGL& operator=(const NLTPointSetGL&); // Not implemented - -protected: - -public: - NLTPointSetGL(); - virtual ~NLTPointSetGL(); - - ClassDef(NLTPointSetGL, 0); -}; // endclass NLTPointSetGL - -} - -#endif diff --git a/EVE/Reve/NLTPolygonSet.cxx b/EVE/Reve/NLTPolygonSet.cxx deleted file mode 100644 index f55732ece22..00000000000 --- a/EVE/Reve/NLTPolygonSet.cxx +++ /dev/null @@ -1,459 +0,0 @@ -#include "NLTPolygonSet.h" -#include "Reve/PODs.h" -#include "Reve/GeoNode.h" -#include "Reve/NLTProjector.h" - -#include -#include -#include -#include - -#include - -using namespace Reve; - -namespace { - struct Seg { - Int_t v1; - Int_t v2; - - Seg(Int_t i1=-1, Int_t i2=-1):v1(i1), v2(i2){}; - }; - typedef std::list::iterator It_t; -} - - -//______________________________________________________________________________ -// NLTPolygonSet -// -// A set of projected polygons. -// Used for storage of projected geometrical shapes. - -ClassImp(NLTPolygonSet) - -//______________________________________________________________________________ -NLTPolygonSet::NLTPolygonSet(const Text_t* n, const Text_t* t) : - RenderElementList(n, t), - - fBuff(0), - fIdxMap(0), - - fSurf(0), - - fNPnts(0), - fPnts(0), - - fFillColor(5), - fLineColor(3), - fLineWidth(1), - fTransparency (0) -{ - SetMainColorPtr(&fFillColor); -} - -//______________________________________________________________________________ -NLTPolygonSet::~NLTPolygonSet() -{ - ClearPolygonSet(); -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void NLTPolygonSet::ClearPolygonSet() -{ - // delete polygon vertex indices - Int_t* p; - for (vpPolygon_i i = fPols.begin(); i!= fPols.end(); i++) - { - p = (*i).fPnts; delete [] p; - } - fPols.clear(); - - // delete reduced points - delete [] fPnts; fPnts = 0; fNPnts = 0; - fSurf = 0; -} - -//______________________________________________________________________________ -void NLTPolygonSet::SetProjection(NLTProjector* proj, NLTProjectable* model) -{ - NLTProjected::SetProjection(proj, model); - GeoShapeRnrEl* gre = dynamic_cast(model); - - fBuff = gre->MakeBuffer3D(); - if(fBuff) - { - Color_t color = gre->GetMainColor(); - SetMainColor(color); - SetLineColor((Color_t)TColor::GetColorBright(color)); - SetMainTransparency(gre->GetMainTransparency()); - } -} - -//______________________________________________________________________________ -void NLTPolygonSet::UpdateProjection() -{ - if(fBuff == 0) return; - - // drop polygons, and projected/reduced points - ClearPolygonSet(); - ProjectBuffer3D(); -} - -//______________________________________________________________________________ -Bool_t NLTPolygonSet::IsFirstIdxHead(Int_t s0, Int_t s1) -{ - Int_t v0 = fBuff->fSegs[3*s0 + 1]; - Int_t v2 = fBuff->fSegs[3*s1 + 1]; - Int_t v3 = fBuff->fSegs[3*s1 + 2]; - if(v0 != v2 && v0 != v3 ) - return kTRUE; - else - return kFALSE; -} - -//______________________________________________________________________________ -void NLTPolygonSet::ProjectAndReducePoints() -{ - NLTProjection* projection = fProjector->GetProjection(); - - Int_t N = fBuff->NbPnts(); - Vector* pnts = new Vector[N]; - for(Int_t i = 0; ifPnts[3*i],fBuff->fPnts[3*i+1], fBuff->fPnts[3*i+2]); - projection->ProjectPoint(pnts[i].x, pnts[i].y, pnts[i].z, NLTProjection::PP_Plane); - } - fIdxMap = new Int_t[N]; - Int_t* ra = new Int_t[N]; // list of reduced vertices - for(UInt_t v = 0; v < (UInt_t)N; ++v) - { - fIdxMap[v] = -1; - for(Int_t k = 0; k < fNPnts; ++k) - { - if(pnts[v].SquareDistance(pnts[ra[k]]) < NLTProjection::fgEps*NLTProjection::fgEps) - { - fIdxMap[v] = k; - break; - } - } - // have not found a point inside epsilon, add new point in scaled array - if(fIdxMap[v] == -1) - { - fIdxMap[v] = fNPnts; - ra[fNPnts] = v; - ++fNPnts; - } - // printf("(%f, %f) vertex map %d -> %d \n", pnts[v*2], pnts[v*2 + 1], v, fIdxMap[v]); - } - - // create an array of scaled points - fPnts = new Vector[fNPnts]; - for(Int_t idx = 0; idx < fNPnts; ++idx) - { - Int_t i = ra[idx]; - projection->ProjectPoint(pnts[i].x, pnts[i].y, pnts[i].z, NLTProjection::PP_Distort); - fPnts[idx].Set(pnts[i]); - } - delete [] ra; - delete [] pnts; - // printf("reduced %d points of %d\n", fNPnts, N); -} - -//______________________________________________________________________________ -void NLTPolygonSet::AddPolygon(std::list& pp, std::list& pols) -{ - if(pp.size() <= 2) return; - - // dimension of bbox - Float_t bbox[] = { 1e6, -1e6, 1e6, -1e6, 1e6, -1e6 }; - for (std::list::iterator u = pp.begin(); u!= pp.end(); u++) - { - Int_t idx = *u; - if(fPnts[idx].x < bbox[0]) bbox[0] = fPnts[idx].x; - if(fPnts[idx].x > bbox[1]) bbox[1] = fPnts[idx].x; - - if(fPnts[idx].y < bbox[2]) bbox[2] = fPnts[idx].y; - if(fPnts[idx].y > bbox[3]) bbox[3] = fPnts[idx].y; - } - Float_t eps = 2*NLTProjection::fgEps; - if((bbox[1]-bbox[0])::iterator poi = pols.begin(); poi!= pols.end(); poi++) - { - NLTPolygon P = *poi; - if (pp.size() != (UInt_t)P.fNPnts) - continue; - std::list::iterator u = pp.begin(); - Int_t pidx = P.FindPoint(*u); - if (pidx < 0) - continue; - while (u != pp.end()) - { - if ((*u) != P.fPnts[pidx]) - break; - ++u; - if (++pidx >= P.fNPnts) pidx = 0; - } - if (u == pp.end()) return; - } - - // printf("add %d NLTPolygon points %d \n", pols.size(), pp.size()); - Int_t* pv = new Int_t[pp.size()]; - Int_t count=0; - for( std::list::iterator u = pp.begin(); u!= pp.end(); u++){ - pv[count] = *u; - count++; - } - pols.push_back(NLTPolygon(pp.size(), pv)); - fSurf += (bbox[1]-bbox[0])*(bbox[3]-bbox[2]); - // printf("Add Surf %f\n",( bbox[1]-bbox[0])*(bbox[3]-bbox[2])); -} // AddPolygon - -//______________________________________________________________________________ -void NLTPolygonSet::MakePolygonsFromBP() -{ - // build polygons from sorted list of segments : buff->fPols - - // printf("START NLTPolygonSet::MakePolygonsFromBP\n"); - NLTProjection* projection = fProjector->GetProjection(); - Int_t* bpols = fBuff->fPols; - for(UInt_t pi = 0; pi< fBuff->NbPols(); pi++) - { - std::list pp; // points in current polygon - UInt_t Nseg = bpols[1]; - Int_t* seg = &bpols[2]; - // start idx in the fist segment depends of second segment - Int_t tail, head; - Bool_t h = IsFirstIdxHead(seg[0], seg[1]); - if(h) { - head = fIdxMap[fBuff->fSegs[3*seg[0] + 1]]; - tail = fIdxMap[fBuff->fSegs[3*seg[0] + 2]]; - } - else { - head = fIdxMap[fBuff->fSegs[3*seg[0] + 2]]; - tail = fIdxMap[fBuff->fSegs[3*seg[0] + 1]]; - } - pp.push_back(head); - // printf("start idx head %d, tail %d\n", head, tail); - std::list segs; - for(UInt_t s = 1; s < Nseg; ++s) - segs.push_back(Seg(fBuff->fSegs[3*seg[s] + 1],fBuff->fSegs[3*seg[s] + 2])); - - - Bool_t accepted = kFALSE; - for(std::list::iterator it = segs.begin(); it != segs.end(); it++ ) - { - Int_t mv1 = fIdxMap[(*it).v1]; - Int_t mv2 = fIdxMap[(*it).v2]; - accepted = projection->AcceptSegment(fPnts[mv1], fPnts[mv2], NLTProjection::fgEps); - - if(accepted == kFALSE) - { - pp.clear(); - break; - } - if(tail != pp.back()) pp.push_back(tail); - tail = (mv1 == tail) ? mv2 :mv1; - } - // DirectDraw implementation: last and first vertices should not be equal - if(pp.empty() == kFALSE) - { - if(pp.front() == pp.back()) pp.pop_front(); - AddPolygon(pp, fPolsBP); - } - bpols += (Nseg+2); - } -} - -//______________________________________________________________________________ -void NLTPolygonSet::MakePolygonsFromBS() -{ - // builds polygons from the set of buffer segments - - // create your own list of segments according to reduced and projected points - std::list segs; - std::list::iterator it; - NLTProjection* projection = fProjector->GetProjection(); - for(UInt_t s = 0; s < fBuff->NbSegs(); ++s) - { - Bool_t duplicate = kFALSE; - Int_t vo1, vo2; // idx from fBuff segment - Int_t vor1, vor2; // mapped idx - vo1 = fBuff->fSegs[3*s + 1]; - vo2 = fBuff->fSegs[3*s + 2]; //... skip color info - vor1 = fIdxMap[vo1]; - vor2 = fIdxMap[vo2]; - if(vor1 == vor2) continue; - // check duplicate - for(it = segs.begin(); it != segs.end(); it++ ){ - Int_t vv1 = (*it).v1; - Int_t vv2 = (*it).v2; - if((vv1 == vor1 && vv2 == vor2 )||(vv1 == vor2 && vv2 == vor1 )){ - duplicate = kTRUE; - continue; - } - } - if(duplicate == kFALSE && projection->AcceptSegment(fPnts[vor1], fPnts[vor2], NLTProjection::fgEps)) - { - segs.push_back(Seg(vor1, vor2)); - } - } - - // build polygons from segment pool - while(segs.empty() == kFALSE) - { - // printf("Start building polygon %d from %d segments in POOL \n", pols.size(), segs.size()); - std::list pp; // points in current polygon - pp.push_back(segs.front().v1); - Int_t tail = segs.front().v2; - segs.pop_front(); - Bool_t match = kTRUE; - while(match && segs.empty() == kFALSE) - { - // printf("second loop search tail %d \n",tail); - for(It_t k=segs.begin(); k!=segs.end(); ++k){ - Int_t cv1 = (*k).v1; - Int_t cv2 = (*k).v2; - if( cv1 == tail || cv2 == tail){ - // printf("found point %d in %d,%d \n", tail, cv1, cv2); - pp.push_back(tail); - tail = (cv1 == tail)? cv2:cv1; - It_t to_erase = k--; - segs.erase(to_erase); - match = kTRUE; - break; - } - else - { - match = kFALSE; - } - } // end for loop in the segment pool - if(tail == pp.front()) - break; - }; - AddPolygon(pp, fPolsBS); - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void NLTPolygonSet::ProjectBuffer3D() -{ - //DumpBuffer3D(); - ProjectAndReducePoints(); - NLTProjection::GeoMode_e mode = fProjector->GetProjection()->GetGeoMode(); - - switch (mode) - { - case NLTProjection::GM_Polygons : - { - MakePolygonsFromBP(); - fPolsBP.swap(fPols); - break; - } - case NLTProjection::GM_Segments : - { - MakePolygonsFromBS(); - fPolsBS.swap(fPols); - break; - } - case NLTProjection::GM_Unknown: - { - Float_t BPsurf = fSurf; - fSurf = 0; - MakePolygonsFromBS(); - if(fSurf < BPsurf) - { - fPolsBP.swap(fPols); - fPolsBS.clear(); - } - else - { - fPolsBS.swap(fPols); - fPolsBP.clear(); - } - } - default: - break; - } - - delete [] fIdxMap; - ResetBBox(); -} - -//______________________________________________________________________________ -void NLTPolygonSet::ComputeBBox() -{ - BBoxInit(); - for(Int_t pi = 0; piGetViewer3D()->AddObject(buffer); - if (reqSections == TBuffer3D::kNone) { - return; - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void NLTPolygonSet::DumpPolys() const -{ - printf("NLTPolygonSet %d polygons\n", fPols.size()); - for (vpPolygon_ci i = fPols.begin(); i!= fPols.end(); i++) - { - Int_t N = (*i).fNPnts; - printf("polygon %d points :\n", N); - for(Int_t vi = 0; vifPols; - - for(UInt_t pi = 0; pi< fBuff->NbPols(); pi++) - { - UInt_t Nseg = bpols[1]; - printf("%d polygon of %d has %d segments \n", pi,fBuff->NbPols(),Nseg); - - Int_t* seg = &bpols[2]; - for(UInt_t a=0; afSegs[3*seg[a]+ 1]; - Int_t a2 = fBuff->fSegs[3*seg[a]+ 2]; - printf("(%d, %d) \n", a1, a2); - printf("ORIG points :(%f, %f, %f) (%f, %f, %f)\n", - fBuff->fPnts[3*a1],fBuff->fPnts[3*a1+1], fBuff->fPnts[3*a1+2], - fBuff->fPnts[3*a2],fBuff->fPnts[3*a2+1], fBuff->fPnts[3*a2+2]); - } - printf("\n"); - bpols += (Nseg+2); - } -} diff --git a/EVE/Reve/NLTPolygonSet.h b/EVE/Reve/NLTPolygonSet.h deleted file mode 100644 index 515eff28e8f..00000000000 --- a/EVE/Reve/NLTPolygonSet.h +++ /dev/null @@ -1,124 +0,0 @@ -#ifndef REVE_NLTPolygonSet_H -#define REVE_NLTPolygonSet_H - -#include -#include - -#include "TNamed.h" -#include "TAtt3D.h" -#include "TAttBBox.h" -#include "TColor.h" -#include "PODs.h" - -class TBuffer3D; - -namespace std { - template class allocator; - template class list; -} - -namespace Reve { - -class Vector; - -class NLTPolygon -{ -public: - Int_t fNPnts; - Int_t* fPnts; - - NLTPolygon() : fNPnts(0), fPnts(0) {} - NLTPolygon(Int_t n, Int_t* p) : fNPnts(n), fPnts(p) {} - NLTPolygon(const NLTPolygon& x) : fNPnts(x.fNPnts), fPnts(x.fPnts) {} - virtual ~NLTPolygon() {} - - NLTPolygon& operator=(const NLTPolygon& x) - { fNPnts = x.fNPnts; fPnts = x.fPnts; return *this; } - - Int_t FindPoint(Int_t pi) - { for (Int_t i=0; i vpPolygon_t; - typedef vpPolygon_t::iterator vpPolygon_i; - typedef vpPolygon_t::const_iterator vpPolygon_ci; - -private: - TBuffer3D* fBuff; - Int_t* fIdxMap; // map from original to projected and reduced point needed oly for geometry - - Bool_t IsFirstIdxHead(Int_t s0, Int_t s1); - void AddPolygon(std::list >& pp, std::list >& p); - - void ProjectAndReducePoints(); - void MakePolygonsFromBP(); - void MakePolygonsFromBS(); - void ClearPolygonSet(); - -protected: - vpPolygon_t fPols; // NLT polygons - vpPolygon_t fPolsBS; // NLT polygons build freom TBuffer3D segments - vpPolygon_t fPolsBP; // NLT polygons build freom TBuffer3D polygond - Float_t fSurf; // sum of surface of polygons - - // Float_t fEps; // distance accounted in reducing the ponts - Int_t fNPnts; // number of reduced and projected points - Vector* fPnts; // reduced and projected points - - Color_t fFillColor; - Color_t fLineColor; - Float_t fLineWidth; - - UChar_t fTransparency; - -public: - NLTPolygonSet(const Text_t* n="NLTPolygonSet", const Text_t* t=""); - virtual ~NLTPolygonSet(); - - virtual void SetProjection(NLTProjector* proj, NLTProjectable* model); - virtual void UpdateProjection(); - - void ProjectBuffer3D(); - - virtual void ComputeBBox(); - virtual void Paint(Option_t* option = ""); - - virtual void DumpPolys() const; - void DumpBuffer3D(); - - //rendering - virtual Bool_t CanEditMainColor() { return kTRUE; } - virtual Color_t GetLineColor() const { return fLineColor; } - - virtual Bool_t CanEditMainTransparency() { return kTRUE; } - virtual UChar_t GetMainTransparency() const { return fTransparency; } - virtual void SetMainTransparency(UChar_t t) { fTransparency = t; } - - virtual void SetFillColor(Pixel_t pixel) { fFillColor = Color_t(TColor::GetColor(pixel));} - virtual void SetLineColor(Pixel_t pixel) { fLineColor = Color_t(TColor::GetColor(pixel));} - - virtual void SetFillColor(Color_t c) { fFillColor = c; } - virtual void SetLineColor(Color_t c) { fLineColor = c; } - virtual void SetLineWidth(Double_t lw){fLineWidth = lw;} - - ClassDef(NLTPolygonSet,0) - - }; // endclass NLTPolygonSet -} // namespace Reve - -#endif diff --git a/EVE/Reve/NLTPolygonSetEditor.cxx b/EVE/Reve/NLTPolygonSetEditor.cxx deleted file mode 100644 index 50a94437b45..00000000000 --- a/EVE/Reve/NLTPolygonSetEditor.cxx +++ /dev/null @@ -1,96 +0,0 @@ -#include "NLTPolygonSetEditor.h" -#include - -#include - -#include -#include -#include -#include - -using namespace Reve; - - -ClassImp(NLTPolygonSetEditor) - - NLTPolygonSetEditor::NLTPolygonSetEditor(const TGWindow *p, - Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - fPS(0), - // fFillColor(0), - fLineWidth(0), - fLineColor(0) -{ - MakeTitle("NLTPolygonSet"); - /* - { - TGCompositeFrame *f1 = new TGCompositeFrame(this, 80, 20, kHorizontalFrame); - TGLabel *l = new TGLabel(f1, "FillColor:"); - f1->AddFrame(l, new TGLayoutHints(kLHintsLeft | kLHintsCenterY, 25, 2, 1, 1)); - fFillColor = new TGColorSelect(f1, 0, -1); - fFillColor->Connect("ColorSelected(Pixel_t)", "Reve::NLTPolygonSetEditor", this, "DoFillColor(Pixel_t)"); - f1->AddFrame(fFillColor, new TGLayoutHints(kLHintsLeft, 1, 1, 1, 1)); - AddFrame(f1, new TGLayoutHints(kLHintsTop, 1, 1, 0, 0)); - } - */ - - { - TGCompositeFrame *f = new TGCompositeFrame(this, 80, 20, kHorizontalFrame); - - TGLabel *l = new TGLabel(f, "LineColor:"); - f->AddFrame(l, new TGLayoutHints(kLHintsLeft | kLHintsCenterY, 25, 2, 1, 1)); - fLineColor = new TGColorSelect(f, 0, -1); - fLineColor->Connect("ColorSelected(Pixel_t)", "Reve::NLTPolygonSetEditor", this, "DoLineColor(Pixel_t)"); - f->AddFrame(fLineColor, new TGLayoutHints(kLHintsLeft, 1, 1, 1, 1)); - - fLineWidth = new TGNumberEntry(f, 0., 6, -1, - TGNumberFormat::kNESRealOne, TGNumberFormat::kNEAPositive, - TGNumberFormat::kNELLimitMinMax, 0.1, 2000.0); - fLineWidth->GetNumberEntry()->SetToolTipText("Line witdth of outline."); - fLineWidth->Connect("ValueSet(Long_t)", "Reve::NLTPolygonSetEditor", this, "DoLineWidth()"); - f->AddFrame(fLineWidth, new TGLayoutHints(kLHintsLeft, 1, 1, 1, 1)); - - AddFrame(f, new TGLayoutHints(kLHintsTop, 1, 1, 0, 0)); - } -} - - -/**************************************************************************/ -NLTPolygonSetEditor::~NLTPolygonSetEditor() -{} - -/**************************************************************************/ -/* -void NLTPolygonSetEditor::DoFillColor(Pixel_t pixel) -{ - printf("do fill color \n"); - fPS->SetFillColor(pixel); - Update(); -} -*/ -/**************************************************************************/ -void NLTPolygonSetEditor::DoLineWidth() -{ - // Double_t lw = fLineWidth->GetNumber(); - //fPS->SetLineWidth(lw); - fPS->fLineWidth = fLineWidth->GetNumber(); - Update(); -} - -/**************************************************************************/ -void NLTPolygonSetEditor::DoLineColor(Pixel_t pixel) -{ - fPS->SetLineColor(pixel); - Update(); -} - -/**************************************************************************/ - -void NLTPolygonSetEditor::SetModel(TObject* obj) -{ - fPS = dynamic_cast(obj); - // fFillColor->SetColor(TColor::Number2Pixel(fPS->GetFillColor()), kFALSE); - fLineWidth->SetNumber(fPS->fLineWidth); - fLineColor->SetColor(TColor::Number2Pixel(fPS->GetLineColor()), kFALSE); -} diff --git a/EVE/Reve/NLTPolygonSetEditor.h b/EVE/Reve/NLTPolygonSetEditor.h deleted file mode 100644 index afd4c5794f1..00000000000 --- a/EVE/Reve/NLTPolygonSetEditor.h +++ /dev/null @@ -1,39 +0,0 @@ -#ifndef REVE_NLTPolygonSetEditor_H -#define REVE_NLTPolygonSetEditor_H - -#include -class TGNumberEntry; -class TGColorSelect; - -namespace Reve { - -class NLTPolygonSet; -class NLTPolygonSetEditor : public TGedFrame -{ - NLTPolygonSetEditor(const NLTPolygonSetEditor&); // Not implemented - NLTPolygonSetEditor& operator=(const NLTPolygonSetEditor&); // Not implemented - -protected: - NLTPolygonSet* fPS; // fModel dynamic-casted to NLTPolygonSetEditor - - // TGColorSelect *fFillColor; // fill color widget - - TGNumberEntry *fLineWidth; - TGColorSelect *fLineColor; // fill color widget - -public: - NLTPolygonSetEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, - UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - ~NLTPolygonSetEditor(); - - virtual void SetModel(TObject* obj); - - //virtual void DoFillColor(Pixel_t color); - - virtual void DoLineWidth(); - virtual void DoLineColor(Pixel_t color); - - ClassDef(NLTPolygonSetEditor, 0); // Editor for NLTPolygonSet -}; // endclass NLTPolygonSetEditor -} -#endif diff --git a/EVE/Reve/NLTPolygonSetGL.cxx b/EVE/Reve/NLTPolygonSetGL.cxx deleted file mode 100644 index bc74481c5db..00000000000 --- a/EVE/Reve/NLTPolygonSetGL.cxx +++ /dev/null @@ -1,142 +0,0 @@ -#include "NLTPolygonSetGL.h" -#include "NLTPolygonSet.h" -#include "PODs.h" - -#include -#include - - -using namespace Reve; - -/**************************************************************************/ - -NLTPolygonSetGL::NLTPolygonSetGL() : TGLObject() -{ - // fDLCache = false; // Disable DL. -} - -NLTPolygonSetGL::~NLTPolygonSetGL() -{} - -/**************************************************************************/ -Bool_t NLTPolygonSetGL::SetModel(TObject* obj, const Option_t* /*opt*/) -{ - return SetModelCheckClass(obj, NLTPolygonSet::Class()); -} - -/**************************************************************************/ - -void NLTPolygonSetGL::SetBBox() -{ - SetAxisAlignedBBox(((NLTPolygonSet*)fExternalObj)->AssertBBox()); -} - -/**************************************************************************/ -static GLUtriangulatorObj *GetTesselator() -{ - static struct Init { - Init() - { -#if defined(R__WIN32) - typedef void (CALLBACK *tessfuncptr_t)(); -#elif defined(R__AIXGCC) - typedef void (*tessfuncptr_t)(...); -#else - typedef void (*tessfuncptr_t)(); -#endif - fTess = gluNewTess(); - - if (!fTess) { - Error("GetTesselator::Init", "could not create tesselation object"); - } else { - gluTessCallback(fTess, (GLenum)GLU_BEGIN, (tessfuncptr_t)glBegin); - gluTessCallback(fTess, (GLenum)GLU_END, (tessfuncptr_t)glEnd); - gluTessCallback(fTess, (GLenum)GLU_VERTEX, (tessfuncptr_t)glVertex3fv); - } - } - ~Init() - { - if(fTess) - gluDeleteTess(fTess); - } - GLUtriangulatorObj *fTess; - }singleton; - - return singleton.fTess; -} - -/**************************************************************************/ -void NLTPolygonSetGL::DirectDraw(TGLRnrCtx & /*rnrCtx*/) const -{ - // printf("NLTPolygonSetGL::DirectDraw %s \n",fExternalObj->GetName() ); - NLTPolygonSet& PS = * (NLTPolygonSet*) fExternalObj; - if(PS.fPols.size() == 0) return; - - glPushAttrib(GL_ENABLE_BIT | GL_LINE_BIT | GL_POLYGON_BIT); - - glDisable(GL_LIGHTING); - glColorMaterial(GL_FRONT_AND_BACK, GL_DIFFUSE); - glEnable(GL_COLOR_MATERIAL); - glPolygonMode(GL_FRONT_AND_BACK, GL_FILL); - glDisable(GL_CULL_FACE); - - // polygons - glEnable(GL_POLYGON_OFFSET_FILL); - glPolygonOffset(1.,1.); - GLUtriangulatorObj *tessObj = GetTesselator(); - - Vector* pnts = PS.fPnts; - for (NLTPolygonSet::vpPolygon_ci i = PS.fPols.begin(); i!= PS.fPols.end(); i++) - { - Int_t vi; //current vertex index of curent polygon - Int_t N = (*i).fNPnts; // number of points in current polygon - if(N < 4) - { - glBegin(GL_POLYGON); - for(Int_t k=0; k - -namespace Reve { - -class NLTPolygonSetGL : public TGLObject -{ -protected: - virtual void DirectDraw(TGLRnrCtx & rnrCtx) const; - -public: - NLTPolygonSetGL(); - virtual ~NLTPolygonSetGL(); - - virtual Bool_t SetModel(TObject* obj, const Option_t* opt=0); - virtual Bool_t IgnoreSizeForOfInterest() const { return kTRUE; } - virtual void SetBBox(); - - ClassDef(NLTPolygonSetGL,0) // GL renderer for NLTPolygonSet3D -}; - -} -#endif diff --git a/EVE/Reve/NLTProjections.cxx b/EVE/Reve/NLTProjections.cxx deleted file mode 100644 index d385c897bd4..00000000000 --- a/EVE/Reve/NLTProjections.cxx +++ /dev/null @@ -1,268 +0,0 @@ -#include "NLTProjections.h" -#include "Reve.h" - -using namespace Reve; - - -//______________________________________________________________________________ -// NLTProjection -// -// Base-class for non-linear projection of 3D point. -// Enables to define an external center of distortion and a scale to -// fixate a bounding box of a projected point. - -ClassImp(Reve::NLTProjection) - -Float_t NLTProjection::fgEps = 0.005f; -//______________________________________________________________________________ -NLTProjection::NLTProjection(Vector& center) : - fType(PT_Unknown), - fGeoMode(GM_Unknown), - fName(0), - fCenter(center.x, center.y, center.z), - fDistortion(0.0f), - fFixedRadius(300), - fScale(1.0f) -{ - // Constructor. -} - -//______________________________________________________________________________ -void NLTProjection::ProjectVector(Vector& v) -{ - // Project Reve::Vector. - - ProjectPoint(v.x, v.y, v.z); -} - -//______________________________________________________________________________ -void NLTProjection::UpdateLimit() -{ - // Update convergence in +inf and -inf. - - if ( fDistortion == 0.0f ) - return; - - Float_t lim = 1.0f/fDistortion + fFixedRadius; - Float_t* c = GetProjectedCenter(); - fUpLimit.Set(lim + c[0], lim + c[1], c[2]); - fLowLimit.Set(-lim + c[0], -lim + c[1], c[2]); -} - -//______________________________________________________________________________ -void NLTProjection::SetDistortion(Float_t d) -{ - // Set distortion. - - fDistortion=d; - fScale = 1+fFixedRadius*fDistortion; - UpdateLimit(); -} - -//______________________________________________________________________________ -void NLTProjection::SetFixedRadius(Float_t r) -{ - // Set fixed radius. - - fFixedRadius=r; - fScale = 1 + fFixedRadius*fDistortion; - UpdateLimit(); -} - -//______________________________________________________________________________ -void NLTProjection::SetDirectionalVector(Int_t screenAxis, Vector& vec) -{ - // Get vector for axis in a projected space. - - for (Int_t i=0; i<3; i++) - { - vec[i] = (i==screenAxis) ? 1. : 0.; - } -} - -//______________________________________________________________________________ -Float_t NLTProjection::GetValForScreenPos(Int_t i, Float_t sv) -{ - // Inverse projection. - - static const Exc_t eH("NLTProjection::GetValForScreenPos "); - - Float_t xL, xM, xR; - Vector V, DirVec; - SetDirectionalVector(i, DirVec); - if (fDistortion > 0.0f && ((sv > 0 && sv > fUpLimit[i]) || (sv < 0 && sv < fLowLimit[i]))) - throw(eH + Form("screen value '%f' out of limit '%f'.", sv, sv > 0 ? fUpLimit[i] : fLowLimit[i])); - - Vector zero; ProjectVector(zero); - // search from -/+ infinity according to sign of screen value - if (sv > zero[i]) - { - xL = 0; xR = 1000; - while (1) - { - V.Mult(DirVec, xR); ProjectVector(V); - // printf("positive projected %f, value %f,xL, xR ( %f, %f)\n", V[i], sv, xL, xR); - if (V[i] > sv || V[i] == sv) break; - xL = xR; xR *= 2; - } - } - else if (sv < zero[i]) - { - xR = 0; xL = -1000; - while (1) - { - V.Mult(DirVec, xL); ProjectVector(V); - // printf("negative projected %f, value %f,xL, xR ( %f, %f)\n", V[i], sv, xL, xR); - if (V[i] < sv || V[i] == sv) break; - xR = xL; xL *= 2; - } - } - else - { - return 0.0f; - } - - do - { - xM = 0.5f * (xL + xR); - V.Mult(DirVec, xM); - ProjectVector(V); - if (V[i] > sv) - xR = xM; - else - xL = xM; - } while(TMath::Abs(V[i] - sv) >= fgEps); - - return xM; -} - -//______________________________________________________________________________ -Float_t NLTProjection::GetScreenVal(Int_t i, Float_t x) -{ - // Project point on given axis and return projected value. - - Vector dv; - SetDirectionalVector(i, dv); dv = dv*x; - ProjectVector(dv); - return dv[i]; -} - - -//______________________________________________________________________________ -// NLTRhoZ -// -// Transformation from 3D to 2D. X axis represent Z coordinate. Y axis have value of -// radius with a sign of Y coordinate. - -ClassImp(Reve::NLTRhoZ) - -//______________________________________________________________________________ -void NLTRhoZ::SetCenter(Vector& v) -{ - // Set center of distortion (virtual method). - - fCenter = v; - - Float_t R = TMath::Sqrt(v.x*v.x+v.y*v.y); - fProjectedCenter.x = fCenter.z; - fProjectedCenter.y = TMath::Sign(R, fCenter.y); - fProjectedCenter.z = 0; - UpdateLimit(); -} - -//______________________________________________________________________________ -void NLTRhoZ::ProjectPoint(Float_t& x, Float_t& y, Float_t& z, PProc_e proc ) -{ - // Project point. - - using namespace TMath; - - if(proc == PP_Plane || proc == PP_Full) - { - // project - y = Sign((Float_t)Sqrt(x*x+y*y), y); - x = z; - } - if(proc == PP_Distort || proc == PP_Full) - { - // move to center - x -= fProjectedCenter.x; - y -= fProjectedCenter.y; - // distort - y = (y*fScale) / (1.0f + Abs(y)*fDistortion); - x = (x*fScale) / (1.0f + Abs(x)*fDistortion); - // move back from center - x += fProjectedCenter.x; - y += fProjectedCenter.y; - } - z = 0.0f; -} - -//______________________________________________________________________________ -void NLTRhoZ::SetDirectionalVector(Int_t screenAxis, Vector& vec) -{ - // Get direction in the unprojected space for axis index in the projected space. - // This is virtual method from base-class NLTProjection. - - if(screenAxis == 0) - vec.Set(0., 0., 1); - else if (screenAxis == 1) - vec.Set(0., 1., 0); - -} -//______________________________________________________________________________ -Bool_t NLTRhoZ::AcceptSegment(Vector& v1, Vector& v2, Float_t tolerance) -{ - // Check if segment of two projected points is valid. - - Float_t a = fProjectedCenter.y; - Bool_t val = kTRUE; - if((v1.y < a && v2.y > a) || (v1.y > a && v2.y < a)) - { - val = kFALSE; - if (tolerance > 0) - { - Float_t a1 = TMath::Abs(v1.y - a), a2 = TMath::Abs(v2.y - a); - if (a1 < a2) - { - if (a1 < tolerance) { v1.y = a; val = kTRUE; } - } - else - { - if (a2 < tolerance) { v2.y = a; val = kTRUE; } - } - } - } - return val; -} - - -//______________________________________________________________________________ -// NLTCircularFishEye -// -// XY projection with distortion around given center. - -ClassImp(Reve::NLTCircularFishEye) - -//______________________________________________________________________________ -void NLTCircularFishEye::ProjectPoint(Float_t& x, Float_t& y, Float_t& z, - PProc_e proc) -{ - // Project point. - - using namespace TMath; - - if (proc != PP_Plane) - { - x -= fCenter.x; - y -= fCenter.y; - Float_t phi = x == 0.0 && y == 0.0 ? 0.0 : ATan2(y,x); - Float_t R = Sqrt(x*x+y*y); - // distort - Float_t NR = (R*fScale) / (1.0f + R*fDistortion); - x = NR*Cos(phi) + fCenter.x; - y = NR*Sin(phi) + fCenter.y; - } - z = 0.0f; -} - diff --git a/EVE/Reve/NLTProjections.h b/EVE/Reve/NLTProjections.h deleted file mode 100644 index 5afeb6f4b4b..00000000000 --- a/EVE/Reve/NLTProjections.h +++ /dev/null @@ -1,115 +0,0 @@ -#ifndef REVE_NLTProjections -#define REVE_NLTProjections - -#include - -namespace Reve { - -//////////////////////////////////////////////////////////////// -// // -// NLTProjection // -// // -//////////////////////////////////////////////////////////////// - -class NLTProjection -{ -public: - enum PType_e { PT_Unknown, PT_CFishEye, PT_RhoZ }; // type - enum PProc_e { PP_Plane, PP_Distort, PP_Full }; // procedure - enum GeoMode_e { GM_Unknown, GM_Polygons, GM_Segments }; // reconstruction of geometry - -protected: - PType_e fType; // type - GeoMode_e fGeoMode; // way of polygon reconstruction - const char* fName; // name - - Vector fCenter; // center of distortion - Vector fZeroPosVal; // projected origin (0, 0, 0) - - Float_t fDistortion; // distortion - Float_t fFixedRadius; // projected radius independent of distortion - Float_t fScale; // scale factor to keep projected radius fixed - Vector fUpLimit; // convergence of point +infinity - Vector fLowLimit; // convergence of point -infinity - -public: - NLTProjection(Vector& center); - virtual ~NLTProjection(){} - - virtual void ProjectPoint(Float_t&, Float_t&, Float_t&, PProc_e p = PP_Full ) = 0; - virtual void ProjectPointFv(Float_t* v){ ProjectPoint(v[0], v[1], v[2]); } - virtual void ProjectVector(Vector& v); - - const char* GetName(){return fName;} - void SetName(const char* txt){ fName = txt; } - - virtual void SetCenter(Vector& v){ fCenter = v; UpdateLimit();} - virtual Float_t* GetProjectedCenter() { return fCenter.c_vec(); } - - void SetType(PType_e t){fType = t;} - PType_e GetType(){return fType;} - - void SetGeoMode(GeoMode_e m){fGeoMode = m;} - GeoMode_e GetGeoMode(){return fGeoMode;} - - void UpdateLimit(); - void SetDistortion(Float_t d); - Float_t GetDistortion(){return fDistortion;} - void SetFixedRadius(Float_t x); - Float_t GetFixedRadius(){return fFixedRadius;} - - virtual Bool_t AcceptSegment(Vector&, Vector&, Float_t /*tolerance*/) { return kTRUE; } - virtual void SetDirectionalVector(Int_t screenAxis, Vector& vec); - - // utils to draw axis - virtual Float_t GetValForScreenPos(Int_t ax, Float_t value); - virtual Float_t GetScreenVal(Int_t ax, Float_t value); - Float_t GetLimit(Int_t i, Bool_t pos) { return pos ? fUpLimit[i] : fLowLimit[i]; } - - static Float_t fgEps; // resolution of projected points - - ClassDef(NLTProjection, 0); // Base-class for non-linear projection. -}; // endclass NLTProjection - -//////////////////////////////////////////////////////////////// -// // -// NLTRhoZ // -// // -//////////////////////////////////////////////////////////////// - -class NLTRhoZ: public NLTProjection -{ -private: - Vector fProjectedCenter; // projected center of distortion. -public: - NLTRhoZ(Vector& center) : NLTProjection(center) { fType = PT_RhoZ; fName="RhoZ"; } - virtual ~NLTRhoZ() {} - - virtual Bool_t AcceptSegment(Vector& v1, Vector& v2, Float_t tolerance); - virtual void ProjectPoint(Float_t& x, Float_t& y, Float_t& z, PProc_e proc = PP_Full); - virtual void SetDirectionalVector(Int_t screenAxis, Vector& vec); - - virtual void SetCenter(Vector& center); - virtual Float_t* GetProjectedCenter() { return fProjectedCenter.c_vec(); } - ClassDef(NLTRhoZ, 0); // Rho/Z non-linear projection. -}; // endclass NLTRhoZ - -//////////////////////////////////////////////////////////////// -// // -// NLTCircularFishEye // -// // -//////////////////////////////////////////////////////////////// - -class NLTCircularFishEye : public NLTProjection -{ -public: - NLTCircularFishEye(Vector& center):NLTProjection(center) { fType = PT_CFishEye; fGeoMode = GM_Polygons; fName="CircularFishEye"; } - virtual ~NLTCircularFishEye() {} - - virtual void ProjectPoint(Float_t& x, Float_t& y, Float_t& z, PProc_e proc = PP_Full); - - ClassDef(NLTCircularFishEye, 0); // XY non-linear projection. -}; // endclass NLTCircularFishEye - -} -#endif diff --git a/EVE/Reve/NLTProjector.cxx b/EVE/Reve/NLTProjector.cxx deleted file mode 100644 index 5c6f5d56513..00000000000 --- a/EVE/Reve/NLTProjector.cxx +++ /dev/null @@ -1,244 +0,0 @@ -#include "NLTProjector.h" -#include "ReveManager.h" -#include "NLTBases.h" - -#include "TBuffer3D.h" -#include "TBuffer3DTypes.h" -#include -#include - -#include - -using namespace Reve; - -//______________________________________________________________________________ -// NLTProjector -// -// Recursively projects RenderElement and draws axis in the projected scene. -// It enables to interactivly set NLTProjection parameters and updates -// projected scene accordingly. - -ClassImp(NLTProjector) - -//______________________________________________________________________________ -NLTProjector::NLTProjector(): - RenderElementList("NLTProjector",""), - - fProjection (0), - - fDrawCenter(kFALSE), - fDrawOrigin(kFALSE), - - fSplitInfoMode(0), - fSplitInfoLevel(1), - fAxisColor(0), - - fCurrentDepth(0) -{ - // Constructor. - - fProjection = new NLTCircularFishEye(fCenter); - UpdateName(); -} - -//______________________________________________________________________________ -NLTProjector::~NLTProjector() -{ - // Destructor. - - if(fProjection) delete fProjection; -} - -//______________________________________________________________________________ -void NLTProjector::UpdateName() -{ - // Updates name to have consitent information with prjection. - - SetName(Form ("%s (%3.1f)", fProjection->GetName(), fProjection->GetDistortion()*1000)); - UpdateItems(); -} - -//______________________________________________________________________________ -void NLTProjector::SetProjection(NLTProjection::PType_e type, Float_t distort) -{ - // Set projection type and distortion. - - static const Exc_t eH("NLTProjector::SetProjection "); - - delete fProjection; - fProjection = 0; - - switch (type) - { - case NLTProjection::PT_CFishEye: - { - fProjection = new NLTCircularFishEye(fCenter); - break; - } - case NLTProjection::PT_RhoZ: - { - fProjection = new NLTRhoZ(fCenter); - break; - } - default: - throw(eH + "projection type not valid."); - break; - } - fProjection->SetDistortion(distort); - UpdateName(); -} -//______________________________________________________________________________ -void NLTProjector::SetCenter(Float_t x, Float_t y, Float_t z) -{ - // Set projection center and rebuild projected scene. - - fCenter.Set(x, y, z); - fProjection->SetCenter(fCenter); - ProjectChildren(); -} - -//______________________________________________________________________________ -Bool_t NLTProjector::HandleElementPaste(RenderElement* el) -{ - // React to element being pasted or dnd-ed. - // Return true if redraw is needed (virtual method). - - size_t n_children = fChildren.size(); - ImportElements(el); - return n_children != fChildren.size(); -} - -//______________________________________________________________________________ -Bool_t NLTProjector::ShouldImport(RenderElement* rnr_el) -{ - // Returns true if rnr_el or any of its children is NTLProjectable. - - if (rnr_el->IsA()->InheritsFrom(NLTProjectable::Class())) - return kTRUE; - for (List_i i=rnr_el->BeginChildren(); i!=rnr_el->EndChildren(); ++i) - if (ShouldImport(*i)) - return kTRUE; - return kFALSE; -} - -//______________________________________________________________________________ -void NLTProjector::ImportElementsRecurse(RenderElement* rnr_el, RenderElement* parent) -{ - // If rnr_el is NLTProjectable add projected instance else add plain RenderElementList - // to parent. Call same function on rnr_el children. - - if (ShouldImport(rnr_el)) - { - RenderElement *new_re = 0; - NLTProjected *new_pr = 0; - NLTProjectable *pble = dynamic_cast(rnr_el); - if (pble) - { - new_re = (RenderElement*) pble->ProjectedClass()->New(); - new_pr = dynamic_cast(new_re); - new_pr->SetProjection(this, pble); - new_pr->SetDepth(fCurrentDepth); - } - else - { - new_re = new RenderElementList; - } - TObject *tobj = rnr_el->GetObject(); - new_re->SetRnrElNameTitle(Form("NLT %s", tobj->GetName()), - tobj->GetTitle()); - new_re->SetRnrSelf (rnr_el->GetRnrSelf()); - new_re->SetRnrChildren(rnr_el->GetRnrChildren()); - gReve->AddRenderElement(new_re, parent); - - for (List_i i=rnr_el->BeginChildren(); i!=rnr_el->EndChildren(); ++i) - ImportElementsRecurse(*i, new_re); - } -} - -//______________________________________________________________________________ -void NLTProjector::ImportElements(RenderElement* rnr_el) -{ - // Recursively import elements and update projection on the projected objects. - - ImportElementsRecurse(rnr_el, this); - ProjectChildren(); -} - -//______________________________________________________________________________ -void NLTProjector::ProjectChildrenRecurse(RenderElement* rnr_el) -{ - // Go recursively through rnr_el tree and call UpdateProjection() on NLTProjected. - - NLTProjected* pted = dynamic_cast(rnr_el); - if (pted) - { - pted->UpdateProjection(); - TAttBBox* bb = dynamic_cast(pted); - if(bb) - { - Float_t* b = bb->AssertBBox(); - BBoxCheckPoint(b[0], b[2], b[4]); - BBoxCheckPoint(b[1], b[3], b[5]); - } - rnr_el->ElementChanged(kFALSE); - } - - for (List_i i=rnr_el->BeginChildren(); i!=rnr_el->EndChildren(); ++i) - ProjectChildrenRecurse(*i); -} - -//______________________________________________________________________________ -void NLTProjector::ProjectChildren() -{ - // Project children recursevly, update BBox and notify ReveManger - // the scenes have chenged. - - BBoxZero(); - ProjectChildrenRecurse(this); - AssertBBoxExtents(0.1); - { - using namespace TMath; - fBBox[0] = 10.0f * Floor(fBBox[0]/10.0f); - fBBox[1] = 10.0f * Ceil (fBBox[1]/10.0f); - fBBox[2] = 10.0f * Floor(fBBox[2]/10.0f); - fBBox[3] = 10.0f * Ceil (fBBox[3]/10.0f); - } - - List_t scenes; - CollectSceneParentsFromChildren(scenes, 0); - gReve->ScenesChanged(scenes); -} - -//______________________________________________________________________________ -void NLTProjector::Paint(Option_t* /*option*/) -{ - // Paint this object. Only direct rendering is supported. - - static const Exc_t eH("NLTProjector::Paint "); - TBuffer3D buff(TBuffer3DTypes::kGeneric); - - // Section kCore - buff.fID = this; - buff.fColor = fAxisColor; - buff.fTransparency = 0; - buff.SetSectionsValid(TBuffer3D::kCore); - - Int_t reqSections = gPad->GetViewer3D()->AddObject(buff); - if (reqSections != TBuffer3D::kNone) - Error(eH, "only direct GL rendering supported."); -} - -//______________________________________________________________________________ -void NLTProjector::ComputeBBox() -{ - // Virtual from TAttBBox; fill bounding-box information. - - static const Exc_t eH("NLTProjector::ComputeBBox "); - - if(GetNChildren() == 0) { - BBoxZero(); - return; - } - - BBoxInit(); -} diff --git a/EVE/Reve/NLTProjector.h b/EVE/Reve/NLTProjector.h deleted file mode 100644 index b9f13e2860a..00000000000 --- a/EVE/Reve/NLTProjector.h +++ /dev/null @@ -1,75 +0,0 @@ -#ifndef REVE_NLTProjector -#define REVE_NLTProjector - -#include -#include - -#include -#include -#include - -namespace Reve { - -class NLTProjector : public RenderElementList, - public TAttBBox, - public TAtt3D -{ -private: - NLTProjector(const NLTProjector&); // Not implemented - NLTProjector& operator=(const NLTProjector&); // Not implemented - - NLTProjection* fProjection; // projection - - Bool_t fDrawCenter; // draw center of distortion - Bool_t fDrawOrigin; // draw origin - Vector fCenter; // center of distortion - - Int_t fSplitInfoMode; // tick-mark position - Int_t fSplitInfoLevel; // tick-mark density - Color_t fAxisColor; // color of axis - - Float_t fCurrentDepth; // z depth of object being projected - - virtual Bool_t ShouldImport(RenderElement* rnr_el); - -public: - NLTProjector(); - virtual ~NLTProjector(); - - void SetProjection(NLTProjection::PType_e type, Float_t distort=0); - NLTProjection* GetProjection() { return fProjection; } - - virtual void UpdateName(); - - void SetAxisColor(Color_t col) { fAxisColor = col; } - Color_t GetAxisColor() const { return fAxisColor; } - void SetSplitInfoMode(Int_t x) { fSplitInfoMode = x; } - Int_t GetSplitInfoMode() const { return fSplitInfoMode; } - void SetSplitInfoLevel(Int_t x) { fSplitInfoLevel = x; } - Int_t GetSplitInfoLevel() const { return fSplitInfoLevel; } - - void SetDrawCenter(Bool_t x){ fDrawCenter = x; } - Bool_t GetDrawCenter(){ return fDrawCenter; } - void SetDrawOrigin(Bool_t x){ fDrawOrigin = x; } - Bool_t GetDrawOrigin(){ return fDrawOrigin; } - - void SetCenter(Float_t x, Float_t y, Float_t z); - Vector& GetCenter(){return fCenter;} - - void SetCurrentDepth(Float_t d) { fCurrentDepth = d; } - Float_t GetCurrentDepth() const { return fCurrentDepth; } - - virtual Bool_t HandleElementPaste(RenderElement* el); - virtual void ImportElementsRecurse(RenderElement* rnr_el, RenderElement* parent); - virtual void ImportElements(RenderElement* rnr_el); - virtual void ProjectChildren(); - virtual void ProjectChildrenRecurse(RenderElement* rnr_el); - - virtual void ComputeBBox(); - virtual void Paint(Option_t* option = ""); - - ClassDef(NLTProjector, 0); // Manages and steers NLT projections. -}; - -} -#endif diff --git a/EVE/Reve/NLTProjectorEditor.cxx b/EVE/Reve/NLTProjectorEditor.cxx deleted file mode 100644 index 44905b3b67e..00000000000 --- a/EVE/Reve/NLTProjectorEditor.cxx +++ /dev/null @@ -1,327 +0,0 @@ -// $Header$ - -#include "NLTProjectorEditor.h" -#include - -#include - -#include -#include -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// NLTProjectorEditor -// -// GUI editor for class NLTProjector. -// - -ClassImp(NLTProjectorEditor) - -NLTProjectorEditor::NLTProjectorEditor(const TGWindow *p, - Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - fM(0), - - fType(0), - fDistortion(0), - fFixedRadius(0), - fCurrentDepth(0), - - fCenterFrame(0), - fDrawCenter(0), - fCenterX(0), - fCenterY(0), - fCenterZ(0), - - fAxisColor(0), - fSIMode(0), - fSILevel(0) -{ - // Constructor. - - MakeTitle("NLTProjection"); - { - TGHorizontalFrame* f = new TGHorizontalFrame(this); - TGLabel* lab = new TGLabel(f, "Type"); - f->AddFrame(lab, new TGLayoutHints(kLHintsLeft|kLHintsBottom, 1, 31, 1, 2)); - fType = new TGComboBox(f); - fType->AddEntry("CFishEye", NLTProjection::PT_CFishEye); - fType->AddEntry("RhoZ", NLTProjection::PT_RhoZ); - TGListBox* lb = fType->GetListBox(); - lb->Resize(lb->GetWidth(), 2*18); - fType->Resize(80, 20); - fType->Connect("Selected(Int_t)", "Reve::NLTProjectorEditor", - this, "DoType(Int_t)"); - f->AddFrame(fType, new TGLayoutHints(kLHintsTop, 1, 1, 2, 4)); - AddFrame(f); - } - - Int_t labelW = 60; - fDistortion = new RGValuator(this, "Distortion:", 90, 0); - fDistortion->SetNELength(5); - fDistortion->SetLabelWidth(labelW); - fDistortion->Build(); - fDistortion->SetLimits(0, 50, 101, TGNumberFormat::kNESRealTwo); - fDistortion->Connect("ValueSet(Double_t)", "Reve::NLTProjectorEditor", - this, "DoDistortion()"); - AddFrame(fDistortion, new TGLayoutHints(kLHintsTop, 1, 1, 1, 0)); - - - fFixedRadius = new RGValuator(this, "FixedR:", 90, 0); - fFixedRadius->SetNELength(5); - fFixedRadius->SetLabelWidth(labelW); - fFixedRadius->Build(); - fFixedRadius->SetLimits(0, 1000, 101, TGNumberFormat::kNESRealOne); - fFixedRadius->SetToolTip("Radius not scaled by distotion."); - fFixedRadius->Connect("ValueSet(Double_t)", "Reve::NLTProjectorEditor", - this, "DoFixedRadius()"); - AddFrame(fFixedRadius, new TGLayoutHints(kLHintsTop, 1, 1, 1, 0)); - - - fCurrentDepth = new RGValuator(this, "CurrentZ:", 90, 0); - fCurrentDepth->SetNELength(5); - fCurrentDepth->SetLabelWidth(labelW); - fCurrentDepth->Build(); - fCurrentDepth->SetLimits(-300, 300, 601, TGNumberFormat::kNESRealOne); - fCurrentDepth->SetToolTip("Z coordinate of incoming projected object."); - fCurrentDepth->Connect("ValueSet(Double_t)", "Reve::NLTProjectorEditor", - this, "DoCurrentDepth()"); - AddFrame(fCurrentDepth, new TGLayoutHints(kLHintsTop, 1, 1, 1, 0)); - - /**************************************************************************/ - MakeTitle("Axis"); - { - TGHorizontalFrame* hf1 = new TGHorizontalFrame(this); - - TGCompositeFrame *labfr = - new TGHorizontalFrame(hf1, 60, 15, kFixedSize); - TGLabel* l = new TGLabel(labfr, "Color"); - labfr->AddFrame(l, new TGLayoutHints(kLHintsLeft|kLHintsBottom)); - hf1->AddFrame(labfr, new TGLayoutHints(kLHintsLeft|kLHintsBottom)); - - - fAxisColor = new TGColorSelect(hf1, 0, -1); - hf1->AddFrame(fAxisColor, new TGLayoutHints(kLHintsLeft, 2, 0, 1, 1)); - fAxisColor->Connect - ("ColorSelected(Pixel_t)", - "Reve::NLTProjectorEditor", this, "DoAxisColor(Pixel_t)"); - - AddFrame(hf1); - } - { - TGHorizontalFrame* f = new TGHorizontalFrame(this); - TGLabel* lab = new TGLabel(f, "StepMode"); - f->AddFrame(lab, new TGLayoutHints(kLHintsLeft|kLHintsBottom, 1, 6, 1, 2)); - fSIMode = new TGComboBox(f, "Position"); - fSIMode->AddEntry("Value", 1); - fSIMode->AddEntry("Position", 0); - fSIMode->GetTextEntry()->SetToolTipText("Set tick-marks on equidistant values/screen position."); - TGListBox* lb = fSIMode->GetListBox(); - lb->Resize(lb->GetWidth(), 2*18); - fSIMode->Resize(80, 20); - fSIMode->Connect("Selected(Int_t)", "Reve::NLTProjectorEditor", - this, "DoSplitInfoMode(Int_t)"); - f->AddFrame(fSIMode, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - AddFrame(f); - } - { - TGHorizontalFrame* f = new TGHorizontalFrame(this); - TGLabel* lab = new TGLabel(f, "SplitLevel"); - f->AddFrame(lab, new TGLayoutHints(kLHintsLeft|kLHintsBottom, 1, 8, 1, 2)); - - fSILevel = new TGNumberEntry(f, 0, 3, -1,TGNumberFormat::kNESInteger, TGNumberFormat::kNEANonNegative, - TGNumberFormat::kNELLimitMinMax, 0, 7); - fSILevel->GetNumberEntry()->SetToolTipText("Number of tick-marks TMath::Power(2, level)."); - fSILevel->Connect("ValueSet(Long_t)", "Reve::NLTProjectorEditor", this, "DoSplitInfoLevel()"); - f->AddFrame(fSILevel, new TGLayoutHints(kLHintsTop, 1, 1, 1, 2)); - AddFrame(f, new TGLayoutHints(kLHintsTop, 0, 0, 0, 3) ); - } - - /**************************************************************************/ - // center tab - fCenterFrame = CreateEditorTabSubFrame("Center"); - - TGCompositeFrame *title1 = new TGCompositeFrame(fCenterFrame, 180, 10, - kHorizontalFrame | - kLHintsExpandX | - kFixedWidth | - kOwnBackground); - title1->AddFrame(new TGLabel(title1, "Distortion Center"), - new TGLayoutHints(kLHintsLeft, 1, 1, 0, 0)); - title1->AddFrame(new TGHorizontal3DLine(title1), - new TGLayoutHints(kLHintsExpandX, 5, 5, 7, 7)); - fCenterFrame->AddFrame(title1, new TGLayoutHints(kLHintsTop, 0, 0, 2, 0)); - - - { - - TGHorizontalFrame* hf1 = new TGHorizontalFrame(fCenterFrame); - - fDrawOrigin = new TGCheckButton(hf1, "DrawOrigin"); - hf1->AddFrame(fDrawOrigin, new TGLayoutHints(kLHintsLeft, 2,1,0,4)); - fDrawOrigin->Connect("Toggled(Bool_t)"," Reve::NLTProjectorEditor", this, "DoDrawOrigin()"); - - - fDrawCenter = new TGCheckButton(hf1, "DrawCenter"); - hf1->AddFrame(fDrawCenter, new TGLayoutHints(kLHintsLeft, 2,1,0,4)); - fDrawCenter->Connect("Toggled(Bool_t)"," Reve::NLTProjectorEditor", this, "DoDrawCenter()"); - - fCenterFrame->AddFrame(hf1, new TGLayoutHints(kLHintsTop, 0,0,0,0)); - - } - - Int_t nel = 8; - fCenterX = new RGValuator(fCenterFrame, "CenterX:", 90, 0); - fCenterX->SetNELength(nel); - fCenterX->SetLabelWidth(labelW); - fCenterX->Build(); - fCenterX->SetLimits(-5, 5, 501, TGNumberFormat::kNESRealThree); - fCenterX->SetToolTip("Origin of the projection."); - fCenterX->Connect("ValueSet(Double_t)", "Reve::NLTProjectorEditor", - this, "DoCenter()"); - fCenterFrame->AddFrame(fCenterX, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - - fCenterY = new RGValuator(fCenterFrame, "CenterY:", 90, 0); - fCenterY->SetNELength(nel); - fCenterY->SetLabelWidth(labelW); - fCenterY->Build(); - fCenterY->SetLimits(-5, 5, 501, TGNumberFormat::kNESRealThree); - fCenterY->SetToolTip("Origin of the projection."); - fCenterY->Connect("ValueSet(Double_t)", "Reve::NLTProjectorEditor", - this, "DoCenter()"); - fCenterFrame->AddFrame(fCenterY, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - - fCenterZ = new RGValuator(fCenterFrame, "CenterZ:", 90, 0); - fCenterZ->SetNELength(nel); - fCenterZ->SetLabelWidth(labelW); - fCenterZ->Build(); - fCenterZ->SetLimits(-25, 25, 501, TGNumberFormat::kNESRealThree); - fCenterZ->SetToolTip("Origin of the projection."); - fCenterZ->Connect("ValueSet(Double_t)", "Reve::NLTProjectorEditor", - this, "DoCenter()"); - fCenterFrame->AddFrame(fCenterZ, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); -} - -//______________________________________________________________________________ -void NLTProjectorEditor::SetModel(TObject* obj) -{ - // Set model object. - - fM = dynamic_cast(obj); - - fAxisColor->SetColor(TColor::Number2Pixel(fM->GetAxisColor()), kFALSE); - fSIMode->Select(fM->GetSplitInfoMode(), kFALSE); - fSILevel->SetNumber(fM->GetSplitInfoLevel()); - - fType->Select(fM->GetProjection()->GetType(), kFALSE); - fDistortion->SetValue(1000.0f * fM->GetProjection()->GetDistortion()); - fFixedRadius->SetValue(fM->GetProjection()->GetFixedRadius()); - fCurrentDepth->SetValue(fM->GetCurrentDepth()); - - fDrawCenter->SetState(fM->GetDrawCenter() ? kButtonDown : kButtonUp); - fDrawOrigin->SetState(fM->GetDrawOrigin() ? kButtonDown : kButtonUp); - fCenterX->SetValue(fM->GetCenter().x); - fCenterY->SetValue(fM->GetCenter().y); - fCenterZ->SetValue(fM->GetCenter().z); -} - -//______________________________________________________________________________ -void NLTProjectorEditor::DoType(Int_t type) -{ - // Slot for setting of projection type. - - fM->SetProjection((NLTProjection::PType_e)type, 0.001f * fDistortion->GetValue()); - fM->ProjectChildren(); - Update(); -} - -//______________________________________________________________________________ -void NLTProjectorEditor::DoDistortion() -{ - // Slot for setting distortion. - - fM->GetProjection()->SetDistortion(0.001f * fDistortion->GetValue()); - fM->UpdateName(); - fM->ProjectChildren(); - Update(); -} - -//______________________________________________________________________________ - void NLTProjectorEditor::DoFixedRadius() -{ - // Slot for setting fixed radius. - - fM->GetProjection()->SetFixedRadius(fFixedRadius->GetValue()); - fM->ProjectChildren(); - Update(); -} - -//______________________________________________________________________________ -void NLTProjectorEditor::DoCurrentDepth() -{ - // Slot for setting current depth. - - fM->SetCurrentDepth(fCurrentDepth->GetValue()); - fM->ProjectChildren(); - Update(); -} - -//______________________________________________________________________________ -void NLTProjectorEditor::DoCenter() -{ - // Slot for setting center of distortion. - - fM->SetCenter(fCenterX->GetValue(), fCenterY->GetValue(), fCenterZ->GetValue()); - Update(); -} - -//______________________________________________________________________________ -void NLTProjectorEditor::DoDrawOrigin() -{ - // Slot for setting draw of origin. - - fM->SetDrawOrigin(fDrawOrigin->IsOn()); - Update(); -} - -//______________________________________________________________________________ -void NLTProjectorEditor::DoDrawCenter() -{ - // Slot for setting draw of center. - - fM->SetDrawCenter(fDrawCenter->IsOn()); - Update(); -} - -//______________________________________________________________________________ -void NLTProjectorEditor::DoSplitInfoMode(Int_t type) -{ - // Slot for setting split info mode. - - fM->SetSplitInfoMode(type); - Update(); -} - -//______________________________________________________________________________ -void NLTProjectorEditor::DoSplitInfoLevel() -{ - // Slot for setting tick-mark density. - - fM->SetSplitInfoLevel((Int_t)fSILevel->GetNumber()); - Update(); -} - -//______________________________________________________________________________ -void NLTProjectorEditor::DoAxisColor(Pixel_t pixel) -{ - // Slot for setting axis color. - - fM->SetAxisColor(Color_t(TColor::GetColor(pixel))); - Update(); -} diff --git a/EVE/Reve/NLTProjectorEditor.h b/EVE/Reve/NLTProjectorEditor.h deleted file mode 100644 index b0c8e165851..00000000000 --- a/EVE/Reve/NLTProjectorEditor.h +++ /dev/null @@ -1,71 +0,0 @@ -// $Header$ - -#ifndef REVE_NLTProjectorEditor_H -#define REVE_NLTProjectorEditor_H - -#include - -class TGComboBox; -class TGCheckButton; -class TGNumberEntry; -class TGColorSelect; - -namespace Reve { - -class NLTProjector; -class RGValuator; - -class NLTProjectorEditor : public TGedFrame -{ -private: - NLTProjectorEditor(const NLTProjectorEditor&); // Not implemented - NLTProjectorEditor& operator=(const NLTProjectorEditor&); // Not implemented - -protected: - NLTProjector *fM; // fModel dynamic-casted to NLTProjectorEditor - - // projection - TGComboBox *fType; - RGValuator *fDistortion; - RGValuator *fFixedRadius; - RGValuator *fCurrentDepth; - - // center - TGVerticalFrame *fCenterFrame; // Parent frame for projection center interface. - TGCheckButton *fDrawCenter; - TGCheckButton *fDrawOrigin; - RGValuator *fCenterX; - RGValuator *fCenterY; - RGValuator *fCenterZ; - - // axis - TGColorSelect *fAxisColor; - TGComboBox *fSIMode; - TGNumberEntry *fSILevel; - -public: - NLTProjectorEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, UInt_t options = kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - virtual ~NLTProjectorEditor(){} - - virtual void SetModel(TObject* obj); - - // Declare callback/slot methods - - void DoSplitInfoMode(Int_t type); - void DoSplitInfoLevel(); - void DoAxisColor(Pixel_t pixel); - - void DoType(Int_t type); - void DoDistortion(); - void DoFixedRadius(); - void DoCurrentDepth(); - void DoDrawCenter(); - void DoDrawOrigin(); - void DoCenter(); - - ClassDef(NLTProjectorEditor, 0); // Editor for NLTProjector. -}; // endclass NLTProjectorEditor - -} - -#endif diff --git a/EVE/Reve/NLTProjectorGL.cxx b/EVE/Reve/NLTProjectorGL.cxx deleted file mode 100644 index f3bd4bb44f3..00000000000 --- a/EVE/Reve/NLTProjectorGL.cxx +++ /dev/null @@ -1,298 +0,0 @@ -// $Header$ - -#include "NLTProjectorGL.h" -#include - -#include -#include -#include -#include - -#include - -using namespace Reve; - -//______________________________________________________________________ -// NLTProjectorGL -// - -ClassImp(NLTProjectorGL) - -NLTProjectorGL::NLTProjectorGL() : - TGLObject(), - - fRange(300), - fLabelSize(0.02), - fLabelOff(0.018), - fTMSize(0.02), - - fM(0), - fText(0) -{ - fDLCache = kFALSE; // Disable display list. - fText = new TGLText(); - fText->SetGLTextFont(40); - fText->SetTextColor(0); -} - -NLTProjectorGL::~NLTProjectorGL() -{} -/**************************************************************************/ -const char* NLTProjectorGL::GetText(Float_t x) const -{ - using namespace TMath; - // TODO: Form could be replaced with own version of printf - if ( Abs(x) > 1000 ) - { - Float_t v = 10*TMath::Nint(x/10.0f); - return Form("%.0f", v); - } - else if( Abs(x) > 100 ) - { - Float_t v = TMath::Nint(x); - return Form("%.0f", v); - } - else if ( Abs(x) > 10 ) - { - return Form("%.1f", x); - } - else if ( Abs(x) > 1 ) - { - return Form("%.2f", x); - } - else - { - return Form("%.3f", x); - } -} - -/**************************************************************************/ -void NLTProjectorGL::SetRange(Float_t pos, Int_t ax) const -{ - using namespace TMath; - Float_t limit = fM->GetProjection()->GetLimit(ax, pos > 0 ? kTRUE: kFALSE); - // printf("NLTProjectorGL::SetRange pos %f range %f \n", pos, limit ); - if ( fM->GetProjection()->GetDistortion() > 0.001 && Abs(pos) > Abs(limit *0.97)) - { - fPos.push_back(limit *0.7); - fVals.push_back(fM->GetProjection()->GetValForScreenPos(ax, fPos.back())); - // printf("bbox value out of limit:: val %f, pos %f\n", limit, fVals.back()); - } - - else - { - fPos.push_back(pos); - fVals.push_back(fM->GetProjection()->GetValForScreenPos(ax, fPos.back())); - } -} - -/**************************************************************************/ - -void NLTProjectorGL::DrawTickMarks(Float_t tm) const -{ - glBegin(GL_LINES); - for( std::list::iterator pi = fPos.begin(); pi!= fPos.end(); pi++) - { - glVertex3f(*pi, 0, 0.); - glVertex3f(*pi, tm, 0.); - } - glEnd(); -} - -/**************************************************************************/ - -void NLTProjectorGL::DrawHInfo() const -{ - Float_t tms = fTMSize*fRange; - DrawTickMarks(-tms); - - glPushMatrix(); - glRotatef(-90, 1, 0, 0); - glTranslatef(0, 0, -tms -fLabelOff*fRange); - const char* txt; - Float_t llx, lly, llz, urx, ury, urz; - std::list::iterator vi = fVals.begin(); - for( std::list::iterator pi = fPos.begin(); pi!= fPos.end(); pi++) - { - txt = GetText(*vi); - fText->BBox(txt, llx, lly, llz, urx, ury, urz); - fText->PaintGLText(*pi -(urx-llx)*fText->GetTextSize()*0.5, 0, 0, txt); - vi++; - } - glPopMatrix(); - - fPos.clear(); fVals.clear(); -} - -/**************************************************************************/ -void NLTProjectorGL::DrawVInfo() const -{ - Float_t tms = fTMSize*fRange; - glRotatef(90, 0, 0, 1); - DrawTickMarks(tms); - glRotatef(-90, 0, 0, 1); - - glPushMatrix(); - glRotatef(-90, 1, 0, 0); - glTranslatef(-fLabelOff*fRange -tms, 0, 0); - const char* txt; - Float_t llx, lly, llz, urx, ury, urz; - std::list::iterator vi = fVals.begin(); - for( std::list::iterator pi = fPos.begin(); pi!= fPos.end(); pi++) - { - txt= GetText(*vi); - fText->BBox(txt, llx, lly, llz, urx, ury, urz); - fText->PaintGLText(-(urx-llx)*fText->GetTextSize(), 0, *pi - (ury - lly)*fText->GetTextSize()*0.5, txt); - vi++; - } - glPopMatrix(); - - fPos.clear(); fVals.clear(); -} - -/**************************************************************************/ -void NLTProjectorGL::SplitInterval(Int_t ax) const -{ - if (fM->GetSplitInfoLevel()) - { - if(fM->GetSplitInfoMode()) - SplitIntervalByVal(fVals.front(), fVals.back(), ax, 0); - else - SplitIntervalByPos(fPos.front(), fPos.back(), ax, 0); - } -} - -/**************************************************************************/ -void NLTProjectorGL::SplitIntervalByPos(Float_t minp, Float_t maxp, Int_t ax, Int_t level) const -{ - Float_t p = (minp+maxp)*0.5; - fPos.push_back(p); - Float_t v = fM->GetProjection()->GetValForScreenPos(ax, p); - fVals.push_back(v); - // printf("level %d position %f value %f\n", level, p,v); - level++; - if(levelGetSplitInfoLevel()) - { - SplitIntervalByPos(minp, p , ax, level); - SplitIntervalByPos(p, maxp, ax, level); - } -} - -/**************************************************************************/ -void NLTProjectorGL::SplitIntervalByVal(Float_t minv, Float_t maxv, Int_t ax, Int_t level) const -{ - Float_t v = (minv+maxv)*0.5; - fVals.push_back(v); - Float_t p = fM->GetProjection()->GetScreenVal(ax, v); - fPos.push_back(p); - //printf("level %d position %f value %f MINMAX val(%f, %f)\n", level, p,v, minv, maxv); - level++; - if(levelGetSplitInfoLevel()) - { - SplitIntervalByVal(minv, v , ax, level); - SplitIntervalByVal(v, maxv, ax, level); - } -} - - -/**************************************************************************/ -void NLTProjectorGL::DirectDraw(TGLRnrCtx & /*rnrCtx*/) const -{ - // printf("NLTProjectorGL::DirectDraw %d\n.", fM->GetMainColor()); - GLboolean lightp; - glGetBooleanv(GL_LIGHTING, &lightp); - if (lightp) glDisable(GL_LIGHTING); - - Float_t* bbox = fM->GetBBox(); - fRange = bbox[1] - bbox[0]; - // printf("bbox %f, %f\n", bbox[0], bbox[1]); - Vector zeroPos; - fM->GetProjection()->ProjectVector(zeroPos); - fText->SetTextSize(fLabelSize*fRange); - fText->SetTextColor(fM->GetAxisColor()); - - { // horizontal - glPushMatrix(); - glTranslatef(0, bbox[2], 0); - // left - SetRange(bbox[0], 0); - fPos.push_back(zeroPos.x); fVals.push_back(0); - SplitInterval(0); - DrawHInfo(); - // right - fPos.push_back(zeroPos.x); fVals.push_back(0); - SetRange(bbox[1], 0); - SplitInterval(0); fVals.pop_front(); fPos.pop_front(); - DrawHInfo(); - glPopMatrix(); - } - { // vertical - glPushMatrix(); - glTranslatef(bbox[0], 0, 0); - // bottom - fPos.push_back(zeroPos.y);fVals.push_back(0); - SetRange(bbox[2], 1); - SplitInterval(1); - DrawVInfo(); - // top - fPos.push_back(zeroPos.y); fVals.push_back(0); - SetRange(bbox[3], 1); - SplitInterval(1);fPos.pop_front(); fVals.pop_front(); - DrawVInfo(); - glPopMatrix(); - } - - // body - glBegin(GL_LINES); - glVertex3f(bbox[0], bbox[2], 0.); - glVertex3f(bbox[1], bbox[2], 0.); - glVertex3f(bbox[0], bbox[2], 0.); - glVertex3f(bbox[0], bbox[3], 0.); - glEnd(); - - Float_t d = 10; - if(fM->GetDrawCenter()) - { - Float_t* c = fM->GetProjection()->GetProjectedCenter(); - glColor3f(1., 0., 0.); - glBegin(GL_LINES); - glVertex3f(c[0] +d, c[1], c[2]); glVertex3f(c[0] - d, c[1] , c[2]); - glVertex3f(c[0] , c[1] +d, c[2]); glVertex3f(c[0] , c[1] -d, c[2]); - glVertex3f(c[0] , c[1], c[2] + d); glVertex3f(c[0] , c[1] , c[2] - d); - glEnd(); - - } - - if(fM->GetDrawOrigin()) - { - Vector zero; - fM->GetProjection()->ProjectVector(zero); - glColor3f(1., 1., 1.); - glBegin(GL_LINES); - glVertex3f(zero[0] +d, zero[1], zero[2]); glVertex3f(zero[0] - d, zero[1] , zero[2]); - glVertex3f(zero[0] , zero[1] +d, zero[2]); glVertex3f(zero[0] , zero[1] -d, zero[2]); - glVertex3f(zero[0] , zero[1], zero[2] + d); glVertex3f(zero[0] , zero[1] , zero[2] - d); - glEnd(); - } - if (lightp) glEnable(GL_LIGHTING); -} - - -/**************************************************************************/ - -Bool_t NLTProjectorGL::SetModel(TObject* obj, const Option_t* /*opt*/) -{ - if(SetModelCheckClass(obj, NLTProjector::Class())) { - fM = dynamic_cast(obj); - return kTRUE; - } - return kFALSE; -} - -/**************************************************************************/ - -void NLTProjectorGL::SetBBox() -{ - // !! This ok if master sub-classed from TAttBBox - SetAxisAlignedBBox(((NLTProjector*)fExternalObj)->AssertBBox()); -} diff --git a/EVE/Reve/NLTProjectorGL.h b/EVE/Reve/NLTProjectorGL.h deleted file mode 100644 index e5a5ffb7b3e..00000000000 --- a/EVE/Reve/NLTProjectorGL.h +++ /dev/null @@ -1,62 +0,0 @@ -// $Header$ - -#ifndef REVE_NLTProjectorGL_H -#define REVE_NLTProjectorGL_H - -#include -#include - -class TGLViewer; -class TGLScene; -class TGLText; - -namespace Reve { -class NLTProjector; -class NLTProjectorGL : public TGLObject -{ -public: - typedef std::list TMList_t; - -private: - NLTProjectorGL(const NLTProjectorGL&); // Not implemented - NLTProjectorGL& operator=(const NLTProjectorGL&); // Not implemented - - mutable TMList_t fPos; - mutable TMList_t fVals; - - mutable Float_t fRange; - Float_t fLabelSize; - Float_t fLabelOff; - Float_t fTMSize; - - void DrawTickMarks(Float_t tms) const; - void DrawHInfo() const; - void DrawVInfo() const; - const char* GetText(Float_t) const; - - void SplitInterval(Int_t axis) const; - void SplitIntervalByPos(Float_t min, Float_t max, Int_t axis, Int_t level)const; - void SplitIntervalByVal(Float_t min, Float_t max, Int_t axis, Int_t level)const; - - void SetRange(Float_t val, Int_t axis) const; - -protected: - NLTProjector* fM; // fModel dynamic-casted to NLTProjector - TGLText* fText; - - virtual void DirectDraw(TGLRnrCtx & rnrCtx) const; - -public: - NLTProjectorGL(); - virtual ~NLTProjectorGL(); - - virtual Bool_t SetModel(TObject* obj, const Option_t* opt=0); - virtual void SetBBox(); - Bool_t IgnoreSizeForOfInterest() const { return kTRUE;} - - ClassDef(NLTProjectorGL, 0); -}; // endclass NLTProjectorGL - -} - -#endif diff --git a/EVE/Reve/NLTTrack.cxx b/EVE/Reve/NLTTrack.cxx deleted file mode 100644 index 2ae6aee1f3f..00000000000 --- a/EVE/Reve/NLTTrack.cxx +++ /dev/null @@ -1,239 +0,0 @@ -// $Header$ - -#include "NLTTrack.h" -#include -#include - -using namespace Reve; - -//______________________________________________________________________________ -// NLTTrack -// - -ClassImp(NLTTrack) - -//______________________________________________________________________________ -NLTTrack::NLTTrack() : - Track (), - fOrigPnts(0), - fProjection(0) -{ - // Default constructor. -} - -//______________________________________________________________________________ -NLTTrack::~NLTTrack() -{ - // Destructor. Noop. -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void NLTTrack::SetProjection(NLTProjector* proj, NLTProjectable* model) -{ - NLTProjected::SetProjection(proj, model); - Track* origTrack = dynamic_cast(fProjectable); - - SetTrackParams(*origTrack); - SetPathMarks (*origTrack); -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void NLTTrack::UpdateProjection() -{ - fProjection = fProjector->GetProjection(); - MakeTrack(kFALSE); // NLTProjector makes recursive calls -} - -//______________________________________________________________________________ -void NLTTrack::GetBreakPoint(Int_t idx, Bool_t back, - Float_t& x, Float_t& y, Float_t& z) -{ - Vector vL = fOrigPnts[idx]; - Vector vR = fOrigPnts[idx+1]; - Vector vM, vLP, vMP; - while((vL-vR).Mag() > 0.01) - { - vM.Mult(vL+vR, 0.5f); - vLP.Set(vL); fProjection->ProjectPoint(vLP.x, vLP.y, vLP.z); - vMP.Set(vM); fProjection->ProjectPoint(vMP.x, vMP.y, vMP.z); - if(fProjection->AcceptSegment(vLP, vMP, 0.0f)) - { - vL.Set(vM); - } - else - { - vR.Set(vM); - } - //printf("new interval Mag %f (%f, %f, %f)(%f, %f, %f) \n",(vL-vR).Mag(), vL.x, vL.y, vL.z, vR.x, vR.y, vR.z); - } - - if(back) - { - x = vL.x; y = vL.y; z = vL.z; - } - else - { - x = vR.x; y = vR.y; z = vR.z; - } - fProjection->ProjectPoint(x, y, z); - // printf("NLTTrack::GetBreakPoint %d (%f, %f, %f) \n", idx, x, y, z); -} - -//______________________________________________________________________________ -Int_t NLTTrack::GetBreakPointIdx(Int_t start) -{ - // Findex index of the last point that lies within the same - // segment of projected space. - // For example, rho-z projection separates upper and lower hemisphere - // and tracks break into two lines when crossing the y=0 plane. - - Int_t val = fLastPoint; - - Vector v1, v2; - if (Size() > 1) - { - Int_t i = start; - while(i < fLastPoint) - { - GetPoint(i, v1.x, v1.y, v1.z); - GetPoint(i+1, v2.x, v2.y, v2.z); - if(fProjection->AcceptSegment(v1, v2, fRnrStyle->fDelta) == kFALSE) - { - val = i; - break; - } - i++; - } - } - // printf("BreakPoint IDX start:%d, BREAK %d, total:%d \n", start, val, Size()); - return val; -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void NLTTrack::MakeTrack(Bool_t recurse) -{ - // Calculate the points of the track for drawing. - // Call base-class, project, find break-points and insert points - // required for full representation. - - Track::MakeTrack(recurse); - - fBreakPoints.clear(); - if(Size() == 0) return; // All points can be outside of MaxR / MaxZ limits. - - // Project points, store originals (needed for break-points). - Float_t *p = GetP(); - fOrigPnts = new Vector[Size()]; - for(Int_t i = 0; i < Size(); ++i, p+=3) - { - fOrigPnts[i].Set(p); - fProjection->ProjectPoint(p[0], p[1], p[2]); - p[2] = fDepth; - } - - Float_t x, y, z; - std::vector vvec; - Int_t bL = 0, bR = GetBreakPointIdx(0); - while (1) - { - for(Int_t i=bL; i<=bR; i++) - { - GetPoint(i, x, y, z); - vvec.push_back(Vector(x, y, z)); - } - if (bR == fLastPoint) - break; - - GetBreakPoint(bR, kTRUE, x, y, z); vvec.push_back(Vector(x, y, z)); - fBreakPoints.push_back(vvec.size()); - GetBreakPoint(bR, kFALSE, x, y, z); vvec.push_back(Vector(x, y, z)); - - bL = bR + 1; - bR = GetBreakPointIdx(bL); - } - fBreakPoints.push_back(vvec.size()); // Mark the track-end for drawing. - - Reset(vvec.size()); - for (std::vector::iterator i=vvec.begin(); i!=vvec.end(); ++i) - SetNextPoint((*i).x, (*i).y, (*i).z); - delete [] fOrigPnts; -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void NLTTrack::PrintLineSegments() -{ - printf("%s LineSegments:\n", GetName()); - Int_t start = 0; - Int_t segment = 0; - Vector S; - Vector E; - for (std::vector::iterator bpi = fBreakPoints.begin(); - bpi != fBreakPoints.end(); ++bpi) - { - Int_t size = *bpi - start; - - GetPoint(start, S.x, S.y, S.z); - GetPoint((*bpi)-1, E.x, E.y, E.z); - printf("seg %d size %d start %d ::(%f, %f, %f) (%f, %f, %f)\n", - segment, size, start, S.x, S.y, S.z, E.x, E.y, E.z); - start += size; - segment ++; - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void NLTTrack::CtrlClicked(Reve::Track* /*track*/) -{ - Track* t = dynamic_cast(fProjectable); - if (t) - t->CtrlClicked(t); -} - - -/******************************************************************************/ -/******************************************************************************/ - - -//______________________________________________________________________________ -// NLTTrackList -// - -ClassImp(NLTTrackList) - -//______________________________________________________________________________ -NLTTrackList::NLTTrackList() : - TrackList (), - NLTProjected () -{ - // Default constructor. -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void NLTTrackList::SetProjection(NLTProjector* proj, NLTProjectable* model) -{ - NLTProjected::SetProjection(proj, model); - - TrackList& tl = * dynamic_cast(model); - SetLineColor(tl.GetLineColor()); - SetLineStyle(tl.GetLineStyle()); - SetLineWidth(tl.GetLineWidth()); - SetMarkerColor(tl.GetMarkerColor()); - SetMarkerStyle(tl.GetMarkerStyle()); - SetMarkerSize(tl.GetMarkerSize()); - SetRnrLine(tl.GetRnrLine()); - SetRnrPoints(tl.GetRnrPoints()); - - SetRnrStyle(tl.GetRnrStyle()); -} diff --git a/EVE/Reve/NLTTrack.h b/EVE/Reve/NLTTrack.h deleted file mode 100644 index 70177bc9962..00000000000 --- a/EVE/Reve/NLTTrack.h +++ /dev/null @@ -1,70 +0,0 @@ -// $Header$ - -#ifndef REVE_NLTTrack_H -#define REVE_NLTTrack_H - -#include -#include - -namespace Reve { - -class NLTProjection; - -class NLTTrack : public Track, - public NLTProjected -{ - friend class NLTTrackGL; - -private: - NLTTrack(const NLTTrack&); // Not implemented - NLTTrack& operator=(const NLTTrack&); // Not implemented - - Vector* fOrigPnts; - Int_t GetBreakPointIdx(Int_t start); - void GetBreakPoint(Int_t N, Bool_t back, Float_t& x, Float_t& y, Float_t& z); - -protected: - std::vector fBreakPoints; - NLTProjection *fProjection; - -public: - NLTTrack(); - virtual ~NLTTrack(); - - virtual void SetProjection(NLTProjector* proj, NLTProjectable* model); - - virtual void UpdateProjection(); - virtual void MakeTrack(Bool_t recurse=kTRUE); - - void PrintLineSegments(); - - virtual void CtrlClicked(Reve::Track*); // marked as signal in Track - - ClassDef(NLTTrack, 1); -}; // endclass NLTTrack - - -/**************************************************************************/ -// TrackRnrStyle -/**************************************************************************/ - -class NLTTrackList : public TrackList, - public NLTProjected -{ -private: - NLTTrackList(const NLTTrackList&); // Not implemented - NLTTrackList& operator=(const NLTTrackList&); // Not implemented - -public: - NLTTrackList(); - virtual ~NLTTrackList() {} - - virtual void SetProjection(NLTProjector* proj, NLTProjectable* model); - virtual void UpdateProjection(){}; - - ClassDef(NLTTrackList, 1); -};// endclass NLTTrackList - -} - -#endif diff --git a/EVE/Reve/NLTTrackGL.cxx b/EVE/Reve/NLTTrackGL.cxx deleted file mode 100644 index 8d44dfb4aba..00000000000 --- a/EVE/Reve/NLTTrackGL.cxx +++ /dev/null @@ -1,102 +0,0 @@ -// $Header$ - -#include "NLTTrackGL.h" -#include -#include -#include - -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// NLTTrackGL -// - -ClassImp(NLTTrackGL) - -NLTTrackGL::NLTTrackGL() : TrackGL(), fM(0) -{ - // fDLCache = kFALSE; // Disable display list. -} - -NLTTrackGL::~NLTTrackGL() -{} - -/**************************************************************************/ - -Bool_t NLTTrackGL::SetModel(TObject* obj, const Option_t* /*opt*/) -{ - if(TrackGL::SetModel(obj) == kFALSE) return kFALSE; - if(SetModelCheckClass(obj, NLTTrack::Class())) { - fM = dynamic_cast(obj); - return kTRUE; - } - return kFALSE; -} - -/**************************************************************************/ - -void NLTTrackGL::DirectDraw(TGLRnrCtx & rnrCtx) const -{ - // printf("NLTTrackGL::DirectDraw Style %d, LOD %d\n", flags.Style(), flags.LOD()); - if (rnrCtx.DrawPass() == TGLRnrCtx::kPassOutlineLine || fM->Size() == 0) - return; - - // lines - Int_t start = 0; - Float_t* p = fM->GetP(); - for (std::vector::iterator bpi = fM->fBreakPoints.begin(); - bpi != fM->fBreakPoints.end(); ++bpi) - { - Int_t size = *bpi - start; - if (fM->fRnrLine) GLUtilNS::RenderLine(*fM, p, size); - if (fM->fRnrPoints) GLUtilNS::RenderPolyMarkers(*fM, p, size); - p += 3*size; - start += size; - } - - // path-marks - std::vector& pm = fM->fPathMarks; - TrackRnrStyle& RS = *fM->GetRnrStyle(); - if(pm.size()) - { - Float_t* pnts = new Float_t[3*pm.size()]; // maximum - Int_t N = 0; - Bool_t accept; - for(std::vector::iterator i=pm.begin(); i!=pm.end(); ++i) - { - accept = kFALSE; - switch((*i)->type) - { - case(PathMark::Daughter): - if(RS.fRnrDaughters) accept = kTRUE; - break; - case(PathMark::Reference): - if(RS.fRnrReferences) accept = kTRUE; - break; - case(PathMark::Decay): - if(RS.fRnrDecay) accept = kTRUE; - break; - } - if(accept) - { - if((TMath::Abs((*i)->V.z) < RS.fMaxZ) && ((*i)->V.Perp() < RS.fMaxR)) - { - pnts[3*N ] =(*i)->V.x; - pnts[3*N+1] =(*i)->V.y; - pnts[3*N+2] =(*i)->V.z; - fM->fProjection->ProjectPoint(pnts[3*N ], pnts[3*N+1], pnts[3*N+2]); - N++; - } - } - } - GLUtilNS::RenderPolyMarkers(RS.fPMAtt, pnts, N); - delete [] pnts; - } - - // fist vertex - if(RS.fRnrFV && fTrack->GetLastPoint()) - GLUtilNS::RenderPolyMarkers(RS.fFVAtt, fTrack->GetP(), 1); -} diff --git a/EVE/Reve/NLTTrackGL.h b/EVE/Reve/NLTTrackGL.h deleted file mode 100644 index ae4d359b0f1..00000000000 --- a/EVE/Reve/NLTTrackGL.h +++ /dev/null @@ -1,37 +0,0 @@ -// $Header$ - -#ifndef REVE_NLTTrackGL_H -#define REVE_NLTTrackGL_H - -#include - -class TGLViewer; -class TGLScene; - -namespace Reve { - -class NLTTrack; - -class NLTTrackGL : public TrackGL -{ -private: - NLTTrackGL(const NLTTrackGL&); // Not implemented - NLTTrackGL& operator=(const NLTTrackGL&); // Not implemented - -protected: - NLTTrack* fM; // fModel dynamic-casted to NLTTrackGL - - virtual void DirectDraw(TGLRnrCtx & rnrCtx) const; - -public: - NLTTrackGL(); - virtual ~NLTTrackGL(); - - virtual Bool_t SetModel(TObject* obj, const Option_t* opt=0); - - ClassDef(NLTTrackGL, 0); -}; // endclass NLTTrackGL - -} - -#endif diff --git a/EVE/Reve/PODs.cxx b/EVE/Reve/PODs.cxx deleted file mode 100644 index 9c1301b15ba..00000000000 --- a/EVE/Reve/PODs.cxx +++ /dev/null @@ -1,76 +0,0 @@ -// $Header$ - -#include - -#include "PODs.h" - -using namespace Reve; - -void Reve::DisablePODTObjectStreamers() -{ - // Vector is not TObject - - // MCTrack derives from TParticle - TParticle::Class()->IgnoreTObjectStreamer(true); - - Hit::Class()->IgnoreTObjectStreamer(true); - Cluster::Class()->IgnoreTObjectStreamer(true); - - RecTrack::Class()->IgnoreTObjectStreamer(true); - // RecKink derives from RecTrack - - RecV0::Class()->IgnoreTObjectStreamer(true); - - GenInfo::Class()->IgnoreTObjectStreamer(true); -} - -//______________________________________________________________________ -// Vector -// - -ClassImp(Reve::Vector) - -Float_t Vector::Eta() const -{ - Float_t cosTheta = CosTheta(); - if (cosTheta*cosTheta < 1) return -0.5* TMath::Log( (1.0-cosTheta)/(1.0+cosTheta) ); - Warning("Eta","transverse momentum = 0! return +/- 10e10"); - return (z >= 0) ? 10e10 : -10e10; -} - -Vector Vector::operator + (const Vector & b) -{ - return Vector(x + b.x, y + b.y, z + b.z); -} - -Vector Vector::operator - (const Vector & b) -{ - return Vector(x - b.x, y - b.y, z - b.z); -} - -Vector Vector::operator * (Float_t a) -{ - return Vector(a*x, a*y, a*z); -} -/**************************************************************************/ -/**************************************************************************/ - -//______________________________________________________________________ -// PathMark -// - -ClassImp(Reve::PathMark) - -const char* PathMark::type_name() -{ - switch (type) - { - case Daughter: return "Daughter"; - case Reference: return "Reference"; - case Decay: return "Decay"; - default: return "Unknown"; - } -} - -//ClassImp(Hit) -//ClassImp(RecTrack) diff --git a/EVE/Reve/PODs.h b/EVE/Reve/PODs.h deleted file mode 100644 index b5479799cf8..00000000000 --- a/EVE/Reve/PODs.h +++ /dev/null @@ -1,355 +0,0 @@ -// $Header$ - -#ifndef REVE_PODs_H -#define REVE_PODs_H - -#include -#include - -#include - -namespace Reve { - -/**************************************************************************/ -// PODs.h -/**************************************************************************/ - -// Basic structures for Reve. Design criteria: -// -// * provide basic cross-referencing functionality; -// -// * small memory/disk footprint (floats / count on compression in -// split mode); -// -// * simple usage from tree selections; -// -// * placement in TClonesArray (composites are TObject derived); -// -// * minimal member-naming (impossible to make everybody happy). - -void DisablePODTObjectStreamers(); - -/**************************************************************************/ -// Vector -/**************************************************************************/ - -// Minimal Float_t copy of TVector3. -// Used to represent points and momenta. - -class Vector -{ -public: - Float_t x, y, z; - - Vector() : x(0), y(0), z(0) {} - Vector(Float_t _x, Float_t _y, Float_t _z) : x(_x), y(_y), z(_z) {} - virtual ~Vector() {} - - Vector operator + (const Vector &); - Vector operator - (const Vector &); - Vector operator * (Float_t a); - - Float_t* c_vec() { return &x; } - Float_t& operator [] (Int_t indx); - Float_t operator [] (Int_t indx) const; - - void Set(Float_t* v) { x=v[0]; y=v[1]; z=v[2]; } - void Set(Double_t* v) { x=v[0]; y=v[1]; z=v[2]; } - void Set(Float_t _x, Float_t _y, Float_t _z) { x=_x; y=_y; z=_z; } - void Set(Double_t _x, Double_t _y, Double_t _z) { x=_x; y=_y; z=_z; } - void Set(const TVector3& v) { x=v.x(); y=v.y(); z=v.z(); } - void Set(const Vector& v) { x=v.x; y=v.y; z=v.z; } - - Float_t Phi() const; - Float_t Theta() const; - Float_t CosTheta() const; - Float_t Eta() const; - - Float_t Mag() const { return TMath::Sqrt(x*x+y*y+z*z);} - Float_t Mag2() const { return x*x+y*y+z*z;} - - Float_t Perp() const { return TMath::Sqrt(x*x+y*y);} - Float_t Perp2() const { return x*x+y*y;} - Float_t R() const { return Perp(); } - - Float_t Distance(const Vector& v) const; - Float_t SquareDistance(const Vector& v) const; - Float_t Dot(const Vector&a) const; - - Vector& Mult(const Vector&a, Float_t af) { x = a.x*af; y = a.y*af; z = a.z*af; return *this; } - - - ClassDef(Vector, 1); // VSD float three-vector. -}; - -inline Float_t Vector::Phi() const -{ return x == 0.0 && y == 0.0 ? 0.0 : TMath::ATan2(y,x); } - -inline Float_t Vector::Theta() const -{ return x == 0.0 && y == 0.0 && z == 0.0 ? 0.0 : TMath::ATan2(Perp(),z); } - -inline Float_t Vector::CosTheta() const -{ Float_t ptot = Mag(); return ptot == 0.0 ? 1.0 : z/ptot; } - -inline Float_t Vector::Distance( const Vector& b) const -{ - return TMath::Sqrt((x - b.x)*(x - b.x) + (y - b.y)*(y - b.y) + (z - b.z)*(z - b.z)); -} -inline Float_t Vector::SquareDistance(const Vector& b) const -{ - return ((x - b.x)*(x - b.x) + (y - b.y)*(y - b.y) + (z - b.z)*(z - b.z)); -} - -inline Float_t Vector::Dot(const Vector& a) const -{ - return a.x*x + a.y*y + a.z*z; -} - -inline Float_t& Vector::operator [] (Int_t idx) -{ return (&x)[idx]; } - -inline Float_t Vector::operator [] (Int_t idx) const -{ return (&x)[idx]; } - -/**************************************************************************/ -// PathMark -/**************************************************************************/ - -class PathMark -{ - public: - enum Type_e { Reference, Daughter, Decay }; - - Vector V; // vertex - Vector P; // momentum - Float_t time; // time - Type_e type; // mark-type - - PathMark(Type_e t=Reference) : V(), P(), time(0), type(t) {} - virtual ~PathMark() {} - - const char* type_name(); - - ClassDef(PathMark, 1); // VSD special-point on track. -}; - -/**************************************************************************/ -// MCTrack -/**************************************************************************/ - -class MCTrack : public TParticle // ?? Copy stuff over ?? -{ -public: - Int_t label; // Label of the track - Int_t index; // Index of the track (in some source array) - Int_t eva_label; // Label of primary particle - - Bool_t decayed; // True if decayed during tracking. - // ?? Perhaps end-of-tracking point/momentum would be better. - Float_t t_decay; // Decay time - Vector V_decay; // Decay vertex - Vector P_decay; // Decay momentum - - MCTrack() : label(-1), index(-1), eva_label(-1), - decayed(false), t_decay(0), V_decay(), P_decay() {} - virtual ~MCTrack() {} - - MCTrack& operator=(const TParticle& p) - { *((TParticle*)this) = p; return *this; } - - void ResetPdgCode() { fPdgCode = 0; } - - ClassDef(MCTrack, 1); // VSD Monte Carlo track. -}; - - -/**************************************************************************/ -// Hit -/**************************************************************************/ - -// Representation of a hit. - -// Members det_id (and subdet_id) serve for cross-referencing into -// geometry. Hits should be stored in det_id (+some label ordering) in -// order to maximize branch compression. - - -class Hit : public TObject -{ -public: - UShort_t det_id; // Custom detector id - UShort_t subdet_id; // Custom sub-detector id - Int_t label; // Label of particle that produced the hit - Int_t eva_label; // Label of primary particle, ancestor of label - Vector V; // Hit position - - // Float_t charge; Probably specific. - - Hit() : det_id(0), subdet_id(0), label(0), eva_label(0), V() {} - virtual ~Hit() {} - - ClassDef(Hit, 1); // VSD Monte Carlo hit. -}; - - -/**************************************************************************/ -// Cluster -/**************************************************************************/ - -// Base class for reconstructed clusters - -// ?? Should Hit and cluster have common base? No. - -class Cluster : public TObject -{ -public: - UShort_t det_id; // Custom detector id - UShort_t subdet_id; // Custom sub-detector id - Int_t label[3]; // Labels of particles that contributed hits - // ?? Should include reconstructed track using it? Rather not, separate. - - Vector V; // Vertex - // Vector W; // Cluster widths - // ?? Coord system? Special variables Wz, Wy? - - Cluster() : det_id(0), subdet_id(0), V() { label[0] = label[1] = label [2] = 0; } - virtual ~Cluster() {} - - ClassDef(Cluster, 1); // VSD reconstructed cluster. -}; - - -/**************************************************************************/ -// RecTrack -/**************************************************************************/ - -class RecTrack : public TObject -{ -public: - Int_t label; // Label of the track - Int_t index; // Index of the track (in some source array) - Int_t status; // Status as exported from reconstruction - Int_t sign; // Charge of the track - Vector V; // Start vertex from reconstruction - Vector P; // Reconstructed momentum at start vertex - Float_t beta; - - // PID data missing - - RecTrack() : label(-1), index(-1), status(0), sign(0), V(), P(), beta(0) {} - virtual ~RecTrack() {} - - Float_t Pt() { return P.Perp(); } - - ClassDef(RecTrack, 1); // VSD reconstructed track. -}; - -// Another class with specified points/clusters - - -/**************************************************************************/ -// RecKink -/**************************************************************************/ - -class RecKink : public RecTrack -{ -public: - Int_t label_sec; // Label of the secondary track - Vector V_end; // End vertex: last point on the primary track - Vector V_kink; // Kink vertex: reconstructed position of the kink - Vector P_sec; // Momentum of secondary track - - RecKink() : RecTrack(), label_sec(0), V_end(), V_kink(), P_sec() {} - virtual ~RecKink() {} - - ClassDef(RecKink, 1); // VSD reconstructed track. -}; - - -/**************************************************************************/ -// RecV0 -/**************************************************************************/ - -class RecV0 : public TObject -{ -public: - Int_t status; - - Vector V_neg; // Vertex of negative track - Vector P_neg; // Momentum of negative track - Vector V_pos; // Vertex of positive track - Vector P_pos; // Momentum of positive track - - Vector V_ca; // Point of closest approach - Vector V0_birth; // Reconstucted birth point of neutral particle - - // ? Data from simulation. - Int_t label; // Neutral mother label read from kinematics - Int_t pdg; // PDG code of mother - Int_t d_label[2]; // Daughter labels ?? Rec labels present anyway. - - RecV0() : status(), V_neg(), P_neg(), V_pos(), P_pos(), - V_ca(), V0_birth(), label(0), pdg(0) - { d_label[0] = d_label[1] = 0; } - virtual ~RecV0() {} - - ClassDef(RecV0, 1); // VSD reconstructed V0. -}; - -/**************************************************************************/ -/**************************************************************************/ - -// Missing primary vertex. - -// Missing GenInfo, RecInfo. - -class GenInfo : public TObject -{ -public: - Bool_t is_rec; // is reconstructed - Bool_t has_V0; - Bool_t has_kink; - Int_t label; - Int_t n_hits; - Int_t n_clus; - - GenInfo() : is_rec(false), has_V0(false), has_kink(false), - label(0), n_hits(0), n_clus(0) {} - virtual ~GenInfo() {} - - ClassDef(GenInfo, 1); // VSD cross-reference of sim/rec data per particle. -}; - -/**************************************************************************/ -/**************************************************************************/ - -// This whole construction is somewhat doubtable. It requires -// shameless copying of experiment data. What is good about this -// scheme: -// -// 1) Filters can be applied at copy time so that only part of the -// data is copied over. -// -// 2) Once the data is extracted it can be used without experiment -// software. Thus, external service can provide this data and local -// client can be really thin. -// -// 3) Some pretty advanced visualization schemes/selections can be -// implemented in a general framework by providing data extractors -// only. This is also good for PR or VIP displays. -// -// 4) These classes can be extended by particular implementations. The -// container classes will use TClonesArray with user-specified element -// class. - -// The common behaviour could be implemented entirely without usage of -// a common base classes, by just specifying names of members that -// retrieve specific data. This is fine as long as one only uses tree -// selections but becomes painful for extraction of data into local -// structures (could a) use interpreter but this is an overkill and -// would cause serious trouble for multi-threaded environment; b) use -// member offsets and data-types from the dictionary). - -} - -#endif diff --git a/EVE/Reve/Pad.cxx b/EVE/Reve/Pad.cxx deleted file mode 100644 index 86241b5df0e..00000000000 --- a/EVE/Reve/Pad.cxx +++ /dev/null @@ -1,30 +0,0 @@ -// $Header$ - -#include - -#include - -//______________________________________________________________________ -// Pad -// -// This was intended as a TPad wrapper to allow smart updates of -// groups of pads. Uses THashList instead of TList for faster removal -// of objects from the pad. - -using namespace Reve; - -ClassImp(Pad) - -Pad::Pad() -{ - fPrimitives = new THashList; -} - -Pad::Pad(const char *name, const char *title, Double_t xlow, - Double_t ylow, Double_t xup, Double_t yup, - Color_t color, Short_t bordersize, Short_t bordermode) - : TPad(name,title,xlow,ylow,xup,yup,color,bordersize,bordermode) -{ - delete fPrimitives; - fPrimitives = new THashList; -} diff --git a/EVE/Reve/Pad.h b/EVE/Reve/Pad.h deleted file mode 100644 index 0ce36a38fd6..00000000000 --- a/EVE/Reve/Pad.h +++ /dev/null @@ -1,31 +0,0 @@ -// $Header$ - -#ifndef REVE_Pad_H -#define REVE_Pad_H - -#include - -namespace Reve { - -class Pad : public TPad -{ -public: - Pad(); - Pad(const char* name, const char* title, - Double_t xlow, Double_t ylow, Double_t xup, Double_t yup, - Color_t color = -1, Short_t bordersize = -1, Short_t bordermode = -2); - virtual ~Pad() {} - - virtual Bool_t IsBatch() const { return kTRUE; } - - virtual void Update() { PaintModified(); } - - virtual TVirtualViewer3D *GetViewer3D(Option_t * /*type*/ = "") - { return fViewer3D; } - - ClassDef(Pad, 1); // Internal Reve pad (sub-class of TPad). -}; - -} - -#endif diff --git a/EVE/Reve/Plex.cxx b/EVE/Reve/Plex.cxx deleted file mode 100644 index 1fdfa60c5b5..00000000000 --- a/EVE/Reve/Plex.cxx +++ /dev/null @@ -1,86 +0,0 @@ -// $Header$ - -#include "Plex.h" - -using namespace Reve; - -//______________________________________________________________________ -// Plex -// -// A group of containers with chunked memory allocation. -// - - -//______________________________________________________________________ -// VoidCPlex -// -// Non-structured (Void) Complete Plex. -// Allocation chunk can accommodate fN atoms of byte-size fS each. -// The chunks themselves are TArrayCs and are stored in a std::vector. -// Holes in the structure are not supported, neither is removal of atoms. -// The structure can be Refit() to occupy a single contiguous array. -// - -void VoidCPlex::ReleaseChunks() -{ - for (Int_t i=0; ifArray; - for (Int_t i=0; ifArray, size); - pos += size; - } - ReleaseChunks(); - fN = fCapacity = fSize; - fVecSize = 1; - fChunks.push_back(one); -} - -/**************************************************************************/ - -Char_t* VoidCPlex::NewChunk() -{ - fChunks.push_back(new TArrayC(fS*fN)); - ++fVecSize; - fCapacity += fN; - return fChunks.back()->fArray; -} - -/**************************************************************************/ -/**************************************************************************/ diff --git a/EVE/Reve/Plex.h b/EVE/Reve/Plex.h deleted file mode 100644 index 9de25b87a39..00000000000 --- a/EVE/Reve/Plex.h +++ /dev/null @@ -1,141 +0,0 @@ -// $Header$ - -#ifndef REVE_PLEX_H -#define REVE_PLEX_H - -#include - -#include -#include - -#include - -namespace Reve { - -/**************************************************************************/ -// VoidCPlex -/**************************************************************************/ - -class VoidCPlex -{ -private: - VoidCPlex(const VoidCPlex&); // Not implemented - VoidCPlex& operator=(const VoidCPlex&); // Not implemented - -protected: - Int_t fS; // Size of atom - Int_t fN; // Number of atoms in a chunk - - Int_t fSize; // Size of container, number of atoms - Int_t fVecSize; // Number of allocated chunks - Int_t fCapacity; // Available capacity within the chunks - - std::vector fChunks; // Memory blocks - - void ReleaseChunks(); - -public: - VoidCPlex(); - VoidCPlex(Int_t atom_size, Int_t chunk_size); - virtual ~VoidCPlex(); - - void Reset(Int_t atom_size, Int_t chunk_size); - void Refit(); - - Int_t S() const { return fS; } - Int_t N() const { return fN; } - - Int_t Size() const { return fSize; } - Int_t VecSize() const { return fVecSize; } - Int_t Capacity() const { return fCapacity; } - - Char_t* Atom(Int_t idx) const { return fChunks[idx/fN]->fArray + idx%fN*fS; } - Char_t* Chunk(Int_t chk) const { return fChunks[chk]->fArray; } - Int_t NAtoms(Int_t chk) const { return (chk < fVecSize-1) ? fN : (fSize-1)%fN + 1; } - - Char_t* NewAtom(); - Char_t* NewChunk(); - - - // Iterators - - struct iterator - { - VoidCPlex *fPlex; - Char_t *fCurrent; - Int_t fAtomIndex; - Int_t fNextChunk; - Int_t fAtomsToGo; - - iterator(VoidCPlex* p) : - fPlex(p), fCurrent(0), fAtomIndex(-1), fNextChunk(0), fAtomsToGo(0) {} - iterator(VoidCPlex& p) : - fPlex(&p), fCurrent(0), fAtomIndex(-1), fNextChunk(0), fAtomsToGo(0) {} - - Bool_t next(); - void reset() { fCurrent = 0; fNextChunk = fAtomsToGo = 0; } - - Char_t* operator()() { return fCurrent; } - Char_t* operator*() { return fCurrent; } - Int_t index() { return fAtomIndex; } - }; - - ClassDef(VoidCPlex, 1); // Vector-like container with chunked memory allocation. -}; - - -/******************************************************************************/ - -inline Char_t* VoidCPlex::NewAtom() -{ - Char_t *a = (fSize >= fCapacity) ? NewChunk() : Atom(fSize); - ++fSize; - return a; -} - -inline Bool_t VoidCPlex::iterator::next() -{ - if (fAtomsToGo <= 0) { - if (fNextChunk < fPlex->fVecSize) { - fCurrent = fPlex->Chunk(fNextChunk); - fAtomsToGo = fPlex->NAtoms(fNextChunk); - ++fNextChunk; - } else { - return kFALSE; - } - } else { - fCurrent += fPlex->fS; - } - ++fAtomIndex; - --fAtomsToGo; - return kTRUE; -} - - -/**************************************************************************/ -// Templated some-class CPlex -/**************************************************************************/ - -template -class CPlex : public VoidCPlex -{ -private: - CPlex(const CPlex&); // Not implemented - CPlex& operator=(const CPlex&); // Not implemented - -public: - CPlex() : VoidCPlex() {} - CPlex(Int_t chunk_size) : VoidCPlex(sizeof(T), chunk_size) {} - virtual ~CPlex() {} - - void Reset(Int_t chunk_size) { Reset(sizeof(T), chunk_size); } - - T* At(Int_t idx) { return reinterpret_cast(Atom(idx)); } - T& Ref(Int_t idx) { return *At(idx); } - - ClassDef(CPlex, 1); // Templated class for specific atom classes (given as template argument). -}; // endclass CPlex - -} - -#endif diff --git a/EVE/Reve/PointSet.cxx b/EVE/Reve/PointSet.cxx deleted file mode 100644 index 0cc32cac4e0..00000000000 --- a/EVE/Reve/PointSet.cxx +++ /dev/null @@ -1,614 +0,0 @@ -// $Header$ - -#include "PointSet.h" - -#include -#include - -#include -#include -#include - -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// PointSet -// -// PointSet is a render-element holding a collection of 3D points with -// optional per-point TRef and an arbitrary number of integer ids (to -// be used for signal, volume-id, track-id, etc). -// -// 3D point representation is implemented in base-class TPolyMarker3D. -// Per-point TRef is implemented in base-class TPointSet3D. -// -// By using the TPointSelector the points and integer ids can be -// filled directly from a TTree holding the source data. -// Setting of per-point TRef's is not supported. -// -// PointSet is a NLTProjectable: it can be projected by using the -// NLTProjector class. - -ClassImp(PointSet) - -//______________________________________________________________________________ -PointSet::PointSet(Int_t n_points, TreeVarType_e tv_type) : - RenderElement(fMarkerColor), - TPointSet3D(n_points), - TPointSelectorConsumer(tv_type), - - fTitle (), - fIntIds (0), - fIntIdsPerPoint (0) -{ - // Constructor. - - fMarkerStyle = 20; -} - -//______________________________________________________________________________ -PointSet::PointSet(const Text_t* name, Int_t n_points, TreeVarType_e tv_type) : - RenderElement(fMarkerColor), - TPointSet3D(n_points), - TPointSelectorConsumer(tv_type), - TQObject(), - - fTitle (), - fIntIds (0), - fIntIdsPerPoint (0) -{ - // Constructor. - - fMarkerStyle = 20; - SetName(name); -} - -//______________________________________________________________________________ -PointSet::~PointSet() -{ - // Destructor. - - delete fIntIds; -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void PointSet::ComputeBBox() -{ - // Override of virtual method from TAttBBox. - - TPointSet3D::ComputeBBox(); - AssertBBoxExtents(0.1); -} - -//______________________________________________________________________________ -void PointSet::Reset(Int_t n_points, Int_t n_int_ids) -{ - // Drop all data and set-up the data structures to recive new data. - // n_points specifies the initial size of the arrays. - // n_int_ids specifies the number of integer ids per point. - - delete [] fP; fP = 0; - fN = n_points; - if(fN) fP = new Float_t [3*fN]; - memset(fP, 0, 3*fN*sizeof(Float_t)); - fLastPoint = -1; - ClearIds(); - delete fIntIds; fIntIds = 0; - fIntIdsPerPoint = n_int_ids; - if (fIntIdsPerPoint > 0) fIntIds = new TArrayI(fIntIdsPerPoint*fN); - ResetBBox(); -} - -//______________________________________________________________________________ -Int_t PointSet::GrowFor(Int_t n_points) -{ - // Resizes internal array to allow additional n_points to be stored. - // Returns the old size which is also the location where one can - // start storing new data. - // The caller is *obliged* to fill the new point slots. - - Int_t old_size = Size(); - Int_t new_size = old_size + n_points; - SetPoint(new_size - 1, 0, 0, 0); - if (fIntIds) - fIntIds->Set(fIntIdsPerPoint * new_size); - return old_size; -} - -/**************************************************************************/ - -//______________________________________________________________________________ -inline void PointSet::AssertIntIdsSize() -{ - // Assert that size of IntId array is compatible with the size of - // the point array. - - Int_t exp_size = GetN()*fIntIdsPerPoint; - if (fIntIds->GetSize() < exp_size) - fIntIds->Set(exp_size); -} - -//______________________________________________________________________________ -Int_t* PointSet::GetPointIntIds(Int_t p) const -{ - // Return a pointer to integer ids of point with index p. - // Existence of integer id array is checked, 0 is returned if it - // does not exist. - // Validity of p is *not* checked. - - if (fIntIds) - return fIntIds->GetArray() + p*fIntIdsPerPoint; - return 0; -} - -//______________________________________________________________________________ -Int_t PointSet::GetPointIntId(Int_t p, Int_t i) const -{ - // Return i-th integer id of point with index p. - // Existence of integer id array is checked, kMinInt is returned if - // it does not exist. - // Validity of p and i is *not* checked. - - if (fIntIds) - return * (fIntIds->GetArray() + p*fIntIdsPerPoint + i); - return kMinInt; -} - -//______________________________________________________________________________ -void PointSet::SetPointIntIds(Int_t* ids) -{ - // Set integer ids for the last point that was registerd (most - // probably via TPolyMarker3D::SetNextPoint(x,y,z)). - - SetPointIntIds(fLastPoint, ids); -} - -//______________________________________________________________________________ -void PointSet::SetPointIntIds(Int_t n, Int_t* ids) -{ - // Set integer ids for point with index n. - - if (!fIntIds) return; - AssertIntIdsSize(); - Int_t* x = fIntIds->GetArray() + n*fIntIdsPerPoint; - for (Int_t i=0; i 0) { - fIntIdsPerPoint = subIdNum; - if (!fIntIds) - fIntIds = new TArrayI(fIntIdsPerPoint*GetN()); - else - fIntIds->Set(fIntIdsPerPoint*GetN()); - } else { - delete fIntIds; fIntIds = 0; - fIntIdsPerPoint = 0; - } -} - -//______________________________________________________________________________ -void PointSet::TakeAction(TPointSelector* sel) -{ - // Called from TPointSelector when internal arrays of the tree-selector - // are filled up and need to be processed. - // Virtual from TPointSelectorConsumer. - - static const Exc_t eH("PointSet::TakeAction "); - - if(sel == 0) - throw(eH + "selector is ."); - - Int_t n = sel->GetNfill(); - Int_t beg = GrowFor(n); - - // printf("PointSet::TakeAction beg=%d n=%d size=%d nsubid=%d dim=%d\n", - // beg, n, Size(), sel->GetSubIdNum(), sel->GetDimension()); - - Double_t *vx = sel->GetV1(), *vy = sel->GetV2(), *vz = sel->GetV3(); - Float_t *p = fP + 3*beg; - - switch(fSourceCS) { - case TVT_XYZ: - while(n-- > 0) { - p[0] = *vx; p[1] = *vy; p[2] = *vz; - p += 3; - ++vx; ++vy; ++vz; - } - break; - case TVT_RPhiZ: - while(n-- > 0) { - p[0] = *vx * TMath::Cos(*vy); p[1] = *vx * TMath::Sin(*vy); p[2] = *vz; - p += 3; - ++vx; ++vy; ++vz; - } - break; - default: - throw(eH + "unknown tree variable type."); - } - - if (fIntIds) { - Double_t** subarr = new Double_t* [fIntIdsPerPoint]; - for (Int_t i=0; iGetVal(sel->GetDimension() - fIntIdsPerPoint + i); - if (subarr[i] == 0) - throw(eH + "sub-id array not available."); - } - Int_t* ids = fIntIds->GetArray() + fIntIdsPerPoint*beg; - n = sel->GetNfill(); - while (n-- > 0) { - for (Int_t i=0; iGetRnrSelf()) - (*i)->GetObject()->Paint(option); - } - } -} - -//______________________________________________________________________________ -void PointSetArray::RemoveElementLocal(RenderElement* el) -{ - // Virtual from RenderElement, provide bin management. - - for (Int_t i=0; i((*i)->GetObject()); - if (m && m->GetMarkerColor() == fMarkerColor) - m->SetMarkerColor(tcolor); - } - TAttMarker::SetMarkerColor(tcolor); -} - -//______________________________________________________________________________ -void PointSetArray::SetMarkerStyle(Style_t mstyle) -{ - for (List_i i=fChildren.begin(); i!=fChildren.end(); ++i) { - TAttMarker* m = dynamic_cast((*i)->GetObject()); - if (m && m->GetMarkerStyle() == fMarkerStyle) - m->SetMarkerStyle(mstyle); - } - TAttMarker::SetMarkerStyle(mstyle); -} - -//______________________________________________________________________________ -void PointSetArray::SetMarkerSize(Size_t msize) -{ - for (List_i i=fChildren.begin(); i!=fChildren.end(); ++i) { - TAttMarker* m = dynamic_cast((*i)->GetObject()); - if (m && m->GetMarkerSize() == fMarkerSize) - m->SetMarkerSize(msize); - } - TAttMarker::SetMarkerSize(msize); -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void PointSetArray::TakeAction(TPointSelector* sel) -{ - // Called from TPointSelector when internal arrays of the tree-selector - // are filled up and need to be processed. - // Virtual from TPointSelectorConsumer. - - static const Exc_t eH("PointSetArray::TakeAction "); - - if (sel == 0) - throw(eH + "selector is ."); - - Int_t n = sel->GetNfill(); - - // printf("PointSetArray::TakeAction n=%d\n", n); - - Double_t *vx = sel->GetV1(), *vy = sel->GetV2(), *vz = sel->GetV3(); - Double_t *qq = sel->GetV4(); - - if(qq == 0) - throw(eH + "requires 4-d varexp."); - - switch(fSourceCS) { - case TVT_XYZ: - while(n-- > 0) { - Fill(*vx, *vy, *vz, *qq); - ++vx; ++vy; ++vz; ++qq; - } - break; - case TVT_RPhiZ: - while(n-- > 0) { - Fill(*vx * TMath::Cos(*vy), *vx * TMath::Sin(*vy), *vz, *qq); - ++vx; ++vy; ++vz; ++qq; - } - break; - default: - throw(eH + "unknown tree variable type."); - } -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void PointSetArray::InitBins(const Text_t* quant_name, - Int_t nbins, Double_t min, Double_t max, - Bool_t addRe) -{ - static const Exc_t eH("PointSetArray::InitBins "); - - if (nbins < 1) throw(eH + "nbins < 1."); - if (min > max) throw(eH + "min > max."); - - RemoveElements(); - - fQuantName = quant_name; - fNBins = nbins; - fLastBin = -1; - fMin = fCurMin = min; - fMax = fCurMax = max; - fBinWidth = (fMax - fMin)/fNBins; - - fBins = new Reve::PointSet*[fNBins]; - for (Int_t i=0; iSetMarkerColor(fMarkerColor); - fBins[i]->SetMarkerStyle(fMarkerStyle); - fBins[i]->SetMarkerSize(fMarkerSize); - if (addRe) - gReve->AddRenderElement(fBins[i], this); - else - AddElement(fBins[i]); - } -} - -//______________________________________________________________________________ -void PointSetArray::Fill(Double_t x, Double_t y, Double_t z, Double_t quant) -{ - fLastBin = Int_t( (quant - fMin)/fBinWidth ); - if (fLastBin >= 0 && fLastBin < fNBins && fBins[fLastBin] != 0) - fBins[fLastBin]->SetNextPoint(x, y, z); - else - fLastBin = -1; -} - -//______________________________________________________________________________ -void PointSetArray::SetPointId(TObject* id) -{ - if (fLastBin >= 0) - fBins[fLastBin]->SetPointId(id); -} - -//______________________________________________________________________________ -void PointSetArray::CloseBins() -{ - for (Int_t i=0; ifN = fBins[i]->fLastPoint; - - fBins[i]->ComputeBBox(); - } - } - fLastBin = -1; -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void PointSetArray::SetOwnIds(Bool_t o) -{ - for (Int_t i=0; iSetOwnIds(o); - } -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void PointSetArray::SetRange(Double_t min, Double_t max) -{ - using namespace TMath; - - fCurMin = min; fCurMax = max; - Int_t low_b = (Int_t) Max(Double_t(0), Floor((min-fMin)/fBinWidth)); - Int_t high_b = (Int_t) Min(Double_t(fNBins-1), Ceil((max-fMin)/fBinWidth)); - for (Int_t i=0; iSetRnrSelf(i>=low_b && i<=high_b); - } -} - - -/******************************************************************************/ -/******************************************************************************/ - -//______________________________________________________________________________ -// NLTPointSet -// - -ClassImp(NLTPointSet) - -//______________________________________________________________________________ -NLTPointSet::NLTPointSet() : - PointSet (), - NLTProjected () -{ - // Default contructor. -} - -//______________________________________________________________________________ -void NLTPointSet::SetProjection(NLTProjector* proj, NLTProjectable* model) -{ - NLTProjected::SetProjection(proj, model); - - * (TAttMarker*)this = * dynamic_cast(fProjectable); -} - -//______________________________________________________________________________ -void NLTPointSet::UpdateProjection() -{ - NLTProjection& proj = * fProjector->GetProjection(); - PointSet & ps = * dynamic_cast(fProjectable); - - Int_t n = ps.GetN(); - Reset(n); - Float_t *o = ps.GetP(), *p = GetP(); - for (Int_t i = 0; i < n; ++i, o+=3, p+=3) - { - p[0] = o[0]; p[1] = o[1]; p[2] = o[2]; - proj.ProjectPoint(p[0], p[1], p[2]); - p[2] = fDepth; - } - fLastPoint = n - 1; -} diff --git a/EVE/Reve/PointSet.h b/EVE/Reve/PointSet.h deleted file mode 100644 index bf3979dec08..00000000000 --- a/EVE/Reve/PointSet.h +++ /dev/null @@ -1,162 +0,0 @@ -// $Header$ - -#ifndef REVE_GuiPointSet_H -#define REVE_GuiPointSet_H - -#include -#include -#include -#include - -#include -#include -#include - -class TTree; -class TF3; -class TGListTreeItem; - -namespace Reve { - -class PointSet : public RenderElement, - public TPointSet3D, - public TPointSelectorConsumer, - public TQObject, - public NLTProjectable -{ - friend class PointSetArray; - -protected: - TString fTitle; // Title/tooltip of the PointSet. - TArrayI *fIntIds; // Optional array of integer ideices. - Int_t fIntIdsPerPoint; // Number of integer indices assigned to each point. - - void AssertIntIdsSize(); - -public: - PointSet(Int_t n_points=0, TreeVarType_e tv_type=TVT_XYZ); - PointSet(const Text_t* name, Int_t n_points=0, TreeVarType_e tv_type=TVT_XYZ); - virtual ~PointSet(); - - virtual void ComputeBBox(); - - void Reset(Int_t n_points=0, Int_t n_int_ids=0); - Int_t GrowFor(Int_t n_points); - - virtual const Text_t* GetTitle() const { return fTitle; } - virtual void SetTitle(const Text_t* t) { fTitle = t; } - - Int_t GetIntIdsPerPoint() const { return fIntIdsPerPoint; } - Int_t* GetPointIntIds(Int_t p) const; - Int_t GetPointIntId(Int_t p, Int_t i) const; - - void SetPointIntIds(Int_t* ids); - void SetPointIntIds(Int_t n, Int_t* ids); - - virtual void SetRnrElNameTitle(const Text_t* name, const Text_t* title); - - virtual void SetMarkerColor(Color_t col) - { SetMainColor(col); } - - virtual void Paint(Option_t* option=""); - - virtual void InitFill(Int_t subIdNum); - virtual void TakeAction(TPointSelector*); - - virtual void PointSelected(Int_t id); - virtual void PointCtrlClicked(PointSet* ps, Int_t id); // *SIGNAL* - - virtual const TGPicture* GetListTreeIcon() { return RenderElement::fgListTreeIcons[3]; } - - virtual TClass* ProjectedClass() const; - - ClassDef(PointSet, 1); // Render element containing an array of 3D points. -}; // endclass PointSet - -/**************************************************************************/ - -class PointSetArray : public RenderElement, - public TNamed, - public TAttMarker, - public TPointSelectorConsumer -{ - friend class PointSetArrayEditor; - - PointSetArray(const PointSetArray&); // Not implemented - PointSetArray& operator=(const PointSetArray&); // Not implemented - -protected: - PointSet** fBins; // Pointers to subjugated PointSet's. - Int_t fDefPointSetCapacity; // Default capacity of subjugated PointSet's. - Int_t fNBins; // Number of subjugated PointSet's. - Int_t fLastBin; //! Index of the last filled PointSet. - Double_t fMin, fCurMin; // Overall and current minimum value of the separating quantity. - Double_t fMax, fCurMax; // Overall and current maximum value of the separating quantity. - Double_t fBinWidth; // Separating quantity bin-width. - TString fQuantName; // Name of the separating quantity. - -public: - PointSetArray(const Text_t* name="PointSetArray", const Text_t* title=""); - virtual ~PointSetArray(); - - virtual void RemoveElementLocal(RenderElement* el); - virtual void RemoveElementsLocal(); - - virtual void Paint(Option_t* option=""); - - virtual void SetMarkerColor(Color_t tcolor=1); - virtual void SetMarkerStyle(Style_t mstyle=1); - virtual void SetMarkerSize(Size_t msize=1); - - virtual void TakeAction(TPointSelector*); - - - void InitBins(const Text_t* quant_name, Int_t nbins, Double_t min, Double_t max, - Bool_t addRe=kTRUE); - void Fill(Double_t x, Double_t y, Double_t z, Double_t quant); - void SetPointId(TObject* id); - void CloseBins(); - - void SetOwnIds(Bool_t o); - - Int_t GetDefPointSetCapacity() const { return fDefPointSetCapacity; } - void SetDefPointSetCapacity(Int_t c) { fDefPointSetCapacity = c; } - - Int_t GetNBins() const { return fNBins; } - PointSet* GetBin(Int_t bin) const { return fBins[bin]; } - - Double_t GetMin() const { return fMin; } - Double_t GetCurMin() const { return fCurMin; } - Double_t GetMax() const { return fMax; } - Double_t GetCurMax() const { return fCurMax; } - - void SetRange(Double_t min, Double_t max); - - ClassDef(PointSetArray, 1); // Array of centrally managed PointSet's. -}; - -/**************************************************************************/ - -class NLTPointSet : public PointSet, - public NLTProjected -{ -private: - NLTPointSet(const NLTPointSet&); // Not implemented - NLTPointSet& operator=(const NLTPointSet&); // Not implemented - -protected: - -public: - NLTPointSet(); - virtual ~NLTPointSet() {} - - virtual void SetProjection(NLTProjector* proj, NLTProjectable* model); - - virtual void UpdateProjection(); - - ClassDef(NLTPointSet, 1); // NLT projected PointSet. -}; // endclass NLTPointSet - -} - -#endif diff --git a/EVE/Reve/PointSetArrayEditor.cxx b/EVE/Reve/PointSetArrayEditor.cxx deleted file mode 100644 index 7d36b4bc0de..00000000000 --- a/EVE/Reve/PointSetArrayEditor.cxx +++ /dev/null @@ -1,78 +0,0 @@ -// $Header$ - -#include "PointSetArrayEditor.h" -#include -#include - -#include -#include - -#include -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// PointSetArrayEditor -// - -ClassImp(PointSetArrayEditor) - -//______________________________________________________________________________ -PointSetArrayEditor::PointSetArrayEditor(const TGWindow *p, - Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p,width, height, options | kVerticalFrame, back), - fM(0), - fRange(0) -{ - // Constructor. - - fM = 0; - MakeTitle("PointSetArray"); - - fRange = new RGDoubleValuator(this,"Range", 200, 0); - fRange->SetNELength(6); - //fRange->SetLabelWidth(labelW); - fRange->Build(); - fRange->GetSlider()->SetWidth(224); - fRange->Connect("ValueSet()", - "Reve::PointSetArrayEditor", this, "DoRange()"); - AddFrame(fRange, new TGLayoutHints(kLHintsTop, 1, 1, 2, 1)); -} - -//______________________________________________________________________________ -PointSetArrayEditor::~PointSetArrayEditor() -{ - // Destructor. -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void PointSetArrayEditor::SetModel(TObject* obj) -{ - // Set model object. - - fM = dynamic_cast(obj); - - // printf("FullRange(%f, %f) Selected(%f,%f)\n", - // fM->GetMin(), fM->GetMax(), fM->GetCurMin(), fM->GetCurMax()); - - fRange->SetLimits(fM->fMin, fM->fMax, TGNumberFormat::kNESRealTwo); - fRange->SetValues(fM->fCurMin, fM->fCurMax); -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void PointSetArrayEditor::DoRange() -{ - // Slot for setting the range of the separating quantity. - - fM->SetRange(fRange->GetMin(), fRange->GetMax()); - Update(); -} diff --git a/EVE/Reve/PointSetArrayEditor.h b/EVE/Reve/PointSetArrayEditor.h deleted file mode 100644 index cce703e0d1a..00000000000 --- a/EVE/Reve/PointSetArrayEditor.h +++ /dev/null @@ -1,43 +0,0 @@ -// $Header$ - -#ifndef REVE_PointSetArrayEditor_H -#define REVE_PointSetArrayEditor_H - -#include - -class TGCheckButton; -class TGNumberEntry; -class TGColorSelect; - -namespace Reve { - -class RGValuator; -class RGDoubleValuator; - -class PointSetArray; - -class PointSetArrayEditor : public TGedFrame -{ - PointSetArrayEditor(const PointSetArrayEditor&); // Not implemented - PointSetArrayEditor& operator=(const PointSetArrayEditor&); // Not implemented - -protected: - PointSetArray *fM; // Model object. - - Reve::RGDoubleValuator *fRange; // Control for displayed range of the separating quantity. - -public: - PointSetArrayEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, - UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - ~PointSetArrayEditor(); - - virtual void SetModel(TObject* obj); - - void DoRange(); - - ClassDef(PointSetArrayEditor, 1); // Editor for PointSetArray class. -}; // endclass PointSetArrayEditor - -} - -#endif diff --git a/EVE/Reve/QuadSet.cxx b/EVE/Reve/QuadSet.cxx deleted file mode 100644 index 1e6709eb28f..00000000000 --- a/EVE/Reve/QuadSet.cxx +++ /dev/null @@ -1,602 +0,0 @@ -// $Header$ - -#include "QuadSet.h" - -#include "ReveManager.h" - -#include - -#include -#include -#include -#include - -#include -#include - - -using namespace Reve; - -/**************************************************************************/ -// Quad -/**************************************************************************/ - -ClassImp(Reve::Quad) - -void Quad::ColorFromIdx(Color_t ci) -{ - TColor* c = gROOT->GetColor(ci); - if(c) { - UChar_t *x = (UChar_t*) &color; - x[0] = (UChar_t)(255*c->GetRed()); x[1] = (UChar_t)(255*c->GetGreen()); - x[2] = (UChar_t)(255*c->GetBlue()); x[3] = 255; - } -} - -Quad::Quad(TRandom& rnd, Float_t origin, Float_t size) : color(0) -{ - ColorFromIdx(Int_t(30*rnd.Rndm())); - Float_t x = 2*origin*(rnd.Rndm() - 0.5); - Float_t y = 2*origin*(rnd.Rndm() - 0.5); - Float_t z = 2*origin*(rnd.Rndm() - 0.5); - Float_t* p = vertices; - for(int i=0; i<4; ++i) { - p[0] = x + 2*size*(rnd.Rndm() - 0.5); - p[1] = y + 2*size*(rnd.Rndm() - 0.5); - p[2] = z + 2*size*(rnd.Rndm() - 0.5); - p += 3; - } -} - -/**************************************************************************/ -// OldQuadSet -/**************************************************************************/ -ClassImp(Reve::OldQuadSet) - - -OldQuadSet::OldQuadSet(const Text_t* n, const Text_t* t) : - TNamed(n, t), - fQuads(), - fTrans(false) -{} - -void OldQuadSet::Test(Int_t nquads) -{ - TRandom rnd(0); - fQuads.resize(nquads); - for(Int_t i=0; iGetViewer3D()->AddObject(buffer); - if (reqSections == TBuffer3D::kNone) { - // printf("OldQuadSet::Paint viewer was happy with Core buff3d.\n"); - return; - } - - if (reqSections & TBuffer3D::kRawSizes) { - Int_t nbPnts = fQuads.size()*4; - Int_t nbSegs = nbPnts; - if (!buffer.SetRawSizes(nbPnts, 3*nbPnts, nbSegs, 3*nbSegs, fQuads.size(), fQuads.size()*6)) { - return; - } - buffer.SetSectionsValid(TBuffer3D::kRawSizes); - } - - if ((reqSections & TBuffer3D::kRaw) && buffer.SectionsValid(TBuffer3D::kRawSizes)) { - // Points - Int_t pidx = 0; - for (std::vector::iterator i=fQuads.begin(); i!=fQuads.end(); ++i) { - for (Int_t k = 0; k < 12; k++ ){ - buffer.fPnts[pidx] = (*i).vertices[k]; - pidx++; - } - } - - // Segments - Int_t sidx = 0; - for (Int_t q = 0; q < (Int_t)fQuads.size(); ++q) { - for (Int_t s = 0; s < 4; ++s ) { - buffer.fSegs[3*sidx ] = 4; - buffer.fSegs[3*sidx+1] = sidx; - if (s == 3) - buffer.fSegs[3*sidx+2] = q*4; - else - buffer.fSegs[3*sidx+2] = sidx + 1; - sidx ++; - } - } - - // Polygons - for (Int_t q = 0; q < (Int_t)fQuads.size(); ++q) { - buffer.fPols[6*q] = fQuads[q].color; - buffer.fPols[6*q +1] = 4; - buffer.fPols[6*q +2] = 4*q + 0; - buffer.fPols[6*q +3] = 4*q + 1; - buffer.fPols[6*q +4] = 4*q + 2; - buffer.fPols[6*q +5] = 4*q + 3; - } - - buffer.SetSectionsValid(TBuffer3D::kRaw); - buffer.fColor = 5; - } - - gPad->GetViewer3D()->AddObject(buffer); -} - -/**************************************************************************/ - -void OldQuadSet::ComputeBBox() -{ - if(fQuads.empty()) { - BBoxZero(); - return; - } - BBoxInit(); - for(std::vector::iterator q=fQuads.begin(); q!=fQuads.end(); ++q) { - Float_t* p = q->vertices; - for(int i=0; i<4; ++i, p+=3) - BBoxCheckPoint(p); - } - - // printf("%s BBox is x(%f,%f), y(%f,%f), z(%f,%f)\n", GetName(), - // fBBox[0], fBBox[1], fBBox[2], fBBox[3], fBBox[4], fBBox[5]); -} - -/**************************************************************************/ -/**************************************************************************/ -/**************************************************************************/ -/**************************************************************************/ - -//__________________________________________________________________________ -// QuadSet -// -// Supports various internal formats that result in rendering of a -// set of planar (lines, rectangles, hegagons with shared normal) objects. -// -// Names of internal structures and their variables use A, B and C as -// names for coordinate value-holders. Typical assignment is A->X, -// B->Y, C->Z but each render mode can override this convention and -// impose y or x as a fixed (third or C) coordinate. Alphabetic order -// is obeyed in this correspondence. -// -// For quad modes the deltas are expected to be positive. -// For line modes negative deltas are ok. - -ClassImp(Reve::QuadSet) - -QuadSet::QuadSet(const Text_t* n, const Text_t* t) : - DigitSet (n, t), - - fQuadType (QT_Undef), - fDefWidth (1), - fDefHeight (1), - fDefCoord (0) -{} - -QuadSet::QuadSet(QuadType_e quadType, Bool_t valIsCol, Int_t chunkSize, - const Text_t* n, const Text_t* t) : - DigitSet (n, t), - - fQuadType (QT_Undef), - fDefWidth (1), - fDefHeight (1), - fDefCoord (0) -{ - Reset(quadType, valIsCol, chunkSize); -} - -QuadSet::~QuadSet() -{} - - -/**************************************************************************/ - -Int_t QuadSet::SizeofAtom(QuadSet::QuadType_e qt) -{ - static const Exc_t eH("QuadSet::SizeofAtom "); - - switch (qt) { - case QT_Undef: return 0; - case QT_FreeQuad: return sizeof(QFreeQuad); - case QT_RectangleXY: - case QT_RectangleXZ: - case QT_RectangleYZ: return sizeof(QRect); - case QT_RectangleXYFixedDim: return sizeof(QRectFixDim); - case QT_RectangleXYFixedZ: - case QT_RectangleXZFixedY: - case QT_RectangleYZFixedX: return sizeof(QRectFixC); - case QT_RectangleXYFixedDimZ: - case QT_RectangleXZFixedDimY: - case QT_RectangleYZFixedDimX: return sizeof(QRectFixDimC); - case QT_LineXZFixedY: - case QT_LineXYFixedZ: return sizeof(QLineFixC); - case QT_HexagonXY: - case QT_HexagonYX: return sizeof(QHex); - default: throw(eH + "unexpected atom type."); - } - return 0; -} - -/**************************************************************************/ - -void QuadSet::Reset(QuadSet::QuadType_e quadType, Bool_t valIsCol, Int_t chunkSize) -{ - fQuadType = quadType; - fValueIsColor = valIsCol; - fDefaultValue = valIsCol ? 0 : kMinInt; - if (fOwnIds) - ReleaseIds(); - fPlex.Reset(SizeofAtom(fQuadType), chunkSize); -} - -/**************************************************************************/ - -void QuadSet::AddQuad(Float_t* verts) -{ - static const Exc_t eH("QuadSet::AddQuad "); - - if (fQuadType != QT_FreeQuad) - throw(eH + "expect free quad-type."); - - QFreeQuad* fq = (QFreeQuad*) NewDigit(); - memcpy(fq->fVertices, verts, sizeof(fq->fVertices)); -} - -void QuadSet::AddQuad(Float_t a, Float_t b) -{ - AddQuad(a, b, fDefCoord, fDefWidth, fDefHeight); -} - -void QuadSet::AddQuad(Float_t a, Float_t b, Float_t c) -{ - AddQuad(a, b, c, fDefWidth, fDefHeight); -} - -void QuadSet::AddQuad(Float_t a, Float_t b, Float_t w, Float_t h) -{ - AddQuad(a, b, fDefCoord, w, h); -} - -void QuadSet::AddQuad(Float_t a, Float_t b, Float_t c, Float_t w, Float_t h) -{ - static const Exc_t eH("QuadSet::AddAAQuad "); - - QOrigin& fq = * (QOrigin*) NewDigit(); - fq.fA = a; fq.fB = b; - switch (fQuadType) - { - case QT_RectangleXY: - case QT_RectangleXZ: - case QT_RectangleYZ: - { - QRect& q = (QRect&) fq; - q.fC = c; q.fW = w; q.fH = h; - break; - } - - case QT_RectangleXYFixedDim: - { - QRectFixDim& q = (QRectFixDim&) fq; - q.fC = c; - break; - } - - case QT_RectangleXYFixedZ: - case QT_RectangleXZFixedY: - case QT_RectangleYZFixedX: - { - QRectFixC& q = (QRectFixC&) fq; - q.fW = w; q.fH = h; - break; - } - - case QT_RectangleXYFixedDimZ: - case QT_RectangleXZFixedDimY: - case QT_RectangleYZFixedDimX: - { - break; - } - - default: - throw(eH + "expect axis-aligned quad-type."); - } -} - -void QuadSet::AddLine(Float_t a, Float_t b, Float_t w, Float_t h) -{ - static const Exc_t eH("QuadSet::AddLine "); - - QOrigin& fq = * (QOrigin*) NewDigit(); - fq.fA = a; fq.fB = b; - switch (fQuadType) - { - case QT_LineXZFixedY: - case QT_LineXYFixedZ: { - QLineFixC& q = (QLineFixC&) fq; - q.fDx = w; q.fDy = h; - break; - } - default: - throw(eH + "expect line quad-type."); - } -} - -void QuadSet::AddHexagon(Float_t a, Float_t b, Float_t c, Float_t r) -{ - static const Exc_t eH("QuadSet::AddHexagon "); - - QOrigin& fq = * (QOrigin*) NewDigit(); - fq.fA = a; fq.fB = b; - switch (fQuadType) - { - case QT_HexagonXY: - case QT_HexagonYX: { - QHex& q = (QHex&) fq; - q.fC = c; q.fR = r; - break; - } - default: - throw(eH + "expect line quad-type."); - } -} - -/**************************************************************************/ -/**************************************************************************/ - -void QuadSet::ComputeBBox() -{ - // Fill bounding-box information of the base-class TAttBBox (virtual method). - // If member 'FrameBox* fFrame' is set, frame's corners are used as bbox. - - static const Exc_t eH("QuadSet::ComputeBBox "); - - if (fFrame != 0) - { - BBoxInit(); - Int_t n = fFrame->GetFrameSize() / 3; - Float_t *bbps = fFrame->GetFramePoints(); - for (int i=0; ifVertices; - BBoxCheckPoint(p); p += 3; - BBoxCheckPoint(p); p += 3; - BBoxCheckPoint(p); p += 3; - BBoxCheckPoint(p); - } - break; - } - - case QT_RectangleXY: - { - while (qi.next()) { - QRect& q = * (QRect*) qi(); - if(q.fA < fBBox[0]) fBBox[0] = q.fA; - if(q.fA + q.fW > fBBox[1]) fBBox[1] = q.fA + q.fW; - if(q.fB < fBBox[2]) fBBox[2] = q.fB; - if(q.fB + q.fH > fBBox[3]) fBBox[3] = q.fB + q.fH; - if(q.fC < fBBox[4]) fBBox[4] = q.fC; - if(q.fC > fBBox[5]) fBBox[5] = q.fC; - } - break; - } - - case QT_RectangleXZ: - { - while (qi.next()) { - QRect& q = * (QRect*) qi(); - if(q.fA < fBBox[0]) fBBox[0] = q.fA; - if(q.fA + q.fW > fBBox[1]) fBBox[1] = q.fA + q.fW; - if(q.fB < fBBox[4]) fBBox[4] = q.fB; - if(q.fB + q.fH > fBBox[5]) fBBox[5] = q.fB + q.fH; - if(q.fC < fBBox[2]) fBBox[2] = q.fC; - if(q.fC > fBBox[3]) fBBox[3] = q.fC; - } - break; - } - - case QT_RectangleYZ: - { - while (qi.next()) { - QRect& q = * (QRect*) qi(); - if(q.fA < fBBox[2]) fBBox[2] = q.fA; - if(q.fA + q.fW > fBBox[3]) fBBox[3] = q.fA + q.fW; - if(q.fB < fBBox[4]) fBBox[4] = q.fB; - if(q.fB + q.fH > fBBox[5]) fBBox[5] = q.fB + q.fH; - if(q.fC < fBBox[0]) fBBox[0] = q.fC; - if(q.fC > fBBox[1]) fBBox[1] = q.fC; - } - break; - } - - case QT_RectangleXYFixedDim: - { - const Float_t& w = fDefWidth; - const Float_t& h = fDefHeight; - while (qi.next()) { - QRectFixDim& q = * (QRectFixDim*) qi(); - if(q.fA < fBBox[0]) fBBox[0] = q.fA; - if(q.fA + w > fBBox[1]) fBBox[1] = q.fA + w; - if(q.fB < fBBox[2]) fBBox[2] = q.fB; - if(q.fB + h > fBBox[3]) fBBox[3] = q.fB + h; - if(q.fC < fBBox[4]) fBBox[4] = q.fC; - if(q.fC > fBBox[5]) fBBox[5] = q.fC; - } - break; - } - - case QT_RectangleXYFixedZ: - { - while (qi.next()) { - QRectFixC& q = * (QRectFixC*) qi(); - if(q.fA < fBBox[0]) fBBox[0] = q.fA; - if(q.fA + q.fW > fBBox[1]) fBBox[1] = q.fA + q.fW; - if(q.fB < fBBox[2]) fBBox[2] = q.fB; - if(q.fB + q.fH > fBBox[3]) fBBox[3] = q.fB + q.fH; - } - break; - } - - case QT_RectangleXZFixedY: - { - while (qi.next()) { - QRectFixC& q = * (QRectFixC*) qi(); - if(q.fA < fBBox[0]) fBBox[0] = q.fA; - if(q.fA + q.fW > fBBox[1]) fBBox[1] = q.fA + q.fW; - if(q.fB < fBBox[4]) fBBox[4] = q.fB; - if(q.fB + q.fH > fBBox[5]) fBBox[5] = q.fB + q.fH; - } - break; - } - - case QT_RectangleYZFixedX: - { - while (qi.next()) { - QRectFixC& q = * (QRectFixC*) qi(); - if(q.fA < fBBox[2]) fBBox[2] = q.fA; - if(q.fA + q.fW > fBBox[3]) fBBox[3] = q.fA + q.fW; - if(q.fB < fBBox[4]) fBBox[4] = q.fB; - if(q.fB + q.fH > fBBox[5]) fBBox[5] = q.fB + q.fH; - } - break; - } - - case QT_RectangleXYFixedDimZ: - { - const Float_t& w = fDefWidth; - const Float_t& h = fDefHeight; - while (qi.next()) { - QRectFixDimC& q = * (QRectFixDimC*) qi(); - if(q.fA < fBBox[0]) fBBox[0] = q.fA; - if(q.fA + w > fBBox[1]) fBBox[1] = q.fA + w; - if(q.fB < fBBox[2]) fBBox[2] = q.fB; - if(q.fB + h > fBBox[3]) fBBox[3] = q.fB + h; - } - break; - } - - case QT_RectangleXZFixedDimY: - { - const Float_t& w = fDefWidth; - const Float_t& h = fDefHeight; - while (qi.next()) { - QRectFixDimC& q = * (QRectFixDimC*) qi(); - if(q.fA < fBBox[0]) fBBox[0] = q.fA; - if(q.fA + w > fBBox[1]) fBBox[1] = q.fA + w; - if(q.fB < fBBox[4]) fBBox[4] = q.fB; - if(q.fB + h > fBBox[5]) fBBox[5] = q.fB + h; - } - break; - } - - case QT_RectangleYZFixedDimX: - { - const Float_t& w = fDefWidth; - const Float_t& h = fDefHeight; - while (qi.next()) { - QRectFixDimC& q = * (QRectFixDimC*) qi(); - if(q.fA < fBBox[2]) fBBox[2] = q.fA; - if(q.fA + w > fBBox[3]) fBBox[3] = q.fA + w; - if(q.fB < fBBox[4]) fBBox[4] = q.fB; - if(q.fB + h > fBBox[5]) fBBox[5] = q.fB + h; - } - break; - } - - // Line modes - - case QT_LineXYFixedZ: - { - while (qi.next()) { - QLineFixC& q = * (QLineFixC*) qi(); - BBoxCheckPoint(q.fA, q.fB, fDefCoord); - BBoxCheckPoint(q.fA + q.fDx, q.fB + q.fDy, fDefCoord); - } - break; - } - - case QT_LineXZFixedY: - { - while (qi.next()) { - QLineFixC& q = * (QLineFixC*) qi(); - BBoxCheckPoint(q.fA, fDefCoord, q.fB); - BBoxCheckPoint(q.fA + q.fDx, fDefCoord, q.fB + q.fDy); - } - break; - } - - // Hexagon modes - - // Ignore 'slight' difference, assume square box for both cases. - case QT_HexagonXY: - case QT_HexagonYX: - { - while (qi.next()) { - QHex& q = * (QHex*) qi(); - BBoxCheckPoint(q.fA-q.fR, q.fB-q.fR, q.fC); - BBoxCheckPoint(q.fA+q.fR, q.fB+q.fR, q.fC); - } - break; - } - - default: - { - throw(eH + "unsupported quad-type."); - } - - } // end switch quad-type - } // end if frame ... else ... - - AssertBBoxExtents(0.001); -} diff --git a/EVE/Reve/QuadSet.h b/EVE/Reve/QuadSet.h deleted file mode 100644 index 650e8e961f9..00000000000 --- a/EVE/Reve/QuadSet.h +++ /dev/null @@ -1,181 +0,0 @@ -// $Header$ - -#ifndef REVE_QuadSet_H -#define REVE_QuadSet_H - -#include - -#include // For OldQuadSet - -class TRandom; - -namespace Reve { - -struct Quad -{ - Float_t vertices[12]; - Int_t color; - - void ColorFromIdx(Color_t ci); - - Quad(Color_t col = 1) : color(0) - { ColorFromIdx(col); } - - Quad(Color_t col, Float_t* p) : color(0) - { ColorFromIdx(col); memcpy(vertices, p, 12*sizeof(Float_t)); } - - Quad(TRandom& rnd, Float_t origin, Float_t size); - - Quad(const Quad& org) : color(0) { memcpy(this, &org, sizeof(Quad)); } - - virtual ~Quad() {} - - ClassDef(Quad, 1); -}; - -class OldQuadSet : public TNamed, public TAtt3D, public TAttBBox -{ - friend class OldQuadSetGL; - -protected: - std::vector fQuads; - Double_t fMatrix[16]; - Bool_t fTrans; - -public: - OldQuadSet(const Text_t* n="QuadSet", const Text_t* t=""); - virtual ~OldQuadSet() {} - - Bool_t GetTrans() const { return fTrans; } - void SetTrans(Bool_t t) { fTrans = t; } - - std::vector& Quads() { return fQuads; } - - void Test(Int_t nquads); - - virtual void ComputeBBox(); - - virtual void Paint(Option_t* option = ""); - - ClassDef(OldQuadSet, 1); -}; - -/**************************************************************************/ -// To become new implementation of QuadSet ... somewhat finished. -/**************************************************************************/ - -class QuadSet : public DigitSet -{ - friend class QuadSetGL; - - QuadSet(const QuadSet&); // Not implemented - QuadSet& operator=(const QuadSet&); // Not implemented - -public: - enum QuadType_e - { - QT_Undef, // unknown-ignored - QT_FreeQuad, // arbitrary quad: specify 4*(x,y,z) quad corners - QT_RectangleXY, // rectangle in x-y plane: specify x, y, z, w, h - QT_RectangleXZ, // rectangle in x-z plane: specify x, y, z, w, h - QT_RectangleYZ, // rectangle in y-z plane: specify x, y, z, w, h - QT_RectangleXYFixedDim, // rectangle in x-y plane: specify x, y, z; w, h taken from fDefWidth/Height - QT_RectangleXYFixedZ, // rectangle in x-y plane: specify x, y, w, h; z taken from fDefCoord - QT_RectangleXZFixedY, // rectangle in x-z plane: specify x, z, w, h; y taken from fDefCoord - QT_RectangleYZFixedX, // rectangle in y-z plane: specify y, z, w, h; x taken from fDefWidth/Height/Coord - QT_RectangleXYFixedDimZ, // rectangle in x-y plane: specify x, y; w, h, z taken from fDefWidth/Height/Coord - QT_RectangleXZFixedDimY, // rectangle in x-z plane: specify x, z; w, h, y taken from fDefWidth/Height/Coord - QT_RectangleYZFixedDimX, // rectangle in y-z plane: specify y, z; w, h, x taken from fDefWidth/Height/Coord - QT_Rectangle_End, - // line modes (needed for uniform handling of silicon-strip digits) - QT_LineXYFixedZ, // line in x-y plane: specify x, y, w(dx), h(dy); z taken from fDefCoord - QT_LineXZFixedY, // line in x-z plane: specify x, z, w(dx), h(dz); y taken from fDefCoord - QT_Line_End, - // hexagon modes - QT_HexagonXY, // horizontal hexagon: specify x, y, z, r - QT_HexagonYX, // vertical hexagon: specify x, y, z, r - QT_Hexagon_End - // circle modes: - // QT_CircleXY, // specify r, z - // QT_CircleXYFixedZ, // specify r - // QT_CircleXYFixedR, // specify z - }; - - enum RenderMode_e { RM_AsIs, RM_Line, RM_Fill }; - -protected: - - struct QFreeQuad : public DigitBase { Float_t fVertices[12]; }; - - struct QOrigin : public DigitBase { Float_t fA, fB; }; - - struct QRectFixDimC : public QOrigin { }; - - struct QRectFixDim : public QRectFixDimC { Float_t fC; }; - - struct QRectFixC : public QRectFixDimC { Float_t fW, fH; }; - - struct QRect : public QRectFixDim { Float_t fW, fH; }; - - struct QLineFixC : public QOrigin { Float_t fDx, fDy; }; - - struct QHex : public QOrigin { Float_t fC, fR; }; - -protected: - QuadType_e fQuadType; - - Float_t fDefWidth; // Breadth assigned to first coordinate (A) - Float_t fDefHeight; // Breadth assigned to second coordinate (B) - Float_t fDefCoord; // Default value for third coordinate (C) - - static Int_t SizeofAtom(QuadType_e qt); - -public: - QuadSet(const Text_t* n="QuadSet", const Text_t* t=""); - QuadSet(QuadType_e quadType, Bool_t valIsCol, Int_t chunkSize, - const Text_t* n="QuadSet", const Text_t* t=""); - virtual ~QuadSet(); - - void Reset(QuadType_e quadType, Bool_t valIsCol, Int_t chunkSize); - - Float_t GetDefWidth() const { return fDefWidth; } - Float_t GetDefHeight() const { return fDefHeight; } - Float_t GetDefCoord() const { return fDefCoord; } - - void SetDefWidth(Float_t v) { fDefWidth = v ; } - void SetDefHeight(Float_t v) { fDefHeight = v ; } - void SetDefCoord(Float_t v) { fDefCoord = v ; } - - // -------------------------------- - - void AddQuad(Float_t* verts); - - void AddQuad(Float_t a, Float_t b); - void AddQuad(Float_t a, Float_t b, Float_t c); - void AddQuad(Float_t a, Float_t b, Float_t w, Float_t h); - void AddQuad(Float_t a, Float_t b, Float_t c, Float_t w, Float_t h); - - void AddLine(Float_t a, Float_t b, Float_t w, Float_t h); - - void AddHexagon(Float_t a, Float_t b, Float_t z, Float_t r); - - // Wrappers to make transition to DigitSet as base easier - void QuadValue(Int_t value) { DigitValue(value); } - void QuadColor(Color_t ci) { DigitColor(ci); } - void QuadColor(UChar_t r, UChar_t g, UChar_t b, UChar_t a=255) { DigitColor(r, g, b, a); } - void QuadId(TObject* id) { DigitId(id); } - - // -------------------------------- - - // void Test(Int_t nquads); - - virtual void ComputeBBox(); - - // virtual void Paint(Option_t* option=""); - - ClassDef(QuadSet, 1); -}; - -} // namespace Reve - -#endif diff --git a/EVE/Reve/QuadSetGL.cxx b/EVE/Reve/QuadSetGL.cxx deleted file mode 100644 index e8334fc2522..00000000000 --- a/EVE/Reve/QuadSetGL.cxx +++ /dev/null @@ -1,591 +0,0 @@ -/************************************************************************** - * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * - * * - * Author: The ALICE Off-line Project. * - * Contributors are mentioned in the code where appropriate. * - * * - * Permission to use, copy, modify and distribute this software and its * - * documentation strictly for non-commercial purposes is hereby granted * - * without fee, provided that the above copyright notice appears in all * - * copies and that both the copyright notice and this permission notice * - * appear in the supporting documentation. The authors make no claims * - * about the suitability of this software for any purpose. It is * - * provided "as is" without express or implied warranty. * - **************************************************************************/ - -/* $Id$ */ - -#include - -#include "QuadSetGL.h" -#include - -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// OldQuadSetGL -// - -ClassImp(OldQuadSetGL) - -/**************************************************************************/ - -OldQuadSetGL::OldQuadSetGL() : TGLObject() -{ - // fDLCache = false; // Disable DL. -} - -OldQuadSetGL::~OldQuadSetGL() -{} - -/**************************************************************************/ - -Bool_t OldQuadSetGL::SetModel(TObject* obj, const Option_t* /*opt*/) -{ - return SetModelCheckClass(obj, Reve::OldQuadSet::Class()); -} - -void OldQuadSetGL::SetBBox() -{ - SetAxisAlignedBBox(((OldQuadSet*)fExternalObj)->AssertBBox()); -} - -/**************************************************************************/ - -void OldQuadSetGL::DirectDraw(TGLRnrCtx & /*rnrCtx*/) const -{ - // printf("OldQuadSetGLRenderer::DirectDraw Style %d, LOD %d\n", rnrCtx.Style(), rnrCtx.LOD()); - - OldQuadSet& Q = * (OldQuadSet*) fExternalObj; - - glPushAttrib(GL_ENABLE_BIT | GL_POLYGON_BIT); - - glDisable(GL_LIGHTING); - glColorMaterial(GL_FRONT_AND_BACK, GL_DIFFUSE); - glEnable(GL_COLOR_MATERIAL); - glPolygonMode(GL_FRONT, GL_LINE); - glPolygonMode(GL_BACK, GL_LINE); - glDisable(GL_CULL_FACE); - - Float_t c[4]; glGetFloatv(GL_CURRENT_COLOR, c); - // UChar_t alpha = (UChar_t)(255*c[3]); - - glBegin(GL_QUADS); - for(std::vector::iterator q=Q.fQuads.begin(); q!=Q.fQuads.end(); ++q) { - UChar_t* c = (UChar_t*) &q->color; - //glColor4ub(c[0], c[1], c[2], (c[3]*alpha) >> 8); - glColor3ub(c[0], c[1], c[2]); - glVertex3fv(q->vertices); - glVertex3fv(q->vertices + 3); - glVertex3fv(q->vertices + 6); - glVertex3fv(q->vertices + 9); - } - glEnd(); - - glPopAttrib(); -} - - -/**************************************************************************/ -/**************************************************************************/ -/**************************************************************************/ -/**************************************************************************/ - -//______________________________________________________________________ -// QuadSetGL -// - -ClassImp(QuadSetGL) - -/**************************************************************************/ - -QuadSetGL::QuadSetGL() : TGLObject(), fM(0) -{ - // fDLCache = false; // Disable DL. -} - -QuadSetGL::~QuadSetGL() -{} - -/**************************************************************************/ - -Bool_t QuadSetGL::ShouldDLCache(const TGLRnrCtx & rnrCtx) const -{ - if (rnrCtx.DrawPass() == TGLRnrCtx::kPassOutlineLine) - return kFALSE; - return TGLObject::ShouldDLCache(rnrCtx); -} - -/**************************************************************************/ - -Bool_t QuadSetGL::SetModel(TObject* obj, const Option_t* /*opt*/) -{ - Bool_t ok = SetModelCheckClass(obj, Reve::QuadSet::Class()); - fM = ok ? dynamic_cast(obj) : 0; - return ok; -} - -void QuadSetGL::SetBBox() -{ - SetAxisAlignedBBox(fM->AssertBBox()); -} - -/**************************************************************************/ - -inline Bool_t QuadSetGL::SetupColor(const DigitSet::DigitBase& q) const -{ - if (fM->fValueIsColor) - { - glColor4ubv((UChar_t*) & q.fValue); - return kTRUE; - } - else - { - UChar_t c[4]; - Bool_t visible = fM->fPalette->ColorFromValue(q.fValue, fM->fDefaultValue, c); - if (visible) - glColor4ubv(c); - return visible; - } -} - -/**************************************************************************/ - -void QuadSetGL::DirectDraw(TGLRnrCtx & rnrCtx) const -{ - static const Exc_t eH("QuadSetGL::DirectDraw "); - - // printf("QuadSetGLRenderer::DirectDraw Style %d, LOD %d\n", rnrCtx.Style(), rnrCtx.LOD()); - - if (rnrCtx.DrawPass() == TGLRnrCtx::kPassOutlineLine) - return; - - QuadSet& mQ = * fM; - - if (mQ.fFrame != 0 && ! rnrCtx.SecSelection()) - FrameBoxGL::Render(mQ.fFrame); - - if (mQ.fPlex.Size() == 0) - return; - if ( ! mQ.fValueIsColor && mQ.fPalette == 0) - { - mQ.AssertPalette(); - } - - glPushAttrib(GL_ENABLE_BIT | GL_POLYGON_BIT); - glColorMaterial(GL_FRONT_AND_BACK, GL_DIFFUSE); - glEnable(GL_COLOR_MATERIAL); - glDisable(GL_CULL_FACE); - - if (mQ.fRenderMode == DigitSet::RM_Fill) - glPolygonMode(GL_FRONT_AND_BACK, GL_FILL); - else if (mQ.fRenderMode == DigitSet::RM_Line) - glPolygonMode(GL_FRONT_AND_BACK, GL_LINE); - - if (mQ.fDisableLigting) glDisable(GL_LIGHTING); - - if (mQ.fQuadType < QuadSet::QT_Rectangle_End) RenderQuads(rnrCtx); - else if (mQ.fQuadType < QuadSet::QT_Line_End) RenderLines(rnrCtx); - else if (mQ.fQuadType < QuadSet::QT_Hexagon_End) RenderHexagons(rnrCtx); - - glPopAttrib(); - -} - - -void QuadSetGL::RenderQuads(TGLRnrCtx & rnrCtx) const -{ - static const Exc_t eH("QuadSetGL::RenderQuads "); - - QuadSet& mQ = * fM; - - GLenum primitiveType; - if (mQ.fRenderMode != DigitSet::RM_Line) - { - primitiveType = GL_QUADS; - if (mQ.fQuadType == QuadSet::QT_FreeQuad) - glEnable(GL_NORMALIZE); - else - glNormal3f(0, 0, 1); - } else { - primitiveType = GL_LINE_LOOP; - } - - VoidCPlex::iterator qi(mQ.fPlex); - - if (rnrCtx.SecSelection()) glPushName(0); - - switch (mQ.fQuadType) - { - - case QuadSet::QT_FreeQuad: - { - Float_t e1[3], e2[3], normal[3]; - while (qi.next()) { - QuadSet::QFreeQuad& q = * (QuadSet::QFreeQuad*) qi(); - if (SetupColor(q)) - { - Float_t* p = q.fVertices; - e1[0] = p[3] - p[0]; e1[1] = p[4] - p[1]; e1[2] = p[5] - p[2]; - e2[0] = p[6] - p[0]; e2[1] = p[7] - p[1]; e2[2] = p[8] - p[2]; - TMath::Cross(e1, e2, normal); - if (rnrCtx.SecSelection()) glLoadName(qi.index()); - glBegin(primitiveType); - glNormal3fv(normal); - glVertex3fv(p); - glVertex3fv(p + 3); - glVertex3fv(p + 6); - glVertex3fv(p + 9); - glEnd(); - } - } - break; - } - - case QuadSet::QT_RectangleXY: - { - while (qi.next()) { - QuadSet::QRect& q = * (QuadSet::QRect*) qi(); - if (SetupColor(q)) - { - if (rnrCtx.SecSelection()) glLoadName(qi.index()); - glBegin(primitiveType); - glVertex3f(q.fA, q.fB, q.fC); - glVertex3f(q.fA + q.fW, q.fB, q.fC); - glVertex3f(q.fA + q.fW, q.fB + q.fH, q.fC); - glVertex3f(q.fA, q.fB + q.fH, q.fC); - glEnd(); - } - } - break; - } - - case QuadSet::QT_RectangleXZ: - { - while (qi.next()) { - QuadSet::QRect& q = * (QuadSet::QRect*) qi(); - if (SetupColor(q)) - { - if (rnrCtx.SecSelection()) glLoadName(qi.index()); - glBegin(primitiveType); - glVertex3f(q.fA, q.fC, q.fB); - glVertex3f(q.fA + q.fW, q.fC, q.fB); - glVertex3f(q.fA + q.fW, q.fC, q.fB + q.fH); - glVertex3f(q.fA, q.fC, q.fB + q.fH); - glEnd(); - } - } - break; - } - - case QuadSet::QT_RectangleYZ: - { - while (qi.next()) { - QuadSet::QRect& q = * (QuadSet::QRect*) qi(); - if (SetupColor(q)) - { - if (rnrCtx.SecSelection()) glLoadName(qi.index()); - glBegin(primitiveType); - glVertex3f(q.fC, q.fA, q.fB); - glVertex3f(q.fC, q.fA + q.fW, q.fB); - glVertex3f(q.fC, q.fA + q.fW, q.fB + q.fH); - glVertex3f(q.fC, q.fA, q.fB + q.fH); - glEnd(); - } - } - break; - } - - case QuadSet::QT_RectangleXYFixedDim: - { - const Float_t& w = mQ.fDefWidth; - const Float_t& h = mQ.fDefHeight; - while (qi.next()) { - QuadSet::QRectFixDim& q = * (QuadSet::QRectFixDim*) qi(); - if (SetupColor(q)) - { - if (rnrCtx.SecSelection()) glLoadName(qi.index()); - glBegin(primitiveType); - glVertex3f(q.fA, q.fB, q.fC); - glVertex3f(q.fA + w, q.fB, q.fC); - glVertex3f(q.fA + w, q.fB + h, q.fC); - glVertex3f(q.fA, q.fB + h, q.fC); - glEnd(); - } - } - break; - } - - case QuadSet::QT_RectangleXYFixedZ: - { - const Float_t& z = mQ.fDefCoord; - while (qi.next()) { - QuadSet::QRectFixC& q = * (QuadSet::QRectFixC*) qi(); - if (SetupColor(q)) - { - if (rnrCtx.SecSelection()) glLoadName(qi.index()); - glBegin(primitiveType); - glVertex3f(q.fA, q.fB, z); - glVertex3f(q.fA + q.fW, q.fB, z); - glVertex3f(q.fA + q.fW, q.fB + q.fH, z); - glVertex3f(q.fA, q.fB + q.fH, z); - glEnd(); - } - } - break; - } - - case QuadSet::QT_RectangleXZFixedY: - { - const Float_t& y = mQ.fDefCoord; - while (qi.next()) { - QuadSet::QRectFixC& q = * (QuadSet::QRectFixC*) qi(); - if (SetupColor(q)) - { - if (rnrCtx.SecSelection()) glLoadName(qi.index()); - glBegin(primitiveType); - glVertex3f(q.fA, y, q.fB); - glVertex3f(q.fA + q.fW, y, q.fB); - glVertex3f(q.fA + q.fW, y, q.fB + q.fH); - glVertex3f(q.fA, y, q.fB + q.fH); - glEnd(); - } - } - break; - } - - case QuadSet::QT_RectangleYZFixedX: - { - const Float_t& x = mQ.fDefCoord; - while (qi.next()) { - QuadSet::QRectFixC& q = * (QuadSet::QRectFixC*) qi(); - if (SetupColor(q)) - { - if (rnrCtx.SecSelection()) glLoadName(qi.index()); - glBegin(primitiveType); - glVertex3f(x, q.fA, q.fB); - glVertex3f(x, q.fA + q.fW, q.fB); - glVertex3f(x, q.fA + q.fW, q.fB + q.fH); - glVertex3f(x, q.fA, q.fB + q.fH); - glEnd(); - } - } - break; - } - - case QuadSet::QT_RectangleXYFixedDimZ: - { - const Float_t& z = mQ.fDefCoord; - const Float_t& w = mQ.fDefWidth; - const Float_t& h = mQ.fDefHeight; - while (qi.next()) { - QuadSet::QRectFixDimC& q = * (QuadSet::QRectFixDimC*) qi(); - if (SetupColor(q)) - { - if (rnrCtx.SecSelection()) glLoadName(qi.index()); - glBegin(primitiveType); - glVertex3f(q.fA, q.fB, z); - glVertex3f(q.fA + w, q.fB, z); - glVertex3f(q.fA + w, q.fB + h, z); - glVertex3f(q.fA, q.fB + h, z); - glEnd(); - } - } - break; - } - - case QuadSet::QT_RectangleXZFixedDimY: - { - const Float_t& y = mQ.fDefCoord; - const Float_t& w = mQ.fDefWidth; - const Float_t& h = mQ.fDefHeight; - while (qi.next()) { - QuadSet::QRectFixDimC& q = * (QuadSet::QRectFixDimC*) qi(); - if (SetupColor(q)) - { - if (rnrCtx.SecSelection()) glLoadName(qi.index()); - glBegin(primitiveType); - glVertex3f(q.fA, y, q.fB); - glVertex3f(q.fA + w, y, q.fB); - glVertex3f(q.fA + w, y, q.fB + h); - glVertex3f(q.fA, y, q.fB + h); - glEnd(); - } - } - break; - } - - case QuadSet::QT_RectangleYZFixedDimX: - { - const Float_t& x = mQ.fDefCoord; - const Float_t& w = mQ.fDefWidth; - const Float_t& h = mQ.fDefHeight; - while (qi.next()) { - QuadSet::QRectFixDimC& q = * (QuadSet::QRectFixDimC*) qi(); - if (SetupColor(q)) - { - if (rnrCtx.SecSelection()) glLoadName(qi.index()); - glBegin(primitiveType); - glVertex3f(x, q.fA, q.fB); - glVertex3f(x, q.fA + w, q.fB); - glVertex3f(x, q.fA + w, q.fB + h); - glVertex3f(x, q.fA, q.fB + h); - glEnd(); - } - } - break; - } - - default: - throw(eH + "unsupported quad-type."); - - } // end switch quad-type - - if (rnrCtx.SecSelection()) glPopName(); -} - - -void QuadSetGL::RenderLines(TGLRnrCtx & rnrCtx) const -{ - static const Exc_t eH("QuadSetGL::RenderLines "); - - QuadSet& mQ = * fM; - - VoidCPlex::iterator qi(mQ.fPlex); - - if (rnrCtx.SecSelection()) glPushName(0); - - switch (mQ.fQuadType) - { - - case QuadSet::QT_LineXYFixedZ: - { - const Float_t& z = mQ.fDefCoord; - while (qi.next()) { - QuadSet::QLineFixC& q = * (QuadSet::QLineFixC*) qi(); - if (SetupColor(q)) - { - if (rnrCtx.SecSelection()) glLoadName(qi.index()); - glBegin(GL_LINES); - glVertex3f(q.fA, q.fB, z); - glVertex3f(q.fA + q.fDx, q.fB + q.fDy, z); - glEnd(); - } - } - break; - } - - case QuadSet::QT_LineXZFixedY: - { - const Float_t& z = mQ.fDefCoord; - while (qi.next()) { - QuadSet::QLineFixC& q = * (QuadSet::QLineFixC*) qi(); - if (SetupColor(q)) - { - if (rnrCtx.SecSelection()) glLoadName(qi.index()); - glBegin(GL_LINES); - glVertex3f(q.fA, z, q.fB); - glVertex3f(q.fA + q.fDx, z, q.fB + q.fDy); - glEnd(); - } - } - break; - } - - default: - throw(eH + "unsupported quad-type."); - - } - - if (rnrCtx.SecSelection()) glPopName(); -} - -void QuadSetGL::RenderHexagons(TGLRnrCtx & rnrCtx) const -{ - static const Exc_t eH("QuadSetGL::RenderHexagons "); - - const Float_t sqr3hf = 0.5*TMath::Sqrt(3); - - QuadSet& mQ = * fM; - - GLenum primitveType = (mQ.fRenderMode != DigitSet::RM_Line) ? - GL_POLYGON : GL_LINE_LOOP; - - glNormal3f(0, 0, 1); - - VoidCPlex::iterator qi(mQ.fPlex); - - if (rnrCtx.SecSelection()) glPushName(0); - - switch (mQ.fQuadType) - { - - case QuadSet::QT_HexagonXY: - { - while (qi.next()) { - QuadSet::QHex& q = * (QuadSet::QHex*) qi(); - if (SetupColor(q)) - { - const Float_t rh = q.fR * 0.5; - const Float_t rs = q.fR * sqr3hf; - if (rnrCtx.SecSelection()) glLoadName(qi.index()); - glBegin(primitveType); - glVertex3f( q.fR + q.fA, q.fB, q.fC); - glVertex3f( rh + q.fA, rs + q.fB, q.fC); - glVertex3f( -rh + q.fA, rs + q.fB, q.fC); - glVertex3f(-q.fR + q.fA, q.fB, q.fC); - glVertex3f( -rh + q.fA, -rs + q.fB, q.fC); - glVertex3f( rh + q.fA, -rs + q.fB, q.fC); - glEnd(); - } - } - break; - } - - case QuadSet::QT_HexagonYX: - { - while (qi.next()) { - QuadSet::QHex& q = * (QuadSet::QHex*) qi(); - if (SetupColor(q)) - { - const Float_t rh = q.fR * 0.5; - const Float_t rs = q.fR * sqr3hf; - if (rnrCtx.SecSelection()) glLoadName(qi.index()); - glBegin(primitveType); - glVertex3f( rs + q.fA, rh + q.fB, q.fC); - glVertex3f( q.fA, q.fR + q.fB, q.fC); - glVertex3f(-rs + q.fA, rh + q.fB, q.fC); - glVertex3f(-rs + q.fA, -rh + q.fB, q.fC); - glVertex3f( q.fA, -q.fR + q.fB, q.fC); - glVertex3f( rs + q.fA, -rh + q.fB, q.fC); - glEnd(); - } - } - break; - } - - default: - throw(eH + "unsupported quad-type."); - - } // end switch quad-type - - if (rnrCtx.SecSelection()) glPopName(); -} - -/**************************************************************************/ -/**************************************************************************/ - -//______________________________________________________________________________ -void QuadSetGL::ProcessSelection(TGLRnrCtx & /*rnrCtx*/, TGLSelectRecord & rec) -{ - // Processes secondary selection from TGLViewer. - // Calls TPointSet3D::PointSelected(Int_t) with index of selected - // point as an argument. - - if (rec.GetN() < 2) return; - fM->DigitSelected(rec.GetItem(1)); -} diff --git a/EVE/Reve/QuadSetGL.h b/EVE/Reve/QuadSetGL.h deleted file mode 100644 index d040307f30a..00000000000 --- a/EVE/Reve/QuadSetGL.h +++ /dev/null @@ -1,64 +0,0 @@ -// $Header$ - -#ifndef REVE_QuadSetGL_H -#define REVE_QuadSetGL_H - -#include -#include - -namespace Reve { - -class OldQuadSetGL : public TGLObject -{ -protected: - virtual void DirectDraw(TGLRnrCtx & rnrCtx) const; - -public: - OldQuadSetGL(); - virtual ~OldQuadSetGL(); - - virtual Bool_t SetModel(TObject* obj, const Option_t* opt=0); - virtual void SetBBox(); - - ClassDef(OldQuadSetGL, 0); -}; - -/**************************************************************************/ -/**************************************************************************/ - -class QuadSetGL : public TGLObject -{ - QuadSetGL(const QuadSetGL&); // Not implemented - QuadSetGL& operator=(const QuadSetGL&); // Not implemented - -protected: - QuadSet* fM; - - virtual void DirectDraw(TGLRnrCtx & rnrCtx) const; - - Bool_t SetupColor(const DigitSet::DigitBase& q) const; - - void RenderQuads(TGLRnrCtx & rnrCtx) const; - void RenderLines(TGLRnrCtx & rnrCtx) const; - void RenderHexagons(TGLRnrCtx & rnrCtx) const; - -public: - QuadSetGL(); - virtual ~QuadSetGL(); - - virtual Bool_t ShouldDLCache(const TGLRnrCtx & rnrCtx) const; - - virtual Bool_t SetModel(TObject* obj, const Option_t* opt=0); - virtual void SetBBox(); - - virtual Bool_t IgnoreSizeForOfInterest() const { return kTRUE; } - - virtual Bool_t SupportsSecondarySelect() const { return kTRUE; } - virtual void ProcessSelection(TGLRnrCtx & rnrCtx, TGLSelectRecord & rec); - - ClassDef(QuadSetGL, 0); -}; - -} - -#endif diff --git a/EVE/Reve/RGBAPalette.cxx b/EVE/Reve/RGBAPalette.cxx deleted file mode 100644 index e33d39f5730..00000000000 --- a/EVE/Reve/RGBAPalette.cxx +++ /dev/null @@ -1,235 +0,0 @@ -// $Header$ - -#include "RGBAPalette.h" - -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// RGBAPalette -// - -ClassImp(RGBAPalette) - -RGBAPalette::RGBAPalette() : - TObject(), - Reve::ReferenceCount(), - - fLowLimit(0), fHighLimit(0), fMinVal(0), fMaxVal(0), fNBins(0), - - fInterpolate (kFALSE), - fShowDefValue (kTRUE), - fUnderflowAction (LA_Cut), - fOverflowAction (LA_Clip), - - fDefaultColor(0), - fUnderColor (1), - fOverColor (2), - fColorArray (0) -{ - SetLimits(0, 1024); - SetMinMax(0, 512); -} - -RGBAPalette::RGBAPalette(Int_t min, Int_t max, Bool_t interp, Bool_t showdef) : - TObject(), - Reve::ReferenceCount(), - - fLowLimit(0), fHighLimit(0), fMinVal(0), fMaxVal(0), fNBins(0), - - fInterpolate (interp), - fShowDefValue (showdef), - fUnderflowAction (LA_Cut), - fOverflowAction (LA_Clip), - - fDefaultColor(0), - fUnderColor (1), - fOverColor (2), - fColorArray (0) -{ - SetLimits(min, max); - SetMinMax(min, max); -} - -RGBAPalette::~RGBAPalette() -{ - delete [] fColorArray; -} - -/**************************************************************************/ - -void RGBAPalette::SetupColor(Int_t val, UChar_t* pixel) const -{ - using namespace TMath; - Float_t div = Max(1, fMaxVal - fMinVal); - Int_t nCol = gStyle->GetNumberOfColors(); - - Float_t f; - if (val >= fMaxVal) f = nCol - 1; - else if (val <= fMinVal) f = 0; - else f = (val - fMinVal)/div*(nCol - 1); - - if (fInterpolate) { - Int_t bin = (Int_t) f; - Float_t f1 = f - bin, f2 = 1.0f - f1; - ColorFromIdx(f1, gStyle->GetColorPalette(bin), - f2, gStyle->GetColorPalette(Min(bin + 1, nCol - 1)), - pixel); - } else { - ColorFromIdx(gStyle->GetColorPalette((Int_t) Nint(f)), pixel); - } -} - -void RGBAPalette::SetupColorArray() const -{ - if(fColorArray) // !!!! should reinit anyway, maybe palette in gstyle changed - return; - - // !!!! probably should store original palette for editing ... - - fColorArray = new UChar_t [4 * fNBins]; - UChar_t* p = fColorArray; - for(Int_t v=fMinVal; v<=fMaxVal; ++v, p+=4) - SetupColor(v, p); -} - -void RGBAPalette::ClearColorArray() -{ - if(fColorArray) { - delete [] fColorArray; - fColorArray = 0; - } -} - -/**************************************************************************/ - -void RGBAPalette::SetLimits(Int_t low, Int_t high) -{ - fLowLimit = low; - fHighLimit = high; - Bool_t changed = kFALSE; - if (fMaxVal < fLowLimit) { SetMax(fLowLimit); changed = kTRUE; } - if (fMinVal < fLowLimit) { SetMin(fLowLimit); changed = kTRUE; } - if (fMinVal > fHighLimit) { SetMin(fHighLimit); changed = kTRUE; } - if (fMaxVal > fHighLimit) { SetMax(fHighLimit); changed = kTRUE; } - if (changed) - ClearColorArray(); -} - -void RGBAPalette::SetLimitsScaleMinMax(Int_t low, Int_t high) -{ - Float_t rng_old = fHighLimit - fLowLimit; - Float_t rng_new = high - low; - - fMinVal = TMath::Nint(low + (fMinVal - fLowLimit)*rng_new/rng_old); - fMaxVal = TMath::Nint(low + (fMaxVal - fLowLimit)*rng_new/rng_old); - fLowLimit = low; - fHighLimit = high; - - fNBins = fMaxVal - fMinVal + 1; - ClearColorArray(); -} - -void RGBAPalette::SetMin(Int_t min) -{ - fMinVal = TMath::Min(min, fMaxVal); - fNBins = fMaxVal - fMinVal + 1; - ClearColorArray(); -} - -void RGBAPalette::SetMax(Int_t max) -{ - fMaxVal = TMath::Max(max, fMinVal); - fNBins = fMaxVal - fMinVal + 1; - ClearColorArray(); -} - -void RGBAPalette::SetMinMax(Int_t min, Int_t max) -{ - fMinVal = min; - fMaxVal = max; - fNBins = fMaxVal - fMinVal + 1; - ClearColorArray(); -} - -/**************************************************************************/ -/**************************************************************************/ - -void RGBAPalette::SetInterpolate(Bool_t b) -{ - fInterpolate = b; - ClearColorArray(); -} - -/**************************************************************************/ -/**************************************************************************/ - -void RGBAPalette::SetDefaultColor(Color_t ci) -{ - fDefaultColor = ci; - ColorFromIdx(ci, fDefaultRGBA, kTRUE); -} - -void RGBAPalette::SetDefaultColor(Pixel_t pix) -{ - SetDefaultColor(Color_t(TColor::GetColor(pix))); -} - -void RGBAPalette::SetDefaultColor(UChar_t r, UChar_t g, UChar_t b, UChar_t a) -{ - fDefaultColor = Color_t(TColor::GetColor(r, g, b)); - fDefaultRGBA[0] = r; - fDefaultRGBA[1] = g; - fDefaultRGBA[2] = b; - fDefaultRGBA[3] = a; -} - -/**************************************************************************/ - -void RGBAPalette::SetUnderColor(Color_t ci) -{ - fUnderColor = ci; - ColorFromIdx(ci, fUnderRGBA, kTRUE); -} - -void RGBAPalette::SetUnderColor(Pixel_t pix) -{ - SetUnderColor(Color_t(TColor::GetColor(pix))); -} - -void RGBAPalette::SetUnderColor(UChar_t r, UChar_t g, UChar_t b, UChar_t a) -{ - fUnderColor = Color_t(TColor::GetColor(r, g, b)); - fUnderRGBA[0] = r; - fUnderRGBA[1] = g; - fUnderRGBA[2] = b; - fUnderRGBA[3] = a; -} - -/**************************************************************************/ - -void RGBAPalette::SetOverColor(Color_t ci) -{ - fOverColor = ci; - ColorFromIdx(ci, fOverRGBA, kTRUE); -} - -void RGBAPalette::SetOverColor(Pixel_t pix) -{ - SetOverColor(Color_t(TColor::GetColor(pix))); -} - -void RGBAPalette::SetOverColor(UChar_t r, UChar_t g, UChar_t b, UChar_t a) -{ - fOverColor = Color_t(TColor::GetColor(r, g, b)); - fOverRGBA[0] = r; - fOverRGBA[1] = g; - fOverRGBA[2] = b; - fOverRGBA[3] = a; -} - -/**************************************************************************/ -/**************************************************************************/ diff --git a/EVE/Reve/RGBAPalette.h b/EVE/Reve/RGBAPalette.h deleted file mode 100644 index 7e1ffc1ccf3..00000000000 --- a/EVE/Reve/RGBAPalette.h +++ /dev/null @@ -1,198 +0,0 @@ -// $Header$ - -#ifndef REVE_RGBAPalette_H -#define REVE_RGBAPalette_H - -#include - -#include - -namespace Reve { - -class RGBAPalette : public TObject, public ReferenceCount -{ - friend class RGBAPaletteEditor; - friend class RGBAPaletteSubEditor; - -public: - enum LimitAction_e { LA_Cut, LA_Mark, LA_Clip, LA_Wrap }; - -private: - RGBAPalette(const RGBAPalette&); // Not implemented - RGBAPalette& operator=(const RGBAPalette&); // Not implemented - -protected: - Int_t fLowLimit; // Low limit for Min/Max values (used by editor) - Int_t fHighLimit; // High limit for Min/Max values (used by editor) - Int_t fMinVal; - Int_t fMaxVal; - Int_t fNBins; - - Bool_t fInterpolate; - Bool_t fShowDefValue; - Int_t fUnderflowAction; - Int_t fOverflowAction; - - Color_t fDefaultColor; // Color for when value is not specified - UChar_t fDefaultRGBA[4]; - Color_t fUnderColor; // Underflow color - UChar_t fUnderRGBA[4]; - Color_t fOverColor; // Overflow color - UChar_t fOverRGBA[4]; - - mutable UChar_t* fColorArray; //[4*fNBins] - - void SetupColor(Int_t val, UChar_t* pix) const; - - static RGBAPalette* fgDefaultPalette; - -public: - RGBAPalette(); - RGBAPalette(Int_t min, Int_t max, Bool_t interp=kFALSE, Bool_t showdef=kTRUE); - virtual ~RGBAPalette(); - - void SetupColorArray() const; - void ClearColorArray(); - - Bool_t WithinVisibleRange(Int_t val) const; - const UChar_t* ColorFromValue(Int_t val) const; - void ColorFromValue(Int_t val, UChar_t* pix, Bool_t alpha=kTRUE) const; - Bool_t ColorFromValue(Int_t val, Int_t defVal, UChar_t* pix, Bool_t alpha=kTRUE) const; - - Int_t GetMinVal() const { return fMinVal; } - Int_t GetMaxVal() const { return fMaxVal; } - - void SetLimits(Int_t low, Int_t high); - void SetLimitsScaleMinMax(Int_t low, Int_t high); - void SetMinMax(Int_t min, Int_t max); - void SetMin(Int_t min); - void SetMax(Int_t max); - - Int_t GetLowLimit() const { return fLowLimit; } - Int_t GetHighLimit() const { return fHighLimit; } - - // ================================================================ - - Bool_t GetInterpolate() const { return fInterpolate; } - void SetInterpolate(Bool_t b); - - Bool_t GetShowDefValue() const { return fShowDefValue; } - void SetShowDefValue(Bool_t v) { fShowDefValue = v; } - - Int_t GetUnderflowAction() const { return fUnderflowAction; } - Int_t GetOverflowAction() const { return fOverflowAction; } - void SetUnderflowAction(Int_t a) { fUnderflowAction = a; } - void SetOverflowAction(Int_t a) { fOverflowAction = a; } - - // ================================================================ - - Color_t GetDefaultColor() const { return fDefaultColor; } - Color_t* PtrDefaultColor() { return &fDefaultColor; } - UChar_t* GetDefaultRGBA() { return fDefaultRGBA; } - const UChar_t* GetDefaultRGBA() const { return fDefaultRGBA; } - - void SetDefaultColor(Color_t ci); - void SetDefaultColor(Pixel_t pix); - void SetDefaultColor(UChar_t r, UChar_t g, UChar_t b, UChar_t a=255); - - // ---------------------------------------------------------------- - - Color_t GetUnderColor() const { return fUnderColor; } - Color_t* PtrUnderColor() { return &fUnderColor; } - UChar_t* GetUnderRGBA() { return fUnderRGBA; } - const UChar_t* GetUnderRGBA() const { return fUnderRGBA; } - - void SetUnderColor(Color_t ci); - void SetUnderColor(Pixel_t pix); - void SetUnderColor(UChar_t r, UChar_t g, UChar_t b, UChar_t a=255); - - // ---------------------------------------------------------------- - - Color_t GetOverColor() const { return fOverColor; } - Color_t* PtrOverColor() { return &fOverColor; } - UChar_t* GetOverRGBA() { return fOverRGBA; } - const UChar_t* GetOverRGBA() const { return fOverRGBA; } - - void SetOverColor(Color_t ci); - void SetOverColor(Pixel_t pix); - void SetOverColor(UChar_t r, UChar_t g, UChar_t b, UChar_t a=255); - - // ================================================================ - - // ?? Should we emit some *SIGNALS* ?? - // ?? Should we have a RendererTimeStamp ?? - - ClassDef(RGBAPalette, 1); // A generic mapping from value to RGBA color. -}; // endclass RGBAPalette - - -/**************************************************************************/ -// Inlines for RGBAPalette -/**************************************************************************/ - -inline Bool_t RGBAPalette::WithinVisibleRange(Int_t val) const -{ - if ((val < fMinVal && fUnderflowAction == LA_Cut) || - (val > fMaxVal && fOverflowAction == LA_Cut)) - return kFALSE; - else - return kTRUE; -} - -inline const UChar_t* RGBAPalette::ColorFromValue(Int_t val) const -{ - // Here we expect that LA_Cut has been checked; we further check - // for LA_Wrap and LA_Clip otherwise we proceed as for LA_Mark. - - if (!fColorArray) SetupColorArray(); - if (val < fMinVal) { - if (fUnderflowAction == LA_Wrap) - val = (val+1-fMinVal)%fNBins + fMaxVal; - else if (fUnderflowAction == LA_Clip) - val = fMinVal; - else - return fUnderRGBA; - } - else if(val > fMaxVal) { - if (fOverflowAction == LA_Wrap) - val = (val-1-fMaxVal)%fNBins + fMinVal; - else if (fOverflowAction == LA_Clip) - val = fMaxVal; - else - return fOverRGBA; - } - return fColorArray + 4 * (val - fMinVal); -} - -inline void RGBAPalette::ColorFromValue(Int_t val, UChar_t* pix, Bool_t alpha) const -{ - const UChar_t* c = ColorFromValue(val); - pix[0] = c[0]; pix[1] = c[1]; pix[2] = c[2]; - if (alpha) pix[3] = c[3]; -} - -inline Bool_t RGBAPalette::ColorFromValue(Int_t val, Int_t defVal, UChar_t* pix, Bool_t alpha) const -{ - if (val == defVal) { - if (fShowDefValue) { - pix[0] = fDefaultRGBA[0]; - pix[1] = fDefaultRGBA[1]; - pix[2] = fDefaultRGBA[2]; - if (alpha) pix[3] = fDefaultRGBA[3]; - return kTRUE; - } else { - return kFALSE; - } - } - - if (WithinVisibleRange(val)) { - ColorFromValue(val, pix, alpha); - return kTRUE; - } else { - return kFALSE; - } -} - -} - -#endif diff --git a/EVE/Reve/RGBAPaletteEditor.cxx b/EVE/Reve/RGBAPaletteEditor.cxx deleted file mode 100644 index 08280c090c4..00000000000 --- a/EVE/Reve/RGBAPaletteEditor.cxx +++ /dev/null @@ -1,237 +0,0 @@ -// $Header$ - -#include "RGBAPaletteEditor.h" -#include -#include - -#include -#include - -#include -#include -#include -#include -#include -#include - -using namespace Reve; - - -RGBAPaletteSubEditor::RGBAPaletteSubEditor(const TGWindow* p) : - TGVerticalFrame(p), - - fM(0), - - fUnderflowAction (0), - fUnderColor (0), - fOverflowAction (0), - fOverColor (0), - - fMinMax(0), - - fInterpolate(0), - fShowDefValue(0), - fDefaultColor(0) -{ - // Int_t labelW = 42; - - { - TGHorizontalFrame* f = new TGHorizontalFrame(this); - - fInterpolate = new TGCheckButton(f, "Interpolate"); - f->AddFrame(fInterpolate, new TGLayoutHints(kLHintsLeft, 3, 1, 1, 0)); - fInterpolate->Connect("Toggled(Bool_t)", - "Reve::RGBAPaletteSubEditor", this, "DoInterpolate()"); - - AddFrame(f, new TGLayoutHints(kLHintsTop, 1, 1, 1, 0)); - } - - { - TGHorizontalFrame* f = new TGHorizontalFrame(this); - - fShowDefValue = new TGCheckButton(f, "Show default value"); - f->AddFrame(fShowDefValue, new TGLayoutHints(kLHintsLeft, 3, 1, 1, 0)); - fShowDefValue->Connect("Toggled(Bool_t)", - "Reve::RGBAPaletteSubEditor", this, "DoShowDefValue()"); - - fDefaultColor = new TGColorSelect(f, 0, -1); - f->AddFrame(fDefaultColor, new TGLayoutHints(kLHintsLeft|kLHintsTop, 3, 1, 0, 2)); - fDefaultColor->Connect("ColorSelected(Pixel_t)", - "Reve::RGBAPaletteSubEditor", this, "DoDefaultColor(Pixel_t)"); - - AddFrame(f, new TGLayoutHints(kLHintsTop, 1, 1, 1, 0)); - } - - { // Underflow - TGHorizontalFrame* f = new TGHorizontalFrame(this); - TGLabel* lab = new TGLabel(f, "Underflow:"); - f->AddFrame(lab, new TGLayoutHints(kLHintsLeft|kLHintsBottom, 1, 15, 1, 2)); - fUnderflowAction = new TGComboBox(f); - fUnderflowAction->AddEntry("Cut", 0); - fUnderflowAction->AddEntry("Mark", 1); - fUnderflowAction->AddEntry("Clip", 2); - fUnderflowAction->AddEntry("Wrap", 3); - TGListBox* lb = fUnderflowAction->GetListBox(); - lb->Resize(lb->GetWidth(), 4*16); - fUnderflowAction->Resize(59, 20); - fUnderflowAction->Connect("Selected(Int_t)", "Reve::RGBAPaletteSubEditor", this, - "DoUnderflowAction(Int_t)"); - f->AddFrame(fUnderflowAction, new TGLayoutHints(kLHintsLeft, 1, 2, 1, 1)); - - fUnderColor = new TGColorSelect(f, 0, -1); - f->AddFrame(fUnderColor, new TGLayoutHints(kLHintsLeft|kLHintsTop, 1, 1, 0, 2)); - fUnderColor->Connect("ColorSelected(Pixel_t)", - "Reve::RGBAPaletteSubEditor", this, "DoUnderColor(Pixel_t)"); - - AddFrame(f); - } - - { // Overflow - TGHorizontalFrame* f = new TGHorizontalFrame(this); - TGLabel* lab = new TGLabel(f, "Overflow:"); - f->AddFrame(lab, new TGLayoutHints(kLHintsLeft|kLHintsBottom, 1, 20, 1, 2)); - fOverflowAction = new TGComboBox(f); - fOverflowAction->AddEntry("Cut", 0); - fOverflowAction->AddEntry("Mark", 1); - fOverflowAction->AddEntry("Clip", 2); - fOverflowAction->AddEntry("Wrap", 3); - TGListBox* lb = fOverflowAction->GetListBox(); - lb->Resize(lb->GetWidth(), 4*16); - fOverflowAction->Resize(59, 20); - fOverflowAction->Connect("Selected(Int_t)", "Reve::RGBAPaletteSubEditor", this, - "DoOverflowAction(Int_t)"); - f->AddFrame(fOverflowAction, new TGLayoutHints(kLHintsLeft, 1, 2, 1, 1)); - - fOverColor = new TGColorSelect(f, 0, -1); - f->AddFrame(fOverColor, new TGLayoutHints(kLHintsLeft|kLHintsTop, 1, 1, 0, 2)); - fOverColor->Connect("ColorSelected(Pixel_t)", - "Reve::RGBAPaletteSubEditor", this, "DoOverColor(Pixel_t)"); - - AddFrame(f); - } - - fMinMax = new RGDoubleValuator(this,"Main range:", 200, 0); - fMinMax->SetNELength(5); - fMinMax->SetLabelWidth(74); - fMinMax->Build(); - fMinMax->GetSlider()->SetWidth(224); - fMinMax->SetLimits(0, 1023, TGNumberFormat::kNESInteger); - fMinMax->Connect("ValueSet()", - "Reve::RGBAPaletteSubEditor", this, "DoMinMax()"); - AddFrame(fMinMax, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - -} - -/**************************************************************************/ - -void RGBAPaletteSubEditor::SetModel(RGBAPalette* p) -{ - fM = p; - - fMinMax->SetValues(fM->fMinVal, fM->fMaxVal); - fMinMax->SetLimits(fM->fLowLimit, fM->fHighLimit); - - fInterpolate->SetState(fM->fInterpolate ? kButtonDown : kButtonUp); - fShowDefValue->SetState(fM->fShowDefValue ? kButtonDown : kButtonUp); - fDefaultColor->SetColor(TColor::Number2Pixel(fM->GetDefaultColor()), kFALSE); - - fUnderColor->SetColor(TColor::Number2Pixel(fM->GetUnderColor()), kFALSE); - fOverColor->SetColor(TColor::Number2Pixel(fM->GetOverColor()), kFALSE); - - fUnderflowAction->Select(fM->fUnderflowAction, kFALSE); - fOverflowAction->Select(fM->fOverflowAction, kFALSE); -} - -/**************************************************************************/ - -void RGBAPaletteSubEditor::Changed() -{ - Emit("Changed()"); -} - -/**************************************************************************/ - -void RGBAPaletteSubEditor::DoMinMax() -{ - fM->SetMinMax((Int_t) fMinMax->GetMin(), (Int_t) fMinMax->GetMax()); - Changed(); -} - -/**************************************************************************/ - -void RGBAPaletteSubEditor::DoInterpolate() -{ - fM->SetInterpolate(fInterpolate->IsOn()); - Changed(); -} - -void RGBAPaletteSubEditor::DoShowDefValue() -{ - fM->SetShowDefValue(fShowDefValue->IsOn()); - Changed(); -} - -void RGBAPaletteSubEditor::DoDefaultColor(Pixel_t color) -{ - fM->SetDefaultColor(color); - Changed(); -} - -void RGBAPaletteSubEditor::DoUnderColor(Pixel_t color) -{ - fM->SetUnderColor(color); - Changed(); -} - -void RGBAPaletteSubEditor::DoOverColor(Pixel_t color) -{ - fM->SetOverColor(color); - Changed(); -} - -void RGBAPaletteSubEditor::DoUnderflowAction(Int_t mode) -{ - fM->SetUnderflowAction(mode); - Changed(); -} - -void RGBAPaletteSubEditor::DoOverflowAction(Int_t mode) -{ - fM->SetOverflowAction(mode); - Changed(); -} - -/**************************************************************************/ -/**************************************************************************/ -/**************************************************************************/ -/**************************************************************************/ - -//______________________________________________________________________ -// RGBAPaletteEditor -// - -ClassImp(RGBAPaletteEditor) - -RGBAPaletteEditor::RGBAPaletteEditor(const TGWindow *p, Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - fM (0), - fSE(0) -{ - MakeTitle("RGBAPalette"); - - fSE = new RGBAPaletteSubEditor(this); - AddFrame(fSE, new TGLayoutHints(kLHintsTop, 2, 0, 2, 2)); - fSE->Connect("Changed()", "Reve::RGBAPaletteEditor", this, "Update()"); -} - -RGBAPaletteEditor::~RGBAPaletteEditor() -{} - -/**************************************************************************/ - -void RGBAPaletteEditor::SetModel(TObject* obj) -{ - fM = dynamic_cast(obj); - fSE->SetModel(fM); -} diff --git a/EVE/Reve/RGBAPaletteEditor.h b/EVE/Reve/RGBAPaletteEditor.h deleted file mode 100644 index 5a2b2a9c1f3..00000000000 --- a/EVE/Reve/RGBAPaletteEditor.h +++ /dev/null @@ -1,85 +0,0 @@ -// $Header$ - -#ifndef REVE_RGBAPaletteEditor_H -#define REVE_RGBAPaletteEditor_H - -#include - -class TGCheckButton; -class TGColorSelect; -class TGComboBox; - - -namespace Reve { - -class RGBAPalette; -class RGValuator; -class RGDoubleValuator; - -class RGBAPaletteSubEditor : public TGVerticalFrame -{ -private: - RGBAPaletteSubEditor(const RGBAPaletteSubEditor&); // Not implemented - RGBAPaletteSubEditor& operator=(const RGBAPaletteSubEditor&); // Not implemented - -protected: - RGBAPalette* fM; - - TGComboBox* fUnderflowAction; - TGColorSelect* fUnderColor; - TGComboBox* fOverflowAction; - TGColorSelect* fOverColor; - - RGDoubleValuator* fMinMax; - - TGCheckButton* fInterpolate; - TGCheckButton* fShowDefValue; - TGColorSelect* fDefaultColor; - -public: - RGBAPaletteSubEditor(const TGWindow* p); - virtual ~RGBAPaletteSubEditor() {} - - void SetModel(RGBAPalette* p); - - void Changed(); //*SIGNAL* - - void DoMinMax(); - - void DoInterpolate(); - void DoShowDefValue(); - void DoDefaultColor(Pixel_t color); - void DoUnderColor(Pixel_t color); - void DoOverColor(Pixel_t color); - void DoUnderflowAction(Int_t mode); - void DoOverflowAction(Int_t mode); - - ClassDef(RGBAPaletteSubEditor, 1); // Sub-editor for RGBAPalette class. -}; // endclass RGBAPaletteSubEditor - - -/**************************************************************************/ -/**************************************************************************/ - -class RGBAPaletteEditor : public TGedFrame -{ -private: - RGBAPaletteEditor(const RGBAPaletteEditor&); // Not implemented - RGBAPaletteEditor& operator=(const RGBAPaletteEditor&); // Not implemented - -protected: - RGBAPalette* fM; - RGBAPaletteSubEditor* fSE; - -public: - RGBAPaletteEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, UInt_t options = kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - virtual ~RGBAPaletteEditor(); - - virtual void SetModel(TObject* obj); - - ClassDef(RGBAPaletteEditor, 1); // Editor for RGBAPalette class. -}; // endclass RGBAPaletteEditor - -} - -#endif diff --git a/EVE/Reve/RGBrowser.cxx b/EVE/Reve/RGBrowser.cxx deleted file mode 100644 index f53e0625091..00000000000 --- a/EVE/Reve/RGBrowser.cxx +++ /dev/null @@ -1,559 +0,0 @@ -#include "RGBrowser.h" -#include "ReveManager.h" -#include "Reve.h" -#include "RGEditor.h" -#include "VSDSelector.h" -#include -#include - -#include "TGFileBrowser.h" -#include - -#include - -#include -#include -#include -#include -#include -#include - -#include -#include -#include - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include - -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// RGLTEFrame -// -// - -ClassImp(RGLTEFrame) - -RGLTEFrame::RGLTEFrame(const Text_t* name, Int_t width, Int_t height) : - TGMainFrame(gClient->GetRoot(), width, height), - fCtxMenu (0), - fNewSelected (0) -{ - SetWindowName(name); - SetCleanup(kNoCleanup); - - fFrame = new TGCompositeFrame(this, width, height, kVerticalFrame); - - // List-tree - fLTFrame = new TGCompositeFrame(fFrame, width, 3*height/7, kVerticalFrame); - fLTCanvas = new TGCanvas(fLTFrame, 10, 10, kSunkenFrame | kDoubleBorder); - fListTree = new TGListTree(fLTCanvas->GetViewPort(), 10, 10, kHorizontalFrame); - fListTree->SetCanvas(fLTCanvas); - fListTree->Associate(fFrame); - fListTree->SetColorMode(TGListTree::EColorMarkupMode(TGListTree::kColorUnderline | TGListTree::kColorBox)); - fListTree->SetAutoCheckBoxPic(kFALSE); - fLTCanvas->SetContainer(fListTree); - fLTFrame->AddFrame(fLTCanvas, new TGLayoutHints - (kLHintsNormal | kLHintsExpandX | kLHintsExpandY, 1, 1, 1, 1)); - fFrame ->AddFrame(fLTFrame, new TGLayoutHints - (kLHintsNormal | kLHintsExpandX | kLHintsExpandY)); - - // Splitter - fSplitter = new TGHSplitter(fFrame); - fFrame->AddFrame(fSplitter, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 1,1,2,2)); - - // Editor - fFrame->SetEditDisabled(kEditEnable); - fFrame->SetEditable(); - fEditor = new RGEditor(0, width, 4*height/7); - fEditor->SetGlobal(kFALSE); - fEditor->ChangeOptions(fEditor->GetOptions() | kFixedHeight); - fFrame->SetEditable(kEditDisable); - fFrame->SetEditable(kFALSE); - { - TGFrameElement *el = 0; - TIter next(fFrame->GetList()); - while ((el = (TGFrameElement *) next())) { - if (el->fFrame == fEditor) - if (el->fLayout) { - el->fLayout->SetLayoutHints(kLHintsTop | kLHintsExpandX); - el->fLayout->SetPadLeft(0); el->fLayout->SetPadRight(1); - el->fLayout->SetPadTop(2); el->fLayout->SetPadBottom(1); - break; - } - } - } - fSplitter->SetFrame(fEditor, kFALSE); - - AddFrame(fFrame, new TGLayoutHints(kLHintsNormal | kLHintsExpandX | kLHintsExpandY)); - - fCtxMenu = new TContextMenu("", ""); - - fListTree->Connect("Checked(TObject*,Bool_t)", "Reve::RGLTEFrame", - this, "ItemChecked(TObject*, Bool_t)"); - fListTree->Connect("Clicked(TGListTreeItem*, Int_t, Int_t, Int_t)", "Reve::RGLTEFrame", - this, "ItemClicked(TGListTreeItem*, Int_t, Int_t, Int_t)"); - fListTree->Connect("DoubleClicked(TGListTreeItem*, Int_t)", "Reve::RGLTEFrame", - this, "ItemDblClicked(TGListTreeItem*, Int_t)"); - fListTree->Connect("KeyPressed(TGListTreeItem*, ULong_t, ULong_t)", "Reve::RGLTEFrame", - this, "ItemKeyPress(TGListTreeItem*, UInt_t, UInt_t)"); - - Layout(); - MapSubwindows(); - MapWindow(); -} - -RGLTEFrame::~RGLTEFrame() -{ - delete fCtxMenu; - - // Should un-register editor, all items and list-tree from gReve ... eventually. - - delete fEditor; - delete fSplitter; - delete fListTree; - delete fLTCanvas; - delete fLTFrame; - delete fFrame; -} - -/**************************************************************************/ - -void RGLTEFrame::ReconfToHorizontal() -{ - UnmapWindow(); - - fFrame->ChangeOptions(kHorizontalFrame); - fLTFrame->ChangeOptions(kHorizontalFrame); - fListTree->ChangeOptions(kVerticalFrame); - - TGFrameElement *el = 0; - TIter next(fFrame->GetList()); - while ((el = (TGFrameElement *) next())) - { - if (el->fFrame == fSplitter) - { - delete fSplitter; - el->fFrame = fSplitter = new TGVSplitter(fFrame); - el->fLayout->SetLayoutHints(kLHintsLeft | kLHintsExpandY); - el->fLayout->SetPadLeft(2); el->fLayout->SetPadRight (2); - el->fLayout->SetPadTop (1); el->fLayout->SetPadBottom(1); - } - else if (el->fFrame == fEditor) - { - fEditor->ChangeOptions(fEditor->GetOptions() & (~kFixedHeight)); - fEditor->ChangeOptions(fEditor->GetOptions() | kFixedWidth); - el->fLayout->SetLayoutHints(kLHintsLeft | kLHintsExpandY); - } - } - - fEditor->Resize(fEditor->GetWidth() / 2 - 1, fEditor->GetHeight()); - fSplitter->SetFrame(fEditor, kFALSE); - - Layout(); - //fFrame->Layout(); - //fLTFrame->Layout(); - //fLTCanvas->Layout(); - //fListTree->ClearViewPort(); - MapSubwindows(); - MapWindow(); -} - -void RGLTEFrame::ReconfToVertical() -{ - UnmapWindow(); - - fFrame->ChangeOptions(kVerticalFrame); - fLTFrame->ChangeOptions(kVerticalFrame); - fListTree->ChangeOptions(kHorizontalFrame); - - TGFrameElement *el = 0; - TIter next(fFrame->GetList()); - while ((el = (TGFrameElement *) next())) - { - if (el->fFrame == fSplitter) - { - delete fSplitter; - el->fFrame = fSplitter = new TGHSplitter(fFrame); - el->fLayout->SetLayoutHints(kLHintsTop | kLHintsExpandX); - el->fLayout->SetPadLeft(2); el->fLayout->SetPadRight (2); - el->fLayout->SetPadTop (1); el->fLayout->SetPadBottom(1); - } - else if (el->fFrame == fEditor) - { - fEditor->ChangeOptions(fEditor->GetOptions() & (~kFixedWidth)); - fEditor->ChangeOptions(fEditor->GetOptions() | kFixedHeight); - el->fLayout->SetLayoutHints(kLHintsTop | kLHintsExpandX); - } - } - - fEditor->Resize(fEditor->GetWidth(), fEditor->GetHeight() / 2 - 1); - fSplitter->SetFrame(fEditor, kFALSE); - - Layout(); - //fFrame->Layout(); - //fLTFrame->Layout(); - //fLTCanvas->Layout(); - //fListTree->ClearViewPort(); - MapSubwindows(); - MapWindow(); -} - -/**************************************************************************/ - -void RGLTEFrame::ItemChecked(TObject* obj, Bool_t state) -{ - // Item's user-data is blindly casted into TObject. - // We recast it blindly back into the render element. - - RenderElement* rnrEl = (RenderElement*) obj; - gReve->RenderElementChecked(rnrEl, state); - gReve->Redraw3D(); -} - -void RGLTEFrame::ItemClicked(TGListTreeItem *item, Int_t btn, Int_t x, Int_t y) -{ - //printf("ItemClicked item %s List %d btn=%d, x=%d, y=%d\n", - // item->GetText(),fDisplayFrame->GetList()->GetEntries(), btn, x, y); - - RenderElement* re = (RenderElement*)item->GetUserData(); - if(re == 0) return; - TObject* obj = re->GetObject(); - - switch (btn) - { - case 1: - gReve->RenderElementSelect(re); - break; - - case 2: - if (gReve->RenderElementPaste(re)) - gReve->Redraw3D(); - break; - - case 3: - // If control pressed, show menu for render-element itself. - // event->fState & kKeyControlMask - // ??? how do i get current event? - if (obj) fCtxMenu->Popup(x, y, obj); - break; - - default: - break; - } -} - -void RGLTEFrame::ItemDblClicked(TGListTreeItem* item, Int_t btn) -{ - if (btn != 1) return; - - RenderElement* re = (RenderElement*) item->GetUserData(); - if (re == 0) return; - - re->ExpandIntoListTree(fListTree, item); - - TObject* obj = re->GetObject(); - if (obj) - { - // Browse geonodes. - if (obj->IsA()->InheritsFrom(TGeoNode::Class())) - { - TGeoNode* n = dynamic_cast(obj); - if (item->GetFirstChild() == 0 && n->GetNdaughters()) - { - fListTree->DeleteChildren(item); - for (Int_t i=0; i< n->GetNdaughters(); i++) - { - TString title; - title.Form("%d : %s[%d]", i, - n->GetDaughter(i)->GetVolume()->GetName(), - n->GetDaughter(i)->GetNdaughters()); - - TGListTreeItem* child = fListTree->AddItem( item, title.Data()); - child->SetUserData(n->GetDaughter(i)); - } - } - } - } -} - -void RGLTEFrame::ItemKeyPress(TGListTreeItem *entry, UInt_t keysym, UInt_t /*mask*/) -{ - static const Exc_t eH("RGLTEFrame::ItemKeyPress "); - - // replace entry with selected! - entry = fListTree->GetSelected(); - if (entry == 0) return; - - if (keysym == kKey_Delete) - { - RenderElement* rnr_el = dynamic_cast - ((RenderElement*) entry->GetUserData()); - if (rnr_el == 0) - return; - - if (entry->GetParent()) - { - if (rnr_el->GetDenyDestroy() > 0 && rnr_el->GetNItems() == 1) - throw(eH + "DestroyDenied set for this item."); - - RenderElement* parent_re = dynamic_cast - ((RenderElement*) entry->GetParent()->GetUserData()); - - if (parent_re) - { - ResetSelectedTimer(entry); - gReve->RemoveRenderElement(rnr_el, parent_re); - gReve->Redraw3D(); - } - } - else - { - if (rnr_el->GetDenyDestroy() > 0) - throw(eH + "DestroyDenied set for this top-level item."); - ResetSelectedTimer(entry); - gReve->RemoveFromListTree(rnr_el, fListTree, entry); - gReve->Redraw3D(); - } - } -} - -void RGLTEFrame::ResetSelectedTimer(TGListTreeItem* lti) -{ - fNewSelected = lti->GetPrevSibling(); - if (! fNewSelected) { - fNewSelected = lti->GetNextSibling(); - if (! fNewSelected) - fNewSelected = lti->GetParent(); - } - - TTimer::SingleShot(0, IsA()->GetName(), this, "ResetSelected()"); -} - -void RGLTEFrame::ResetSelected() -{ - fListTree->HighlightItem(fNewSelected); - fListTree->SetSelected(fNewSelected); - fNewSelected = 0; -} - - -/**************************************************************************/ -/**************************************************************************/ - -//______________________________________________________________________ -// RGBrowser -// -// - -ClassImp(RGBrowser) - -void RGBrowser::SetupCintExport(TClass* cl) -{ - TList* l = cl->GetMenuList(); - TClassMenuItem* n = new TClassMenuItem(TClassMenuItem::kPopupUserFunction, cl, - "Export to CINT", "ExportToCINT", this, "const char*,TObject*", 1); - - l->AddFirst(n); -} - -void RGBrowser::CalculateReparentXY(TGObject* parent, Int_t& x, Int_t& y) -{ - UInt_t w, h; - Window_t childdum; - gVirtualX->GetWindowSize(parent->GetId(), x, y, w, h); - gVirtualX->TranslateCoordinates(parent->GetId(), - gClient->GetDefaultRoot()->GetId(), - 0, 0, x, y, childdum); -} - -/**************************************************************************/ - -namespace -{ -enum ReveMenu_e { - kNewViewer, kNewScene, kNewProjector, - kNewBrowser, kNewCanvas, kNewCanvasExt, kNewTextEditor, kNewHtmlBrowser, - kVerticalBrowser -}; -} - -RGBrowser::RGBrowser(UInt_t w, UInt_t h) : - TGNewBrowser("Reve Main Window", w, h, kFALSE), - fFileBrowser (0) -{ - // Construct Reve menu - - fRevePopup = new TGPopupMenu(gClient->GetRoot()); - fRevePopup->AddEntry("New &Viewer", kNewViewer); - fRevePopup->AddEntry("New &Scene", kNewScene); - fRevePopup->AddEntry("New &Projector", kNewProjector); - fRevePopup->AddSeparator(); - fRevePopup->AddEntry("New &Browser", kNewBrowser); - fRevePopup->AddEntry("New &Canvas", kNewCanvas); - fRevePopup->AddEntry("New Canvas Ext", kNewCanvasExt); - fRevePopup->AddEntry("New Text Editor", kNewTextEditor); - // fRevePopup->AddEntry("New HTML Browser", kNewHtmlBrowser); - fRevePopup->AddSeparator(); - fRevePopup->AddEntry("Vertical browser", kVerticalBrowser); - fRevePopup->CheckEntry(kVerticalBrowser); - - fRevePopup->Connect("Activated(Int_t)", "Reve::RGBrowser", - this, "ReveMenu(Int_t)"); - - fMenuBar->RemovePopup("Framework"); - // ?? should disconnect / delete. - fMenuBar->AddPopup("&Reve", fRevePopup, new TGLayoutHints(kLHintsTop | kLHintsLeft, 0, 4, 0, 0)); - - fPreMenuFrame->ChangeOptions(fPreMenuFrame->GetOptions() | kRaisedFrame); - fTopMenuFrame->Layout(); - fTopMenuFrame->MapSubwindows(); -} - -/**************************************************************************/ - -void RGBrowser::ReveMenu(Int_t id) -{ - switch (id) - { - case kNewViewer: - gReve->SpawnNewViewer("Viewer Pepe"); - break; - - case kNewScene: - gReve->SpawnNewScene("Scena Mica"); - break; - - case kNewProjector: { - RenderElement* pr = (RenderElement*) (gROOT->GetClass("Reve::NLTProjector")->New()); - pr->SetRnrElNameTitle("Projector", "User-created projector."); - gReve->AddToListTree(pr, kTRUE); - break; - } - case kNewBrowser: - gROOT->ProcessLineFast("new TBrowser"); - break; - - case kNewCanvas: - StartEmbedding(1); - gROOT->ProcessLineFast("new TCanvas"); - StopEmbedding(); - SetTabTitle("Canvas", 1); - break; - - case kNewCanvasExt: - gROOT->ProcessLineFast("new TCanvas"); - break; - - case kNewTextEditor: - StartEmbedding(1); - gROOT->ProcessLineFast(Form("new TGTextEditor((const char *)0, (const TGWindow *)0x%lx)", gClient->GetRoot())); - StopEmbedding(); - SetTabTitle("Editor", 1); - break; - - case kNewHtmlBrowser: - gSystem->Load("libGuiHtml"); - if (gSystem->Load("libRHtml") >= 0) - { - StartEmbedding(1); - gROOT->ProcessLine(Form("new TGHtmlBrowser(\"http://root.cern.ch/root/html/ClassIndex.html\", \ - (const TGWindow *)0x%lx)", gClient->GetRoot())); - StopEmbedding(); - SetTabTitle("HTML", 1); - } - break; - - case kVerticalBrowser: - if (fRevePopup->IsEntryChecked(kVerticalBrowser)) { - gReve->GetLTEFrame()->ReconfToHorizontal(); - fRevePopup->UnCheckEntry(kVerticalBrowser); - } else { - gReve->GetLTEFrame()->ReconfToVertical(); - fRevePopup->CheckEntry(kVerticalBrowser); - } - break; - - default: - break; - } -} - -/**************************************************************************/ - -void RGBrowser::InitPlugins() -{ - // File browser plugin... - StartEmbedding(0); - //gROOT->ProcessLine(Form("new TGFileBrowser((const TGWindow *)0x%lx, 200, 500)", - // gClient->GetRoot())); - { - TGFileBrowser *fb = MakeFileBrowser(); - fb->BrowseObj(gROOT); - fb->AddFSDirectory("/"); - fb->Show(); - - fFileBrowser = fb; - } - StopEmbedding(); - SetTabTitle("Files", 0); - - // Class browser plugin - /* - StartEmbedding(0); - gROOT->ProcessLine(Form("new TGClassBrowser((const TGWindow *)0x%lx, 200, 500)", - gClient->GetRoot())); - StopEmbedding(); - SetTabTitle("Classes", 0, 1); - */ - - // --- main frame - - // Canvas plugin... - /* Now in menu - StartEmbedding(1); - gROOT->ProcessLineFast("new TCanvas"); - StopEmbedding(); - SetTabTitle("Canvas", 1); - */ - - // Editor plugin... - /* Now in menu - StartEmbedding(1); - gROOT->ProcessLineFast(Form("new TGTextEditor((const char *)0, (const TGWindow *)0x%lx)", - gClient->GetRoot())); - StopEmbedding(); - SetTabTitle("Editor", 1); - */ - - // --- bottom area - - // Command plugin... - StartEmbedding(2); - gROOT->ProcessLineFast(Form("new TGCommandPlugin((const TGWindow *)0x%lx, 700, 300)", - gClient->GetRoot())); - StopEmbedding(); - SetTabTitle("Command", 2); - - // --- Select first tab everywhere - SetTab(0, 0); - SetTab(1, 0); - SetTab(2, 0); -} diff --git a/EVE/Reve/RGBrowser.h b/EVE/Reve/RGBrowser.h deleted file mode 100644 index 6fa79de1c30..00000000000 --- a/EVE/Reve/RGBrowser.h +++ /dev/null @@ -1,86 +0,0 @@ -#ifndef REVE_RGBrowser_H -#define REVE_RGBrowser_H - -#include "TGNewBrowser.h" -#include - -#include - -class TGFileBrowser; -class TGSplitter; - -namespace Reve { - -class RGEditor; - -class RGLTEFrame : public TGMainFrame -{ - RGLTEFrame(const RGLTEFrame&); // Not implemented - RGLTEFrame& operator=(const RGLTEFrame&); // Not implemented - - friend class ReveManager; - -protected: - TGCompositeFrame *fFrame; - TGCompositeFrame *fLTFrame; - - TGCanvas *fLTCanvas; - TGListTree *fListTree; - TGSplitter *fSplitter; - RGEditor *fEditor; - - TContextMenu *fCtxMenu; - - TGListTreeItem *fNewSelected; - - void ResetSelectedTimer(TGListTreeItem* lti); - -public: - RGLTEFrame(const Text_t* name, Int_t width=250, Int_t height=700); - virtual ~RGLTEFrame(); - - void ReconfToHorizontal(); - void ReconfToVertical(); - - TGListTree* GetListTree() { return fListTree; } - - void ItemChecked(TObject* obj, Bool_t state); - void ItemClicked(TGListTreeItem *entry, Int_t btn, Int_t x, Int_t y); - void ItemDblClicked(TGListTreeItem* item, Int_t btn); - void ItemKeyPress(TGListTreeItem *entry, UInt_t keysym, UInt_t mask); - - void ResetSelected(); - - ClassDef(RGLTEFrame, 0); -}; - -// ---------------------------------------------------------------- - -class RGBrowser : public TGNewBrowser -{ - RGBrowser(const RGBrowser&); // Not implemented - RGBrowser& operator=(const RGBrowser&); // Not implemented - -protected: - void SetupCintExport(TClass* cl); - void CalculateReparentXY(TGObject* parent, Int_t& x, Int_t& y); - - TGFileBrowser *fFileBrowser; - TGPopupMenu *fRevePopup; - - public: - RGBrowser(UInt_t w, UInt_t h); - virtual ~RGBrowser() {} - - void InitPlugins(); - - TGFileBrowser *GetFileBrowser() const { return fFileBrowser; } - - void ReveMenu(Int_t id); - - ClassDef(RGBrowser, 0); -}; - -} // namespace Reve - -#endif diff --git a/EVE/Reve/RGEditor.cxx b/EVE/Reve/RGEditor.cxx deleted file mode 100644 index ee51a68d031..00000000000 --- a/EVE/Reve/RGEditor.cxx +++ /dev/null @@ -1,104 +0,0 @@ -// $Header$ - -#include "RGEditor.h" -#include "RenderElement.h" -#include "ReveManager.h" - -#include -#include -#include - -//______________________________________________________________________ -// RGEditor -// - -using namespace Reve; - -ClassImp(RGEditor) - -RGEditor::RGEditor(TCanvas* canvas, Int_t width, Int_t height) : - TGedEditor(canvas), - fRnrElement(0), - fObject (0) -{ - Resize(width, height); - - // Fix priority for TAttMarkerEditor. - TClass* amClass = TClass::GetClass("TAttMarker"); - TClass* edClass = TClass::GetClass("TAttMarkerEditor"); - TGWindow *exroot = (TGWindow*) fClient->GetRoot(); - fClient->SetRoot(fTabContainer); - SetFrameCreator(this); - TGedFrame *frame = reinterpret_cast(edClass->New()); - frame->SetModelClass(amClass); - { - Int_t off = edClass->GetDataMemberOffset("fPriority"); - if(off == 0) - printf("ojej!\n"); - else - * (Int_t*) (((char*)frame) + off) = 1; - } - SetFrameCreator(0); - fClient->SetRoot(exroot); - fFrameMap.Add(amClass, frame); -} - -RenderElement* RGEditor::GetRnrElement() const -{ - return (fModel == fObject) ? fRnrElement : 0; -} - -void RGEditor::DisplayRenderElement(RenderElement* re) -{ - fRnrElement = re; - fObject = fRnrElement ? fRnrElement->GetEditorObject() : 0; - TGedEditor::SetModel(fPad, fObject, kButton1Down); -} - -void RGEditor::DisplayObject(TObject* obj) -{ - fRnrElement = dynamic_cast(obj); - fObject = obj; - TGedEditor::SetModel(fPad, obj, kButton1Down); -} - -/**************************************************************************/ - -void RGEditor::SetModel(TVirtualPad* pad, TObject* obj, Int_t event) -{ - // !!!! do something so that such calls from elswhere will also - // now the render element - - fRnrElement = dynamic_cast(obj); - fObject = obj; - TGedEditor::SetModel(pad, obj, event); -} - -void RGEditor::Update(TGedFrame* /*gframe*/) -{ - // Virtual method from TGedEditor ... called on every change. - - if (fRnrElement) { - fRnrElement->UpdateItems(); - fRnrElement->ElementChanged(); - } - - gReve->Redraw3D(); -} - -/**************************************************************************/ - -/* -// Attempt to enable mouse-wheel in geditor -- failed. -Bool_t RGEditor::HandleButton(Event_t *event) -{ - // Handle mouse button event in container. - - printf("odfjgsf\n"); - if (event->fCode == kButton4 || event->fCode == kButton5) { - return fCan->GetContainer()->HandleButton(event); - } else { - return TGedEditor::HandleButton(event); - } -} -*/ diff --git a/EVE/Reve/RGEditor.h b/EVE/Reve/RGEditor.h deleted file mode 100644 index d7b5b860724..00000000000 --- a/EVE/Reve/RGEditor.h +++ /dev/null @@ -1,40 +0,0 @@ -// $Header$ - -#ifndef REVE_RGEditor_H -#define REVE_RGEditor_H - -#include - -namespace Reve { - -class RenderElement; - -class RGEditor : public TGedEditor -{ - RGEditor(const RGEditor&); // Not implemented - RGEditor& operator=(const RGEditor&); // Not implemented - -protected: - RenderElement *fRnrElement; // Cached rnr-el pointer - TObject *fObject; // Cached tobj pointer - -public: - RGEditor(TCanvas* canvas=0, Int_t width=250, Int_t height=400); - virtual ~RGEditor() {} - - RenderElement* GetRnrElement() const; - - void DisplayRenderElement(RenderElement* re); - void DisplayObject(TObject* obj); - - virtual void SetModel(TVirtualPad* pad, TObject* obj, Int_t event); - virtual void Update(TGedFrame* gframe=0); - - // virtual Bool_t HandleButton(Event_t *event); - - ClassDef(RGEditor, 0); -}; // endclass RGEditor - -} - -#endif diff --git a/EVE/Reve/RGValuators.cxx b/EVE/Reve/RGValuators.cxx deleted file mode 100644 index 8d7ac894eeb..00000000000 --- a/EVE/Reve/RGValuators.cxx +++ /dev/null @@ -1,401 +0,0 @@ -// $Header$ - -#include "RGValuators.h" - -#include -#include -#include -#include - -using namespace Reve; - -/**************************************************************************/ -// RGValuatorBase -/**************************************************************************/ - -ClassImp(RGValuatorBase) - -RGValuatorBase::RGValuatorBase(const TGWindow *p, const char* name, - UInt_t w, UInt_t h) : - TGCompositeFrame(p, w, h), - - fLabelWidth (0), - fAlignRight (kFALSE), - fShowSlider (kTRUE), - - fNELength (5), - fNEHeight (20), - - fLabel (0) -{ - SetName(name); -} - -/**************************************************************************/ -// RGValuator -/**************************************************************************/ - -ClassImp(RGValuator) - -RGValuator::RGValuator(const TGWindow *p, const char* title, - UInt_t w, UInt_t h) : - RGValuatorBase(p, title, w, h), - - fValue (0), - fMin (0), - fMax (0), - - fSliderNewLine (kFALSE), - fSliderDivs (-1), - fEntry (0), - fSlider (0) -{} - -void RGValuator::Build(Bool_t connect) -{ - TGCompositeFrame *hf1, *hfs; - if(fShowSlider && fSliderNewLine) { - SetLayoutManager(new TGVerticalLayout(this)); - hf1 = new TGHorizontalFrame(this); - hf1->SetLayoutManager(new TGHorizontalLayout(hf1)); - AddFrame(hf1, new TGLayoutHints(kLHintsTop, 0,0,0,0)); - hfs = new TGHorizontalFrame(this); - hfs->SetLayoutManager(new TGHorizontalLayout(hfs)); - AddFrame(hfs, new TGLayoutHints(kLHintsTop, 0,0,0,0)); - } else { - hf1 = this; - hfs = this; - SetLayoutManager(new TGHorizontalLayout(this)); - } - - // label - { - TGLayoutHints *labh, *labfrh; - if(fAlignRight) { - labh = new TGLayoutHints(kLHintsRight | kLHintsBottom, 4,0,0,0); - labfrh = new TGLayoutHints(kLHintsRight); - } else { - labh = new TGLayoutHints(kLHintsLeft | kLHintsBottom, 0,4,0,0); - labfrh = new TGLayoutHints(kLHintsLeft); - } - TGCompositeFrame *labfr = - new TGHorizontalFrame(hf1, fLabelWidth, fNEHeight, - fLabelWidth != 0 ? kFixedSize : kFixedHeight); - fLabel = new TGLabel(labfr, fName); - labfr->AddFrame(fLabel, labh); - hf1->AddFrame(labfr, labfrh); - } - - // number-entry - TGLayoutHints* elh = new TGLayoutHints(kLHintsLeft, 0,0,0,0); - fEntry = new TGNumberEntry(hf1, 0, fNELength); - fEntry->SetHeight(fNEHeight); - fEntry->GetNumberEntry()->SetToolTipText("Enter Slider Value"); - hf1->AddFrame(fEntry, elh); - - fEntry->Associate(this); - if (connect) - fEntry->Connect("ValueSet(Long_t)", - "Reve::RGValuator", this, "EntryCallback()"); - - // slider - if(fShowSlider) { - fSlider = new TGHSlider(hfs, GetWidth(), kSlider1 | kScaleBoth); - hfs->AddFrame(fSlider, new TGLayoutHints(kLHintsLeft|kLHintsTop, 1,1,0,0)); - - fSlider->Associate(this); - if (connect) - fSlider->Connect("PositionChanged(Int_t)", - "Reve::RGValuator", this, "SliderCallback()"); - } -} - -void RGValuator::SetLimits(Float_t min, Float_t max, Int_t npos, - TGNumberFormat::EStyle nef) -{ - fMin = Float_t(min); - fMax = Float_t(max); - fEntry->SetFormat(nef); - fEntry->SetLimits(TGNumberFormat::kNELLimitMinMax, min, max); - - if(fSlider) { - fSliderDivs = npos - 1; - fSlider->SetRange(0, fSliderDivs); - } -} - -void RGValuator::SetLimits(Int_t min, Int_t max) -{ - fMin = Float_t(min); - fMax = Float_t(max); - fEntry->SetFormat(TGNumberFormat::kNESInteger); - fEntry->SetLimits(TGNumberFormat::kNELLimitMinMax, min, max); - - if(fSlider) { - fSliderDivs = max - min; - fSlider->SetRange(0, fSliderDivs); - } -} - -Int_t RGValuator::CalcSliderPos(Float_t v) -{ - return (Int_t) TMath::Nint((v - fMin)*fSliderDivs/(fMax - fMin)); -} - -void RGValuator::EntryCallback() -{ - fValue = fEntry->GetNumber(); - if(fSlider) { - fSlider->SetPosition(CalcSliderPos(fValue)); - } - ValueSet(fValue); -} - -void RGValuator::SliderCallback() -{ - fValue = fMin + fSlider->GetPosition()*(fMax-fMin)/fSliderDivs; - fEntry->SetNumber(fValue); - ValueSet(fValue); -} - - -void RGValuator::ValueSet(Double_t val) -{ - Emit("ValueSet(Double_t)", val); -} - -void RGValuator::SetValue(Float_t val, Bool_t emit) -{ - fValue = val; - fEntry->SetNumber(fValue); - - if(fSlider){ - fSlider->SetPosition(CalcSliderPos(fValue)); - } - if(emit) - ValueSet(val); -} - -void RGValuator::SetToolTip(const Text_t* tip) -{ - fEntry->GetNumberEntry()->SetToolTipText(tip); -} - -void RGValuator::SetEnabled(Bool_t state) -{ - fEntry->GetNumberEntry()->SetEnabled(state); - fEntry->GetButtonUp()->SetEnabled(state); - fEntry->GetButtonDown()->SetEnabled(state); - if(fSlider) { - if(state) fSlider->MapWindow(); - else fSlider->UnmapWindow(); - } -} - -/**************************************************************************/ -// RGDoubleValuator -/**************************************************************************/ - -ClassImp(RGDoubleValuator) - -RGDoubleValuator::RGDoubleValuator(const TGWindow *p, const char* title, - UInt_t w, UInt_t h) : - RGValuatorBase(p, title, w, h), - - fMinEntry(0), - fMaxEntry(0), - fSlider(0) -{} - -void RGDoubleValuator::Build(Bool_t connect) -{ - TGCompositeFrame *hf1, *hfs; - if(fShowSlider) { - SetLayoutManager(new TGVerticalLayout(this)); - hf1 = new TGHorizontalFrame(this); - hf1->SetLayoutManager(new TGHorizontalLayout(hf1)); - AddFrame(hf1, new TGLayoutHints(kLHintsTop, 0,0,0,0)); - hfs = new TGHorizontalFrame(this); - hfs->SetLayoutManager(new TGHorizontalLayout(hfs)); - AddFrame(hfs, new TGLayoutHints(kLHintsTop, 0,0,0,0)); - } else { - hf1 = this; - hfs = this; - SetLayoutManager(new TGHorizontalLayout(this)); - } - - // label - TGLayoutHints* lh; - if(fAlignRight) - lh = new TGLayoutHints(kLHintsRight | kLHintsBottom, 4,0,0,0); - else - lh = new TGLayoutHints(kLHintsLeft | kLHintsBottom, 0,4,0,0); - - if(fLabelWidth > 0) { - TGCompositeFrame *lf = new TGHorizontalFrame(hf1, fLabelWidth, fNEHeight, kFixedSize); - fLabel = new TGLabel(lf, fName); - lf->AddFrame(fLabel, lh); - // add label frame to top horizontal frame - TGLayoutHints* lfh = new TGLayoutHints(kLHintsLeft, 0,0,0,0); - hf1->AddFrame(lf, lfh); - } else { - fLabel = new TGLabel(hf1, fName); - hf1->AddFrame(fLabel, lh); - } - - // entries - fMinEntry = new TGNumberEntry(hf1, 0, fNELength); - fMinEntry->SetHeight(fNEHeight); - fMinEntry->GetNumberEntry()->SetToolTipText("Enter Slider Min Value"); - hf1->AddFrame(fMinEntry, new TGLayoutHints(kLHintsLeft, 0,0,0,0)); - if (connect) - fMinEntry->Connect("ValueSet(Long_t)", - "Reve::RGDoubleValuator", this, "MinEntryCallback()"); - fMinEntry->Associate(this); - - fMaxEntry = new TGNumberEntry(hf1, 0, fNELength); - fMaxEntry->SetHeight(fNEHeight); - fMaxEntry->GetNumberEntry()->SetToolTipText("Enter Slider Max Value"); - hf1->AddFrame(fMaxEntry, new TGLayoutHints(kLHintsLeft, 2,0,0,0)); - if (connect) - fMaxEntry->Connect("ValueSet(Long_t)", - "Reve::RGDoubleValuator", this, "MaxEntryCallback()"); - fMaxEntry->Associate(this); - - // slider - if(fShowSlider) { - fSlider = new TGDoubleHSlider(hfs, GetWidth(), kDoubleScaleBoth); - hfs->AddFrame(fSlider, new TGLayoutHints(kLHintsTop|kLHintsLeft, 0,0,1,0)); - fSlider->Associate(this); - if (connect) - fSlider->Connect("PositionChanged()", - "Reve::RGDoubleValuator", this, "SliderCallback()"); - } -} - -void RGDoubleValuator::SetLimits(Int_t min, Int_t max) -{ - fMinEntry->SetLimits(TGNumberFormat::kNELLimitMinMax, min, max); - fMinEntry->SetFormat(TGNumberFormat::kNESInteger); - fMaxEntry->SetLimits(TGNumberFormat::kNELLimitMinMax, min, max); - fMaxEntry->SetFormat(TGNumberFormat::kNESInteger); - - if(fSlider) { - fSlider->SetRange(min, max); - } -} - -void RGDoubleValuator::SetLimits(Float_t min, Float_t max, - TGNumberFormat::EStyle nef) -{ - // printf("RGDoubleValuator::SetLimits(Float_t min, Float_t max, Int_ \n"); - fMinEntry->SetLimits(TGNumberFormat::kNELLimitMinMax, min, max); - fMinEntry->SetFormat(nef); - fMaxEntry->SetLimits(TGNumberFormat::kNELLimitMinMax, min, max); - fMaxEntry->SetFormat(nef); - - if(fSlider) fSlider->SetRange(min, max); -} - -void RGDoubleValuator::MinEntryCallback() -{ - if(GetMin() > GetMax()) - fMaxEntry->SetNumber(GetMin()); - if(fSlider) fSlider->SetPosition(GetMin(), GetMax()); - ValueSet(); -} - -void RGDoubleValuator::MaxEntryCallback() -{ - if(GetMax() < GetMin()) - fMinEntry->SetNumber(GetMax()); - if(fSlider) fSlider->SetPosition(GetMin(), GetMax()); - ValueSet(); -} - -void RGDoubleValuator::SliderCallback() -{ - Float_t minp, maxp; - fSlider->GetPosition(minp, maxp); - //printf("RGDoubleValuator::SliderCallback %f %f\n", minp, maxp); - fMinEntry->SetNumber(minp); - fMaxEntry->SetNumber(maxp); - ValueSet(); -} - -void RGDoubleValuator::SetValues(Float_t min, Float_t max, Bool_t emit) -{ - fMinEntry->SetNumber(min); - fMaxEntry->SetNumber(max); - - if(fSlider) fSlider->SetPosition(min, max); - if(emit) ValueSet(); -} - -void RGDoubleValuator::ValueSet() -{ - Emit("ValueSet()"); -} - - -/**************************************************************************/ -// RGTriVecValuator -/**************************************************************************/ - -RGTriVecValuator::RGTriVecValuator(const TGWindow *p, const char* name, - UInt_t w, UInt_t h) : - TGCompositeFrame(p, w, h), - - fLabelWidth (0), - fNELength (5), - fNEHeight (20) -{ - SetName(name); -} - -RGTriVecValuator::~RGTriVecValuator() -{} - -void RGTriVecValuator::Build(Bool_t vertical, const char* lab0, const char* lab1, const char* lab2) -{ - if (vertical) SetLayoutManager(new TGVerticalLayout(this)); - else SetLayoutManager(new TGHorizontalLayout(this)); - - const char *labs[3] = { lab0, lab1, lab2 }; - TGLayoutHints* lh; - for (Int_t i=0; i<3; ++i) { - fVal[i] = new RGValuator(this, labs[i], 10, 0); - fVal[i]->SetLabelWidth(fLabelWidth); - fVal[i]->SetShowSlider(kFALSE); - fVal[i]->SetNELength(fNELength); - fVal[i]->SetNEHeight(fNEHeight); - fVal[i]->Build(); - fVal[i]->Connect - ("ValueSet(Double_t)", "Reve::RGTriVecValuator", this, "ValueSet()"); - if (vertical) lh = new TGLayoutHints(kLHintsTop, 1, 1, 1, 1); - else lh = new TGLayoutHints(kLHintsLeft|kLHintsExpandX, 1, 1, 1, 1); - AddFrame(fVal[i], lh); - } -} - -void RGTriVecValuator::ValueSet() -{ - Emit("ValueSet()"); -} - -/**************************************************************************/ - -void RGTriVecValuator::SetLimits(Int_t min, Int_t max) -{ - for (Int_t i=0; i<3; ++i) - fVal[i]->SetLimits(min, max); -} - -void RGTriVecValuator::SetLimits(Float_t min, Float_t max, - TGNumberFormat::EStyle nef) -{ - for (Int_t i=0; i<3; ++i) - fVal[i]->SetLimits(min, max, 0, nef); -} - - diff --git a/EVE/Reve/RGValuators.h b/EVE/Reve/RGValuators.h deleted file mode 100644 index 6a857ffc825..00000000000 --- a/EVE/Reve/RGValuators.h +++ /dev/null @@ -1,193 +0,0 @@ -// $Header$ - -#ifndef REVE_RGValuators_H -#define REVE_RGValuators_H - -#include - -class TGLabel; -class TGHSlider; -class TGDoubleHSlider; - - -namespace Reve { - -class RGValuatorBase: public TGCompositeFrame -{ - RGValuatorBase(const RGValuatorBase&); // Not implemented - RGValuatorBase& operator=(const RGValuatorBase&); // Not implemented - -protected: - UInt_t fLabelWidth; - Bool_t fAlignRight; - Bool_t fShowSlider; - - Int_t fNELength; // Number-entry length (in characters) - Int_t fNEHeight; // Number-entry height (in pixels) - - TGLabel* fLabel; - -public: - RGValuatorBase(const TGWindow *p, const char* title, UInt_t w, UInt_t h); - virtual ~RGValuatorBase() {} - - virtual void Build(Bool_t connect=kTRUE) = 0; - - void SetLabelWidth(Int_t w) { fLabelWidth = w; } - void SetAlignRight(Bool_t a) { fAlignRight = a; } - void SetShowSlider(Bool_t s=kTRUE) { fShowSlider = s; } - - void SetNELength(Int_t l) { fNELength = l; } - void SetNEHeight(Int_t h) { fNEHeight = h; } - - ClassDef(RGValuatorBase, 0); -}; // endclass RGValuatorBase - -/**************************************************************************/ - -class RGValuator: public RGValuatorBase -{ - RGValuator(const RGValuator&); // Not implemented - RGValuator& operator=(const RGValuator&); // Not implemented - -protected: - Float_t fValue; - Float_t fMin; - Float_t fMax; - - Bool_t fSliderNewLine; - Int_t fSliderDivs; - TGNumberEntry* fEntry; - TGHSlider* fSlider; - - Int_t CalcSliderPos(Float_t v); - -public: - RGValuator(const TGWindow *p, const char* title, UInt_t w, UInt_t h); - virtual ~RGValuator() {} - - virtual void Build(Bool_t connect=kTRUE); - - Float_t GetValue() const { return fValue; } - virtual void SetValue(Float_t v, Bool_t emit=kFALSE); - - void SliderCallback(); - void EntryCallback(); - void ValueSet(Double_t); //*SIGNAL* - - TGHSlider* GetSlider() { return fSlider; } - TGNumberEntry* GetEntry() { return fEntry; } - - void SetSliderNewLine(Bool_t nl) { fSliderNewLine = nl; } - - void GetLimits(Float_t& min, Float_t& max) const { min = fMin; max = fMax; } - Float_t GetLimitMin() const { return fMin; } - Float_t GetLimitMax() const { return fMax; } - void SetLimits(Int_t min, Int_t max); - void SetLimits(Float_t min, Float_t max, Int_t npos, - TGNumberFormat::EStyle nef=TGNumberFormat::kNESRealTwo); - - void SetToolTip(const Text_t* tip); - void SetEnabled(Bool_t state); - - ClassDef(RGValuator, 0); -}; // endclass RGValuator - -/**************************************************************************/ - -class RGDoubleValuator: public RGValuatorBase -{ - RGDoubleValuator(const RGDoubleValuator&); // Not implemented - RGDoubleValuator& operator=(const RGDoubleValuator&); // Not implemented - -protected: - TGNumberEntry* fMinEntry; - TGNumberEntry* fMaxEntry; - TGDoubleHSlider* fSlider; - -public: - RGDoubleValuator(const TGWindow *p, const char* title, UInt_t w, UInt_t h); - virtual ~RGDoubleValuator() {} - - virtual void Build(Bool_t connect=kTRUE); - - void MinEntryCallback(); - void MaxEntryCallback(); - void SliderCallback(); - void ValueSet(); //*SIGNAL* - - TGDoubleHSlider* GetSlider() { return fSlider; } - TGNumberEntry* GetMinEntry() { return fMinEntry; } - TGNumberEntry* GetMaxEntry() { return fMaxEntry; } - - void SetLimits(Int_t min, Int_t max); - void SetLimits(Float_t min, Float_t max, TGNumberFormat::EStyle nef=TGNumberFormat::kNESRealTwo); - void SetValues(Float_t min, Float_t max, Bool_t emit=kFALSE); - - void GetValues(Float_t& min, Float_t& max) const - { min = fMinEntry->GetNumber(); max = fMaxEntry->GetNumber(); } - Float_t GetMin() const { return fMinEntry->GetNumber(); } - Float_t GetMax() const { return fMaxEntry->GetNumber(); } - Float_t GetLimitMin() const { return fMinEntry->GetNumMin(); } - Float_t GetLimitMax() const { return fMaxEntry->GetNumMax(); } - - ClassDef(RGDoubleValuator, 0); -}; // endclass RGDoubleValuator - -/**************************************************************************/ - -class RGTriVecValuator : public TGCompositeFrame -{ - RGTriVecValuator(const RGTriVecValuator&); // Not implemented - RGTriVecValuator& operator=(const RGTriVecValuator&); // Not implemented - -protected: - RGValuator* fVal[3]; - - // Weed-size vars from RGValuator; copied. - UInt_t fLabelWidth; - Int_t fNELength; // Number-entry length (in characters) - Int_t fNEHeight; // Number-entry height (in pixels) - -public: - RGTriVecValuator(const TGWindow *p, const char* name, UInt_t w, UInt_t h); - virtual ~RGTriVecValuator(); - - void Build(Bool_t vertical, const char* lab0, const char* lab1, const char* lab2); - - RGValuator* GetValuator(Int_t i) const { return fVal[i]; } - - Float_t GetValue(Int_t i) const { return fVal[i]->GetValue(); } - void SetValue(Int_t i, Float_t v) { fVal[i]->SetValue(v); } - - void GetValues(Float_t& v0, Float_t& v1, Float_t& v2) const - { v0 = GetValue(0); v1 = GetValue(1); v2 = GetValue(2); } - void GetValues(Float_t v[3]) const - { v[0] = GetValue(0); v[1] = GetValue(1); v[2] = GetValue(2); } - void GetValues(Double_t v[3]) const - { v[0] = GetValue(0); v[1] = GetValue(1); v[2] = GetValue(2); } - - void SetValues(Float_t v0, Float_t v1, Float_t v2) - { SetValue(0, v0); SetValue(1, v1); SetValue(2, v2); } - void SetValues(Float_t v[3]) - { SetValue(0, v[0]); SetValue(1, v[1]); SetValue(2, v[2]); } - void SetValues(Double_t v[3]) - { SetValue(0, v[0]); SetValue(1, v[1]); SetValue(2, v[2]); } - - void ValueSet(); //*SIGNAL* - - // Weed-size vars from RGValuator; copied. - void SetLabelWidth(Int_t w) { fLabelWidth = w; } - void SetNELength(Int_t l) { fNELength = l; } - void SetNEHeight(Int_t h) { fNEHeight = h; } - - void SetLimits(Int_t min, Int_t max); - void SetLimits(Float_t min, Float_t max, - TGNumberFormat::EStyle nef=TGNumberFormat::kNESRealTwo); - - ClassDef(RGTriVecValuator, 0) -}; - -} - -#endif diff --git a/EVE/Reve/RMacro.cxx b/EVE/Reve/RMacro.cxx deleted file mode 100644 index 0e95e98904e..00000000000 --- a/EVE/Reve/RMacro.cxx +++ /dev/null @@ -1,102 +0,0 @@ -// $Header$ - -#include "RMacro.h" - -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// RMacro -// -// Sub-class of TMacro, overriding Exec to unload the previous verison -// and cleanup after the execution. - -ClassImp(RMacro) - -RMacro::RMacro() : TMacro() {} - -RMacro::RMacro(const RMacro& m) : TMacro(m) {} - -RMacro::RMacro(const char* name) : - TMacro() -{ - if (!name) return; - - fTitle = name; - - char *dot = (char*)strrchr(name, '.'); - char *slash = (char*)strrchr(name, '/'); - if (dot) *dot = 0; - if (slash) fName = slash + 1; - else fName = name; - - ReadFile(fTitle); -} - -/**************************************************************************/ - -#include - -Long_t RMacro::Exec(const char* params, Int_t* error) -{ - Long_t retval = -1; - - if (gROOT->GetGlobalFunction(fName, 0, kTRUE) != 0) - { - gROOT->SetExecutingMacro(kTRUE); - gROOT->SetExecutingMacro(kFALSE); - retval = gROOT->ProcessLine(Form("%s()", fName.Data()), error); - } - else - { - // Copy from TMacro::Exec. Difference is that the file is really placed - // into the /tmp. - TString fname = "/tmp/"; - { - //the current implementation uses a file in the current directory. - //should be replaced by a direct execution from memory by CINT - fname += GetName(); - fname += ".C"; - SaveSource(fname); - //disable a possible call to gROOT->Reset from the executed script - gROOT->SetExecutingMacro(kTRUE); - //execute script in /tmp - TString exec = ".x " + fname; - TString p = params; - if (p == "") p = fParams; - if (p != "") - exec += "(" + p + ")"; - retval = gROOT->ProcessLine(exec, error); - //enable gROOT->Reset - gROOT->SetExecutingMacro(kFALSE); - //delete the temporary file - gSystem->Unlink(fname); - } - } - - //G__unloadfile(fname); - - // In case an exception was thrown (which i do not know how to detect - // the execution of next macros does not succeed. - // However strange this might seem, this solves the problem. - // TTimer::SingleShot(100, "Reve::RMacro", this, "ResetRoot()"); - // - // 27.8.07 - ok, this does not work any more. Seems I'll have to fix - // this real soon now. - // - // !!!! FIX MACRO HANDLING !!!! - // - - return retval; -} - -#include - -void RMacro::ResetRoot() -{ - // printf ("RMacro::ResetRoot doing 'gROOT->Reset()'.\n"); - gROOT->GetApplication()->ProcessLine("gROOT->Reset()"); -} diff --git a/EVE/Reve/RMacro.h b/EVE/Reve/RMacro.h deleted file mode 100644 index ed3eae652bc..00000000000 --- a/EVE/Reve/RMacro.h +++ /dev/null @@ -1,31 +0,0 @@ -// $Header$ - -#ifndef REVE_RMacro_H -#define REVE_RMacro_H - -#include - -#include - -namespace Reve { - -class RMacro : public TMacro -{ -protected: - -public: - RMacro(); - RMacro(const RMacro&); - RMacro(const char* name); - virtual ~RMacro() {} - - virtual Long_t Exec(const char* params = "0", Int_t* error = 0); - - void ResetRoot(); - - ClassDef(RMacro, 1); -}; // endclass RMacro - -} - -#endif diff --git a/EVE/Reve/RenderElement.cxx b/EVE/Reve/RenderElement.cxx deleted file mode 100644 index f228fbdac60..00000000000 --- a/EVE/Reve/RenderElement.cxx +++ /dev/null @@ -1,813 +0,0 @@ -// $Header$ - -#include "RenderElement.h" -#include "ReveManager.h" -#include "RGEditor.h" - -#include -#include -#include -#include - -#include - -using namespace Reve; - -//______________________________________________________________________________ -// RenderElement -// -// - -ClassImp(RenderElement) - -const TGPicture* RenderElement::fgRnrIcons[4] = { 0 }; -const TGPicture* RenderElement::fgListTreeIcons[8] = { 0 }; - -//______________________________________________________________________________ -RenderElement::RenderElement() : - fRnrSelf (kTRUE), - fRnrChildren (kTRUE), - fMainColorPtr (0), - fItems (), - fParents (), - fDestroyOnZeroRefCnt (kTRUE), - fDenyDestroy (0), - fChildren () -{ - // Default contructor. -} - -//______________________________________________________________________________ -RenderElement::RenderElement(Color_t& main_color) : - fRnrSelf (kTRUE), - fRnrChildren (kTRUE), - fMainColorPtr (&main_color), - fItems (), - fParents (), - fDestroyOnZeroRefCnt (kTRUE), - fDenyDestroy (0), - fChildren () -{ - // Constructor. -} - -//______________________________________________________________________________ -RenderElement::~RenderElement() -{ - // Destructor. - - static const Exc_t _eh("RenderElement::RenderElement "); - - RemoveElements(); - - for (List_i p=fParents.begin(); p!=fParents.end(); ++p) - { - (*p)->RemoveElementLocal(this); - (*p)->fChildren.remove(this); - } - fParents.clear(); - - for (sLTI_i i=fItems.begin(); i!=fItems.end(); ++i) - i->fTree->DeleteItem(i->fItem); -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void RenderElement::SetRnrElNameTitle(const Text_t* name, const Text_t* title) -{ - // Virtual function for setting of name and title of render element. - // Here we attempt to cast the assigned object into TNamed and call - // SetNameTitle() there. - - TNamed* named = dynamic_cast(GetObject()); - if (named) - named->SetNameTitle(name, title); -} - -//______________________________________________________________________________ -const Text_t* RenderElement::GetRnrElName() const -{ - // Virtual function for retrieveing name of the render-element. - // Here we attempt to cast the assigned object into TNamed and call - // GetName() there. - - TObject* named = dynamic_cast(GetObject()); - return named ? named->GetName() : ""; -} - -//______________________________________________________________________________ -const Text_t* RenderElement::GetRnrElTitle() const -{ - // Virtual function for retrieveing title of the render-element. - // Here we attempt to cast the assigned object into TNamed and call - // GetTitle() there. - - TObject* named = dynamic_cast(GetObject()); - return named ? named->GetTitle() : ""; -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void RenderElement::AddParent(RenderElement* re) -{ - // Add re into the list parents. - // Adding parent is subordinate to adding an element. - // This is an internal function. - - fParents.push_back(re); -} - -void RenderElement::RemoveParent(RenderElement* re) -{ - // Remove re from the list of parents. - // Removing parent is subordinate to removing an element. - // This is an internal function. - - static const Exc_t eH("RenderElement::RemoveParent "); - - fParents.remove(re); - CheckReferenceCount(eH); -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void RenderElement::CheckReferenceCount(const Reve::Exc_t& eh) -{ - // Check external references to this and eventually auto-destruct - // the render-element. - - if(fParents.empty() && fItems.empty() && - fDenyDestroy <= 0 && fDestroyOnZeroRefCnt) - { - if (gDebug > 0) - Info(eh, Form("auto-destructing '%s' on zero reference count.", GetRnrElName())); - - gReve->PreDeleteRenderElement(this); - delete this; - } -} - -//______________________________________________________________________________ -void RenderElement::CollectSceneParents(List_t& scenes) -{ - // Collect all parents of class Reve::Scene. This is needed to - // automatically detect which scenes need to be updated. - // - // Overriden in Reve::Scene to include itself and return. - - for(List_i p=fParents.begin(); p!=fParents.end(); ++p) - (*p)->CollectSceneParents(scenes); -} - -//______________________________________________________________________________ -void RenderElement::CollectSceneParentsFromChildren(List_t& scenes, RenderElement* parent) -{ - // Collect scene-parents from all children. This is needed to - // automatically detect which scenes need to be updated during/after - // a full sub-tree update. - // Argument parent specifies parent in traversed hierarchy for which we can - // skip the upwards search. - - for (List_i p=fParents.begin(); p!=fParents.end(); ++p) - { - if (*p != parent) (*p)->CollectSceneParents(scenes); - } - - for (List_i c=fChildren.begin(); c!=fChildren.end(); ++c) - { - (*c)->CollectSceneParentsFromChildren(scenes, this); - } -} - -/******************************************************************************/ -// List-tree stuff -/******************************************************************************/ - -//______________________________________________________________________________ -Int_t RenderElement::ExpandIntoListTree(TGListTree* ltree, - TGListTreeItem* parent) -{ - // Populates parent with elements. - // parent must be an already existing representation of *this*. - // Returns number of inserted elements. - // If parent already has children, it does nothing. - // - // RnrEl can be inserted in a list-tree several times, thus we can not - // search through fItems to get parent here. - // Anyhow, it is probably known as it must have been selected by the user. - - if (parent->GetFirstChild() != 0) - return 0; - Int_t n = 0; - for (List_i i=fChildren.begin(); i!=fChildren.end(); ++i) { - (*i)->AddIntoListTree(ltree, parent); - ++n; - } - return n; -} - -//______________________________________________________________________________ -Int_t RenderElement::DestroyListSubTree(TGListTree* ltree, - TGListTreeItem* parent) -{ - Int_t n = 0; - TGListTreeItem* i = parent->GetFirstChild(); - while (i != 0) - { - //n += DestroyListSubTree(ltree, i); - RenderElement* re = (RenderElement*) i->GetUserData(); - i = i->GetNextSibling(); - re->RemoveFromListTree(ltree, parent); - } - return n; -} - -//______________________________________________________________________________ -TGListTreeItem* RenderElement::AddIntoListTree(TGListTree* ltree, - TGListTreeItem* parent_lti) -{ - // Add this render element into ltree to already existing item - // parent_lti. - - static const Exc_t eH("RenderElement::AddIntoListTree "); - - TObject* tobj = GetObject(eH); - TGListTreeItem* item = ltree->AddItem(parent_lti, tobj->GetName(), this, - 0, 0, kTRUE); - item->SetCheckBoxPictures(GetCheckBoxPicture(1, fRnrChildren), - GetCheckBoxPicture(0, fRnrChildren)); - - item->SetPictures(GetListTreeIcon(),GetListTreeIcon()); - item->CheckItem(fRnrSelf); - - if (fMainColorPtr != 0) item->SetColor(GetMainColor()); - item->SetTipText(tobj->GetTitle()); - - fItems.insert(ListTreeInfo(ltree, item)); - ltree->ClearViewPort(); - - return item; -} - -//______________________________________________________________________________ -TGListTreeItem* RenderElement::AddIntoListTree(TGListTree* ltree, - RenderElement* parent) -{ - // Add this render element into ltree to all items belonging to - // parent. Returns list-tree-item from the first register entry (but - // we use a set for that so it can be anything). - - TGListTreeItem* lti = 0; - if (parent == 0) { - lti = AddIntoListTree(ltree, (TGListTreeItem*) 0); - } else { - for (sLTI_ri i = parent->fItems.rbegin(); i != parent->fItems.rend(); ++i) - { - if (i->fTree == ltree) - lti = AddIntoListTree(ltree, i->fItem); - } - } - return lti; -} - -//______________________________________________________________________________ -TGListTreeItem* RenderElement::AddIntoListTrees(RenderElement* parent) -{ - // Add this render element into all list-trees and all items - // belonging to parent. Returns list-tree-item from the first - // register entry (but we use a set for that so it can be anything). - - TGListTreeItem* lti = 0; - for (sLTI_ri i = parent->fItems.rbegin(); i != parent->fItems.rend(); ++i) - { - lti = AddIntoListTree(i->fTree, i->fItem); - } - return lti; -} - -//______________________________________________________________________________ -Bool_t RenderElement::RemoveFromListTree(TGListTree* ltree, - TGListTreeItem* parent_lti) -{ - static const Exc_t eH("RenderElement::RemoveFromListTree "); - - sLTI_i i = FindItem(ltree, parent_lti); - if (i != fItems.end()) { - DestroyListSubTree(ltree, i->fItem); - ltree->DeleteItem(i->fItem); - ltree->ClearViewPort(); - fItems.erase(i); - if (parent_lti == 0) CheckReferenceCount(eH); - return kTRUE; - } else { - return kFALSE; - } -} - -//______________________________________________________________________________ -Int_t RenderElement::RemoveFromListTrees(RenderElement* parent) -{ - Int_t count = 0; - - sLTI_i i = fItems.begin(); - while (i != fItems.end()) - { - sLTI_i j = i++; - TGListTreeItem *plti = j->fItem->GetParent(); - if (plti != 0 && (RenderElement*) plti->GetUserData() == parent) - { - DestroyListSubTree(j->fTree, j->fItem); - j->fTree->DeleteItem(j->fItem); - j->fTree->ClearViewPort(); - fItems.erase(j); - ++count; - } - } - - return count; -} - -//______________________________________________________________________________ -RenderElement::sLTI_i RenderElement::FindItem(TGListTree* ltree) -{ - for (sLTI_i i = fItems.begin(); i != fItems.end(); ++i) - if (i->fTree == ltree) - return i; - return fItems.end(); -} - -//______________________________________________________________________________ -RenderElement::sLTI_i RenderElement::FindItem(TGListTree* ltree, - TGListTreeItem* parent_lti) -{ - for (sLTI_i i = fItems.begin(); i != fItems.end(); ++i) - if (i->fTree == ltree && i->fItem->GetParent() == parent_lti) - return i; - return fItems.end(); -} - -//______________________________________________________________________________ -TGListTreeItem* RenderElement::FindListTreeItem(TGListTree* ltree) -{ - for (sLTI_i i = fItems.begin(); i != fItems.end(); ++i) - if (i->fTree == ltree) - return i->fItem; - return 0; -} - -//______________________________________________________________________________ -TGListTreeItem* RenderElement::FindListTreeItem(TGListTree* ltree, - TGListTreeItem* parent_lti) -{ - for (sLTI_i i = fItems.begin(); i != fItems.end(); ++i) - if (i->fTree == ltree && i->fItem->GetParent() == parent_lti) - return i->fItem; - return 0; -} - -//______________________________________________________________________________ -void RenderElement::UpdateItems() -{ - // Update list-tree-items representing this render-element. - - static const Exc_t eH("RenderElement::UpdateItems "); - - TObject* tobj = GetObject(eH); - - for (sLTI_i i=fItems.begin(); i!=fItems.end(); ++i) { - i->fItem->Rename(tobj->GetName()); - i->fItem->SetTipText(tobj->GetTitle()); - i->fItem->CheckItem(fRnrSelf); - if (fMainColorPtr != 0) i->fItem->SetColor(GetMainColor()); - i->fTree->ClearViewPort(); - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -TObject* RenderElement::GetObject(Exc_t eh) const -{ - // Get a TObject associated with this render-element. - // Most cases uses double-inheritance from RenderElement and TObject - // so we just do a dynamic cast here. - // If some RenderElement descendant implements a different scheme, - // this virtual method should be overriden accordingly. - - const TObject* obj = dynamic_cast(this); - if (obj == 0) - throw(eh + "not a TObject."); - return const_cast(obj); -} - -//______________________________________________________________________________ -void RenderElement::SpawnEditor() -{ - // Show GUI editor for this object. - - gReve->EditRenderElement(this); -} - -//______________________________________________________________________________ -void RenderElement::ExportToCINT(Text_t* var_name) -{ - // Export render-element to CINT with variable name var_name. - - const char* cname = IsA()->GetName(); - gROOT->ProcessLine(Form("%s* %s = (%s*)0x%lx;", cname, var_name, cname, this)); -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void RenderElement::PadPaint(Option_t* option) -{ - // Paint self and/or children into currently active pad. - - if (GetRnrSelf() && GetObject()) - GetObject()->Paint(option); - - - if (GetRnrChildren()) { - for (List_i i=BeginChildren(); i!=EndChildren(); ++i) { - (*i)->PadPaint(option); - } - } -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void RenderElement::SetRnrSelf(Bool_t rnr) -{ - if (rnr != fRnrSelf) - { - fRnrSelf = rnr; - - for (sLTI_i i=fItems.begin(); i!=fItems.end(); ++i) - { - if (i->fItem->IsChecked() != rnr) { - i->fItem->SetCheckBoxPictures(GetCheckBoxPicture(1, fRnrChildren), - GetCheckBoxPicture(0, fRnrChildren)); - i->fItem->CheckItem(fRnrSelf); - i->fTree->ClearViewPort(); - } - } - } -} - -//______________________________________________________________________________ -void RenderElement::SetRnrChildren(Bool_t rnr) -{ - if (rnr != fRnrChildren) - { - fRnrChildren = rnr; - - for (sLTI_i i=fItems.begin(); i!=fItems.end(); ++i) - { - i->fItem->SetCheckBoxPictures(GetCheckBoxPicture(fRnrSelf, fRnrChildren), - GetCheckBoxPicture(fRnrSelf, fRnrChildren)); - i->fTree->ClearViewPort(); - } - } -} - -//______________________________________________________________________________ -void RenderElement::SetRnrState(Bool_t rnr) -{ - if (fRnrSelf != rnr || fRnrChildren != rnr) - { - fRnrSelf = fRnrChildren = rnr; - - for (sLTI_i i=fItems.begin(); i!=fItems.end(); ++i) - { - i->fItem->SetCheckBoxPictures(GetCheckBoxPicture(1,1), GetCheckBoxPicture(0,0)); - i->fItem->CheckItem(fRnrSelf); - i->fTree->ClearViewPort(); - } - } -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void RenderElement::SetMainColor(Color_t color) -{ - // Set main color of the render-element. - // List-tree-items are updated. - - Color_t oldcol = GetMainColor(); - for (List_i i=fChildren.begin(); i!=fChildren.end(); ++i) { - if ((*i)->GetMainColor() == oldcol) (*i)->SetMainColor(color); - } - - if (fMainColorPtr) { - *fMainColorPtr = color; - for (sLTI_i i=fItems.begin(); i!=fItems.end(); ++i) { - if (i->fItem->GetColor() != color) { - i->fItem->SetColor(GetMainColor()); - i->fTree->ClearViewPort(); - } - } - } -} - -//______________________________________________________________________________ -void RenderElement::SetMainColor(Pixel_t pixel) -{ - // Convert pixel to Color_t and call the above function. - - SetMainColor(Color_t(TColor::GetColor(pixel))); -} - -/**************************************************************************/ - -//______________________________________________________________________________ -TGListTreeItem* RenderElement::AddElement(RenderElement* el) -{ - // Add el to the list of children. - - static const Exc_t eH("RenderElement::AddElement "); - - if ( ! AcceptRenderElement(el)) - throw(eH + Form("parent '%s' rejects '%s'.", - GetRnrElName(), el->GetRnrElName())); - - el->AddParent(this); - fChildren.push_back(el); - TGListTreeItem* ret = el->AddIntoListTrees(this); - ElementChanged(); - return ret; -} - -//______________________________________________________________________________ -void RenderElement::RemoveElement(RenderElement* el) -{ - // Remove el from the list of children. - - el->RemoveFromListTrees(this); - RemoveElementLocal(el); - el->RemoveParent(this); - fChildren.remove(el); - ElementChanged(); -} - -//______________________________________________________________________________ -void RenderElement::RemoveElementLocal(RenderElement* /*el*/) -{ - // Perform additional local removal of el. - // Called from RemoveElement() which does whole untangling. - // Put into special function as framework-related handling of - // element removal should really be common to all classes and - // clearing of local structures happens in between removal - // of list-tree-items and final removal. - // If you override this, you should also override - // RemoveElementsLocal(). -} - -//______________________________________________________________________________ -void RenderElement::RemoveElements() -{ - // Remove all elements. This assumes removing of all elements can be - // done more efficiently then looping over them and removing one by - // one. - - for (sLTI_i i=fItems.begin(); i!=fItems.end(); ++i) - { - DestroyListSubTree(i->fTree, i->fItem); - } - RemoveElementsLocal(); - for (List_i i=fChildren.begin(); i!=fChildren.end(); ++i) - { - (*i)->RemoveParent(this); - } - fChildren.clear(); - ElementChanged(); -} - -//______________________________________________________________________________ -void RenderElement::RemoveElementsLocal() -{ - // Perform additional local removal of all elements. - // See comment to RemoveelementLocal(RenderElement*). -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void RenderElement::EnableListElements(Bool_t rnr_self, Bool_t rnr_children) -{ - // Enable rendering of children and their list contents. - // Arguments control how to set self/child rendering. - - for (List_i i=fChildren.begin(); i!=fChildren.end(); ++i) - { - (*i)->SetRnrSelf(rnr_self); - (*i)->SetRnrChildren(rnr_children); - } - - ElementChanged(kTRUE, kTRUE); -} - -//______________________________________________________________________________ -void RenderElement::DisableListElements(Bool_t rnr_self, Bool_t rnr_children) -{ - // Disable rendering of children and their list contents. - // Arguments control how to set self/child rendering. - // - // Same as above function, but default arguments are different. This - // is convenient for calls via context menu. - - for (List_i i=fChildren.begin(); i!=fChildren.end(); ++i) - { - (*i)->SetRnrSelf(rnr_self); - (*i)->SetRnrChildren(rnr_children); - } - - ElementChanged(kTRUE, kTRUE); -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void RenderElement::Destroy() -{ - static const Exc_t eH("RenderElement::Destroy "); - - if (fDenyDestroy > 0) - throw(eH + "this element '%s' is protected against destruction.", GetRnrElName()); - - gReve->PreDeleteRenderElement(this); - delete this; - gReve->Redraw3D(); -} - -//______________________________________________________________________________ -void RenderElement::DestroyElements() -{ - static const Exc_t eH("RenderElement::DestroyElements "); - - while ( ! fChildren.empty()) { - RenderElement* c = fChildren.front(); - if (c->fDenyDestroy <= 0) - { - try { - c->Destroy(); - } - catch (Exc_t exc) { - Warning(eH, Form("element destruction failed: '%s'.", exc.Data())); - RemoveElement(c); - } - } - else - { - if (gDebug > 0) - Info(eH, Form("element '%s' is protected agains destruction, removin locally.", c->GetRnrElName())); - - RemoveElement(c); - } - } -} - -/**************************************************************************/ - -//______________________________________________________________________________ -Bool_t RenderElement::HandleElementPaste(RenderElement* el) -{ - // React to element being pasted or dnd-ed. - // Return true if redraw is needed. - - gReve->AddRenderElement(el, this); - return kTRUE; -} - -//______________________________________________________________________________ -void RenderElement::ElementChanged(Bool_t update_scenes, Bool_t redraw) -{ - if (update_scenes) - gReve->RenderElementChanged(this); - if (redraw) - gReve->Redraw3D(); -} - -/**************************************************************************/ -// Statics -/**************************************************************************/ - -//______________________________________________________________________________ -const TGPicture* -RenderElement::GetCheckBoxPicture(Bool_t rnrSelf, Bool_t rnrDaughters) -{ - Int_t idx = 0; - if (rnrSelf) idx = 2; - if (rnrDaughters ) idx++; - - return fgRnrIcons[idx]; -} - - -/**************************************************************************/ -/**************************************************************************/ - -//______________________________________________________________________________ -// Reve::RenderElementObjPtr -// - -ClassImp(RenderElementObjPtr) - -//______________________________________________________________________________ -RenderElementObjPtr::RenderElementObjPtr(TObject* obj, Bool_t own) : - RenderElement(), - fObject(obj), - fOwnObject(own) -{ - // Constructor. -} - -//______________________________________________________________________________ -RenderElementObjPtr::RenderElementObjPtr(TObject* obj, Color_t& mainColor, Bool_t own) : - RenderElement(mainColor), - fObject(obj), - fOwnObject(own) -{ - // Constructor. -} - -//______________________________________________________________________________ -TObject* RenderElementObjPtr::GetObject(Reve::Exc_t eh) const -{ - // Return external object. - // Virtual from RenderElement. - - if(fObject == 0) - throw(eh + "fObject not set."); - return fObject; -} - -//______________________________________________________________________________ -void RenderElementObjPtr::ExportToCINT(Text_t* var_name) -{ - // Export external object to CINT with variable name var_name. - // Virtual from RenderElement. - - static const Exc_t eH("RenderElementObjPtr::ExportToCINT "); - - TObject* obj = GetObject(eH); - const char* cname = obj->IsA()->GetName(); - gROOT->ProcessLine(Form("%s* %s = (%s*)0x%lx;", cname, var_name, cname, obj)); -} - -//______________________________________________________________________________ -RenderElementObjPtr::~RenderElementObjPtr() -{ - // Destructor. - - if(fOwnObject) - delete fObject; -} - - -/******************************************************************************/ -/******************************************************************************/ - -//______________________________________________________________________________ -// Reve::RenderElementList -// -// A list of render elements. -// Class of acceptable children can be limited by setting the -// fChildClass member. -// - -// !!! should have two ctors (like in RenderElement), one with Color_t& -// and set fDoColor automatically, based on which ctor is called. - -ClassImp(RenderElementList) - -//______________________________________________________________________________ -RenderElementList::RenderElementList(const Text_t* n, const Text_t* t, Bool_t doColor) : - RenderElement(), - TNamed(n, t), - fColor(0), - fDoColor(doColor), - fChildClass(0) -{ - // Constructor. - - if(fDoColor) { - SetMainColorPtr(&fColor); - } -} - -//______________________________________________________________________________ -Bool_t RenderElementList::AcceptRenderElement(RenderElement* el) -{ - // Check if RenderElement el is inherited from fChildClass. - // Virtual from RenderElement. - - if (fChildClass && ! el->IsA()->InheritsFrom(fChildClass)) - return kFALSE; - return kTRUE; -} diff --git a/EVE/Reve/RenderElement.h b/EVE/Reve/RenderElement.h deleted file mode 100644 index 8936221ddf1..00000000000 --- a/EVE/Reve/RenderElement.h +++ /dev/null @@ -1,254 +0,0 @@ -// $Header$ - -#ifndef REVE_RenderElement_H -#define REVE_RenderElement_H - -#include - -#include -#include - -class TGListTree; -class TGListTreeItem; -class TGPicture; - -namespace Reve { - -class ZTrans; - - -/******************************************************************************/ -// RenderElement -/******************************************************************************/ - -class RenderElement -{ - friend class ReveManager; - - RenderElement(const RenderElement&); // Not implemented - RenderElement& operator=(const RenderElement&); // Not implemented - -public: - class ListTreeInfo - { - public: - TGListTree* fTree; - TGListTreeItem* fItem; - - ListTreeInfo() : fTree(0), fItem(0) {} - ListTreeInfo(TGListTree* lt, TGListTreeItem* lti) : fTree(lt), fItem(lti) {} - ListTreeInfo(const ListTreeInfo& l) : fTree(l.fTree), fItem(l.fItem) {} - virtual ~ListTreeInfo() {} - - ListTreeInfo& operator=(const ListTreeInfo& l) - { fTree = l.fTree; fItem = l.fItem; return *this; } - - bool operator==(const ListTreeInfo& x) const - { return fTree == x.fTree && fItem == x.fItem; } - bool operator<(const ListTreeInfo& x) const - { return fTree == x.fTree ? fItem < x.fItem : fTree < x.fTree; } - - ClassDef(ListTreeInfo, 0); // Structure agregating data for a render element image in a list tree. - }; - - static const TGPicture* fgRnrIcons[4]; - static const TGPicture* fgListTreeIcons[8]; - - typedef std::set sLTI_t; - typedef sLTI_t::iterator sLTI_i; - typedef sLTI_t::reverse_iterator sLTI_ri; - - typedef std::list List_t; - typedef std::list::iterator List_i; - -protected: - // TRef fSource; - - Bool_t fRnrSelf; // Render this element. - Bool_t fRnrChildren; // Render children of this element. - Color_t* fMainColorPtr; // Pointer to main-color variable. - - sLTI_t fItems; // Set of list-tree-items. - List_t fParents; // List of parents. - - Bool_t fDestroyOnZeroRefCnt; // Auto-destruct when ref-count reaches zero. - Int_t fDenyDestroy; // Deny-destroy count. - - List_t fChildren; // List of children. - -public: - RenderElement(); - RenderElement(Color_t& main_color); - virtual ~RenderElement(); - - virtual void SetRnrElNameTitle(const Text_t* name, const Text_t* title); - virtual const Text_t* GetRnrElName() const; - virtual const Text_t* GetRnrElTitle() const; - - virtual void AddParent(RenderElement* re); - virtual void RemoveParent(RenderElement* re); - virtual void CheckReferenceCount(const Reve::Exc_t& eh="RenderElement::CheckReferenceCount "); - virtual void CollectSceneParents(List_t& scenes); - virtual void CollectSceneParentsFromChildren(List_t& scenes, RenderElement* parent); - - List_i BeginParents() { return fParents.begin(); } - List_i EndParents() { return fParents.end(); } - Int_t GetNParents() const { return fParents.size(); } - - List_i BeginChildren() { return fChildren.begin(); } - List_i EndChildren() { return fChildren.end(); } - Int_t GetNChildren() const { return fChildren.size(); } - - void EnableListElements (Bool_t rnr_self=kTRUE, Bool_t rnr_children=kTRUE); // *MENU* - void DisableListElements(Bool_t rnr_self=kFALSE, Bool_t rnr_children=kFALSE); // *MENU* - - Bool_t GetDestroyOnZeroRefCnt() const { return fDestroyOnZeroRefCnt; } - void SetDestroyOnZeroRefCnt(Bool_t d) { fDestroyOnZeroRefCnt = d; } - - Int_t GetDenyDestroy() const { return fDenyDestroy; } - void IncDenyDestroy() { ++fDenyDestroy; } - void DecDenyDestroy() { if (--fDenyDestroy <= 0) CheckReferenceCount("RenderElement::DecDenyDestroy "); } - - virtual void PadPaint(Option_t* option); - - virtual TObject* GetObject(Reve::Exc_t eh="RenderElement::GetObject ") const; - virtual TObject* GetEditorObject() const { return GetObject(); } - /* - TRef& GetSource() { return fSource; } - TObject* GetSourceObject() const { return fSource.GetObject(); } - void SetSourceObject(TObject* o) { fSource.SetObject(o); } - - void DumpSourceObject(); // *MENU* - void InspectSourceObject(); // *MENU* - */ - - // -------------------------------- - - virtual Int_t ExpandIntoListTree(TGListTree* ltree, TGListTreeItem* parent); - virtual Int_t DestroyListSubTree(TGListTree* ltree, TGListTreeItem* parent); - - virtual TGListTreeItem* AddIntoListTree(TGListTree* ltree, - TGListTreeItem* parent_lti); - virtual TGListTreeItem* AddIntoListTree(TGListTree* ltree, - RenderElement* parent); - virtual TGListTreeItem* AddIntoListTrees(RenderElement* parent); - - virtual Bool_t RemoveFromListTree(TGListTree* ltree, - TGListTreeItem* parent_lti); - virtual Int_t RemoveFromListTrees(RenderElement* parent); - - virtual sLTI_i FindItem(TGListTree* ltree); - virtual sLTI_i FindItem(TGListTree* ltree, - TGListTreeItem* parent_lti); - virtual TGListTreeItem* FindListTreeItem(TGListTree* ltree); - virtual TGListTreeItem* FindListTreeItem(TGListTree* ltree, - TGListTreeItem* parent_lti); - - virtual Int_t GetNItems() const { return fItems.size(); } - virtual void UpdateItems(); - - void SpawnEditor(); // *MENU* - virtual void ExportToCINT(Text_t* var_name); // *MENU* - - virtual Bool_t AcceptRenderElement(RenderElement* /*el*/) { return kTRUE; } - - virtual TGListTreeItem* AddElement(RenderElement* el); - virtual void RemoveElement(RenderElement* el); - virtual void RemoveElementLocal(RenderElement* el); - virtual void RemoveElements(); - virtual void RemoveElementsLocal(); - - virtual void Destroy(); // *MENU* - virtual void DestroyElements(); // *MENU* - - virtual Bool_t HandleElementPaste(RenderElement* el); - virtual void ElementChanged(Bool_t update_scenes=kTRUE, Bool_t redraw=kFALSE); - - virtual Bool_t CanEditRnrElement() { return kTRUE; } - virtual Bool_t GetRnrSelf() const { return fRnrSelf; } - virtual Bool_t GetRnrChildren() const { return fRnrChildren; } - virtual void SetRnrSelf(Bool_t rnr); - virtual void SetRnrChildren(Bool_t rnr); - virtual void SetRnrState(Bool_t rnr); - - virtual Bool_t CanEditMainColor() { return kFALSE; } - Color_t* GetMainColorPtr() { return fMainColorPtr; } - void SetMainColorPtr(Color_t* color) { fMainColorPtr = color; } - - virtual Color_t GetMainColor() const { return fMainColorPtr ? *fMainColorPtr : 0; } - virtual void SetMainColor(Color_t color); - void SetMainColor(Pixel_t pixel); - - virtual Bool_t CanEditMainTransparency() { return kFALSE; } - virtual UChar_t GetMainTransparency() const { return 0; } - virtual void SetMainTransparency(UChar_t) {} - - virtual Bool_t CanEditMainHMTrans() { return kFALSE; } - virtual ZTrans* PtrMainHMTrans() { return 0; } - - static const TGPicture* GetCheckBoxPicture(Bool_t rnrElement, Bool_t rnrDaughter); - virtual const TGPicture* GetListTreeIcon() { return fgListTreeIcons[0]; } - - ClassDef(RenderElement, 1); // Base class for visualization elements. -}; // endclass RenderElement - - -/******************************************************************************/ -// RenderElementObjPtr -/******************************************************************************/ - -class RenderElementObjPtr : public RenderElement, - public TObject -{ - RenderElementObjPtr(const RenderElementObjPtr&); // Not implemented - RenderElementObjPtr& operator=(const RenderElementObjPtr&); // Not implemented - -protected: - TObject* fObject; // External object holding the visual data. - Bool_t fOwnObject; // Is object owned / should be deleted on destruction. - -public: - RenderElementObjPtr(TObject* obj, Bool_t own=kTRUE); - RenderElementObjPtr(TObject* obj, Color_t& mainColor, Bool_t own=kTRUE); - virtual ~RenderElementObjPtr(); - - virtual TObject* GetObject(Exc_t eh="RenderElementObjPtr::GetObject ") const; - virtual void ExportToCINT(Text_t* var_name); - - Bool_t GetOwnObject() const { return fOwnObject; } - void SetOwnObject(Bool_t o) { fOwnObject = o; } - - ClassDef(RenderElementObjPtr, 1); // Render element with external TObject as visualization data holder. -}; // endclass RenderElementObjPtr - - -/******************************************************************************/ -// RenderElementList -/******************************************************************************/ - -class RenderElementList : public RenderElement, - public TNamed -{ -protected: - Color_t fColor; // Color of the object. - Bool_t fDoColor; // Should serve fColor as the main color of the object. - TClass *fChildClass; // Class of acceptable children, others are rejected. - -public: - RenderElementList(const Text_t* n="RenderElementList", const Text_t* t="", - Bool_t doColor=kFALSE); - virtual ~RenderElementList() {} - - virtual Bool_t CanEditMainColor() { return fDoColor; } - - TClass* GetChildClass() const { return fChildClass; } - void SetChildClass(TClass* c) { fChildClass = c; } - - virtual Bool_t AcceptRenderElement(RenderElement* el); - - ClassDef(RenderElementList, 1); // List of render elements. -}; - -} - -#endif diff --git a/EVE/Reve/RenderElementEditor.cxx b/EVE/Reve/RenderElementEditor.cxx deleted file mode 100644 index ece962cd5e7..00000000000 --- a/EVE/Reve/RenderElementEditor.cxx +++ /dev/null @@ -1,145 +0,0 @@ -// $Header$ - -#include "RenderElementEditor.h" -#include -#include - -#include -#include - -#include -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// RenderElementEditor -// - -ClassImp(RenderElementEditor) - - RenderElementEditor::RenderElementEditor(const TGWindow *p, - Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - - fRE (0), - fHFrame (0), - fRnrSelf (0), - fRnrChildren (0), - fMainColor (0), - fTransparency (0), - fHMTrans (0) -{ - MakeTitle("RenderElement"); - fPriority = 0; - - fHFrame = new TGHorizontalFrame(this); - - fRnrSelf = new TGCheckButton(fHFrame, "RnrSelf"); - fHFrame->AddFrame(fRnrSelf, new TGLayoutHints(kLHintsLeft, 1, 2, 1, 1)); - fRnrSelf->Connect - ("Toggled(Bool_t)", - "Reve::RenderElementEditor", this, "DoRnrSelf()"); - - fRnrChildren = new TGCheckButton(fHFrame, "RnrChildren"); - fHFrame->AddFrame(fRnrChildren, new TGLayoutHints(kLHintsLeft, 2, 1, 1, 1)); - fRnrChildren->Connect - ("Toggled(Bool_t)", - "Reve::RenderElementEditor", this, "DoRnrChildren()"); - - fMainColor = new TGColorSelect(fHFrame, 0, -1); - fHFrame->AddFrame(fMainColor, new TGLayoutHints(kLHintsLeft, 2, 0, 1, 1)); - fMainColor->Connect - ("ColorSelected(Pixel_t)", - "Reve::RenderElementEditor", this, "DoMainColor(Pixel_t)"); - - fTransparency = new TGNumberEntry(fHFrame, 0., 2, -1, - TGNumberFormat::kNESInteger, TGNumberFormat::kNEANonNegative, - TGNumberFormat::kNELLimitMinMax, 0, 100); - fTransparency->SetHeight(18); - fTransparency->GetNumberEntry()->SetToolTipText("Transparency: 0 is opaque, 100 fully transparent."); - fHFrame->AddFrame(fTransparency, new TGLayoutHints(kLHintsLeft, 0, 0, 2, 0)); - fTransparency->Connect - ("ValueSet(Long_t)", - "Reve::RenderElementEditor", this, "DoTransparency()"); - - AddFrame(fHFrame, new TGLayoutHints(kLHintsTop, 0, 0, 0, 0)); - - fHMTrans = new ZTransSubEditor(this); - fHMTrans->Connect("UseTrans()", "Reve::RenderElementEditor", this, "Update()"); - fHMTrans->Connect("TransChanged()", "Reve::RenderElementEditor", this, "Update()"); - AddFrame(fHMTrans, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 0, 0, 0, 0)); -} - -RenderElementEditor::~RenderElementEditor() -{} - -/**************************************************************************/ - -void RenderElementEditor::SetModel(TObject* obj) -{ - fRE = dynamic_cast(obj); - - if (fRE->CanEditRnrElement()) { - fRnrSelf->SetState(fRE->GetRnrSelf() ? kButtonDown : kButtonUp); - fRnrChildren->SetState(fRE->GetRnrChildren() ? kButtonDown : kButtonUp); - fRnrSelf->MapWindow(); - fRnrChildren->MapWindow(); - } else { - fRnrSelf->UnmapWindow(); - fRnrChildren->UnmapWindow(); - } - - if (fRE->CanEditMainColor()) { - fMainColor->SetColor(TColor::Number2Pixel(fRE->GetMainColor()), kFALSE); - fMainColor->MapWindow(); - } else { - fMainColor->UnmapWindow(); - } - if (fRE->CanEditMainTransparency()) { - fTransparency->SetNumber(fRE->GetMainTransparency()); - fTransparency->MapWindow(); - } else { - fTransparency->UnmapWindow(); - } - if (fRE->CanEditMainHMTrans()) { - fHMTrans->SetDataFromTrans(fRE->PtrMainHMTrans()); - fHMTrans->MapWindow(); - } else { - fHMTrans->UnmapWindow(); - } - - fHFrame->Layout(); -} - -/**************************************************************************/ - - -void RenderElementEditor::DoRnrSelf() -{ - fRE->SetRnrSelf(fRnrSelf->IsOn()); - Update(); -} - - -void RenderElementEditor::DoRnrChildren() -{ - fRE->SetRnrChildren(fRnrChildren->IsOn()); - Update(); -} - -void RenderElementEditor::DoMainColor(Pixel_t color) -{ - fRE->SetMainColor(color); - Update(); -} - -void RenderElementEditor::DoTransparency() -{ - fRE->SetMainTransparency((UChar_t)(fTransparency->GetNumber())); - Update(); -} diff --git a/EVE/Reve/RenderElementEditor.h b/EVE/Reve/RenderElementEditor.h deleted file mode 100644 index 4174fed4184..00000000000 --- a/EVE/Reve/RenderElementEditor.h +++ /dev/null @@ -1,49 +0,0 @@ -// $Header$ - -#ifndef REVE_RenderElementEditor_H -#define REVE_RenderElementEditor_H - -#include - -class TGCheckButton; -class TGNumberEntry; -class TGColorSelect; - -namespace Reve { - -class RenderElement; -class ZTransSubEditor; - -class RenderElementEditor : public TGedFrame -{ - RenderElementEditor(const RenderElementEditor&); // Not implemented - RenderElementEditor& operator=(const RenderElementEditor&); // Not implemented - -protected: - RenderElement* fRE; // fModel dynamic-casted to RenderElementEditor - - TGHorizontalFrame* fHFrame; - TGCheckButton* fRnrSelf; - TGCheckButton* fRnrChildren; - TGColorSelect* fMainColor; - TGNumberEntry* fTransparency; - ZTransSubEditor* fHMTrans; - -public: - RenderElementEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, - UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - ~RenderElementEditor(); - - virtual void SetModel(TObject* obj); - - void DoRnrSelf(); - void DoRnrChildren(); - void DoMainColor(Pixel_t color); - void DoTransparency(); - - ClassDef(RenderElementEditor, 1); // Editor for RenderElement -}; // endclass RenderElementEditor - -} - -#endif diff --git a/EVE/Reve/Reve.cxx b/EVE/Reve/Reve.cxx deleted file mode 100644 index 492a4b35fc1..00000000000 --- a/EVE/Reve/Reve.cxx +++ /dev/null @@ -1,348 +0,0 @@ -// $Header$ - -#include "Reve.h" -#include "RenderElement.h" - -#include -#include -#include -#include - -#include -#include - -#include -#include -#include - -#include -#include - -#include -#include -#include - -//______________________________________________________________________ -// Reve -// - -/**************************************************************************/ -/**************************************************************************/ -namespace Reve { -/**************************************************************************/ - - -// TString .vs. string - -bool operator==(const TString& t, const std::string& s) -{ return (s == t.Data()); } - -bool operator==(const std::string& s, const TString& t) -{ return (s == t.Data()); } - -// Exc - -Exc_t::Exc_t(const std::string& s) : TString(s.c_str()) {} - -// Exc + ops - -Exc_t operator+(const Exc_t &s1, const std::string &s2) -{ Exc_t r(s1); r += s2; return r; } - -Exc_t operator+(const Exc_t &s1, const TString &s2) -{ Exc_t r(s1); r += s2; return r; } - -Exc_t operator+(const Exc_t &s1, const char *s2) -{ Exc_t r(s1); r += s2; return r; } - -// ---------------------------------------------------------------- - -void WarnCaller(const TString& warning) -{ - std::cout << "WRN: " << warning << std::endl; -} - -/**************************************************************************/ -/**************************************************************************/ - -void SetupEnvironment() -{ - // Check if REVESYS exists, try fallback to $ALICE_ROOT/EVE. - // Setup Include and Macro paths. - - static const Exc_t eH("Reve::SetupEnvironment"); - static Bool_t setupDone = kFALSE; - - if (setupDone) { - Info(eH.Data(), "has already been run."); - return; - } - - if(gSystem->Getenv("REVESYS") == 0) { - if(gSystem->Getenv("ALICE_ROOT") != 0) { - Info(eH.Data(), "setting REVESYS from ALICE_ROOT."); - gSystem->Setenv("REVESYS", Form("%s/EVE", gSystem->Getenv("ALICE_ROOT"))); - } else { - Error(eH.Data(), "REVESYS not defined, neither is ALICE_ROOT."); - gSystem->Exit(1); - } - } - if(gSystem->AccessPathName(gSystem->Getenv("REVESYS")) == kTRUE) { - Error(eH.Data(), "REVESYS '%s' does not exist.", gSystem->Getenv("REVESYS")); - gSystem->Exit(1); - } - - TString macPath(gROOT->GetMacroPath()); - macPath += Form(":%s/macros", gSystem->Getenv("REVESYS")); - gInterpreter->AddIncludePath(gSystem->Getenv("REVESYS")); - if(gSystem->Getenv("ALICE_ROOT") != 0) { - macPath += Form(":%s/alice-macros", gSystem->Getenv("REVESYS")); - gInterpreter->AddIncludePath(Form("%s/include", gSystem->Getenv("ALICE_ROOT"))); - gInterpreter->AddIncludePath(gSystem->Getenv("ALICE_ROOT")); - } - gROOT->SetMacroPath(macPath); -} - -void SetupGUI() -{ - TString fld( Form("%s/icons/", gSystem->Getenv("REVESYS")) ); - // printf("foofoo %p %p %p %p\n", - // RenderElement::fgRnrIcons[0],RenderElement::fgRnrIcons[1], - // RenderElement::fgRnrIcons[2],RenderElement::fgRnrIcons[3]); - RenderElement::fgRnrIcons[0] = gClient->GetPicture(fld + "rnr00_t.xpm"); - RenderElement::fgRnrIcons[1] = gClient->GetPicture(fld + "rnr01_t.xpm"); - RenderElement::fgRnrIcons[2] = gClient->GetPicture(fld + "rnr10_t.xpm"); - RenderElement::fgRnrIcons[3] = gClient->GetPicture(fld + "rnr11_t.xpm"); - - RenderElement::fgListTreeIcons[0] = gClient->GetPicture("folder_t.xpm"); - RenderElement::fgListTreeIcons[1] = gClient->GetPicture(fld + "viewer.xpm"); - RenderElement::fgListTreeIcons[2] = gClient->GetPicture(fld + "scene.xpm"); - RenderElement::fgListTreeIcons[3] = gClient->GetPicture(fld + "pointset.xpm"); - RenderElement::fgListTreeIcons[4] = gClient->GetPicture(fld + "track.xpm"); - - gClient->GetMimeTypeList()->AddType("root/tmacro", "Reve::RMacro", - "tmacro_s.xpm", "tmacro_t.xpm", ""); -} - -/**************************************************************************/ - -namespace { - void ChompTail(TString& s, char c='.') { - Ssiz_t p = s.Last(c); - if(p != kNPOS) - s.Remove(p); - } -} - -Bool_t CheckMacro(const Text_t* mac) -{ - // Checks if macro 'mac' is loaded. - - // Axel's advice; now sth seems slow, using old method below for test. - // return gROOT->GetInterpreter()->IsLoaded(mac); - - // Previous version expected function with same name and used ROOT's - // list of global functions. - - TString foo(mac); ChompTail(foo); - /* - if(recreate) { - TCollection* logf = gROOT->GetListOfGlobalFunctions(kFALSE); - logf->SetOwner(); - logf->Clear(); - } - */ - if (gROOT->GetGlobalFunction(foo.Data(), 0, kFALSE) != 0) - return kTRUE; - else - return (gROOT->GetGlobalFunction(foo.Data(), 0, kTRUE) != 0); -} - -void AssertMacro(const Text_t* mac) -{ - // Load and execute macro 'mac' if it has not been loaded yet. - - if(CheckMacro(mac) == kFALSE) { - gROOT->Macro(mac); - } -} - -void Macro(const Text_t* mac) -{ - // Execute macro 'mac'. Do not reload the macro. - - if(CheckMacro(mac) == kFALSE) { - gROOT->LoadMacro(mac); - } - TString foo(mac); ChompTail(foo); foo += "()"; - gROOT->ProcessLine(foo.Data()); -} - -void LoadMacro(const Text_t* mac) -{ - // Makes sure that macro 'mac' is loaded, but do not reload it. - - if(CheckMacro(mac) == kFALSE) { - gROOT->LoadMacro(mac); - } -} - -/**************************************************************************/ -/**************************************************************************/ - -// Pad stack for RINT/GUI thread. -std::list s_Pad_Stack; - -TVirtualPad* PushPad(TVirtualPad* new_gpad, Int_t subpad) -{ - // printf("Reve::PushPad old=%p, new=%p\n", gPad, new_gpad); - s_Pad_Stack.push_back(gPad); - if(new_gpad != 0) - new_gpad->cd(subpad); - else - gPad = 0; - return gPad; -} - -TVirtualPad* PopPad(Bool_t modify_update_p) -{ - // printf("Reve::PopPad old=%p, new=%p\n", gPad, s_Pad_Stack.empty() ? 0 : s_Pad_Stack.back()); - if(s_Pad_Stack.empty()) { - Warning("Reve::PopTPad", "stack empty."); - } else { - if(modify_update_p && gPad != 0) { - gPad->Modified(); - gPad->Update(); - } - gPad = s_Pad_Stack.back(); - s_Pad_Stack.pop_back(); - } - return gPad; -} - -/**************************************************************************/ -// GeoManagerHolder -/**************************************************************************/ - -GeoManagerHolder::GeoManagerHolder(TGeoManager* new_gmgr) : - fManager(gGeoManager) -{ - gGeoManager = new_gmgr; -} - -GeoManagerHolder::~GeoManagerHolder() -{ - gGeoManager = fManager; -} - - -/**************************************************************************/ -// Color management -/**************************************************************************/ - -void ColorFromIdx(Color_t ci, UChar_t* col, Bool_t alpha) -{ - if (ci < 0) { - col[0] = col[1] = col[2] = col[3] = 0; - return; - } - TColor* c = gROOT->GetColor(ci); - if(c) { - col[0] = (UChar_t)(255*c->GetRed()); - col[1] = (UChar_t)(255*c->GetGreen()); - col[2] = (UChar_t)(255*c->GetBlue()); - if (alpha) col[3] = 255; - } -} - -void ColorFromIdx(Float_t f1, Color_t c1, Float_t f2, Color_t c2, - UChar_t* col, Bool_t alpha) -{ - TColor* t1 = gROOT->GetColor(c1); - TColor* t2 = gROOT->GetColor(c2); - if(t1 && t2) { - col[0] = (UChar_t)(255*(f1*t1->GetRed() + f2*t2->GetRed())); - col[1] = (UChar_t)(255*(f1*t1->GetGreen() + f2*t2->GetGreen())); - col[2] = (UChar_t)(255*(f1*t1->GetBlue() + f2*t2->GetBlue())); - if (alpha) col[3] = 255; - } -} - -Color_t* FindColorVar(TObject* obj, const Text_t* varname) -{ - static const Exc_t eH("Reve::FindColorVar"); - - Int_t off = obj->IsA()->GetDataMemberOffset(varname); - if(off == 0) - throw(eH + "could not find member '" + varname + "' in class " + obj->IsA()->GetName() + "."); - return (Color_t*) (((char*)obj) + off); -} - - -/**************************************************************************/ -} // end namespace Reve -/**************************************************************************/ -/**************************************************************************/ - -using namespace Reve; - -/**************************************************************************/ -// ReferenceBackPtr -/**************************************************************************/ - -ClassImp(ReferenceBackPtr) - -ReferenceBackPtr::ReferenceBackPtr() : - ReferenceCount(), - fBackRefs() -{} - -ReferenceBackPtr::~ReferenceBackPtr() -{ - // !!!! Complain if list not empty. -} - -ReferenceBackPtr::ReferenceBackPtr(const ReferenceBackPtr&) : - ReferenceCount(), - fBackRefs() -{} - -ReferenceBackPtr& ReferenceBackPtr::operator=(const ReferenceBackPtr&) -{ - return *this; -} - -/**************************************************************************/ - -void ReferenceBackPtr::IncRefCount(RenderElement* re) -{ - ReferenceCount::IncRefCount(); - fBackRefs.push_back(re); -} - -void ReferenceBackPtr::DecRefCount(RenderElement* re) -{ - static const Exc_t eH("ReferenceBackPtr::DecRefCount "); - - std::list::iterator i = - std::find(fBackRefs.begin(), fBackRefs.end(), re); - if (i != fBackRefs.end()) { - fBackRefs.erase(i); - ReferenceCount::DecRefCount(); - } else { - Warning(eH, Form("render element '%s' not found in back-refs.", - re->GetObject()->GetName())); - } -} - -/**************************************************************************/ - -void ReferenceBackPtr::UpdateBackPtrItems() -{ - std::list::iterator i = fBackRefs.begin(); - while (i != fBackRefs.end()) - { - (*i)->UpdateItems(); - ++i; - } -} diff --git a/EVE/Reve/Reve.h b/EVE/Reve/Reve.h deleted file mode 100644 index d0085c99a3f..00000000000 --- a/EVE/Reve/Reve.h +++ /dev/null @@ -1,165 +0,0 @@ -// $Header$ - -#ifndef REVE_Reve_H -#define REVE_Reve_H - -// #include -#include -#include -#include - -#include -#include -#include -#include -#include - -class TVirtualPad; -class TGeoManager; - -namespace Reve { - -class RenderElement; - -/**************************************************************************/ -// Exceptions, string functions -/**************************************************************************/ - -bool operator==(const TString& t, const std::string& s); -bool operator==(const std::string& s, const TString& t); - -class Exc_t : public std::exception, public TString -{ - public: - Exc_t() {} - Exc_t(const TString& s) : TString(s) {} - Exc_t(const char* s) : TString(s) {} - Exc_t(const std::string& s); - - virtual ~Exc_t() throw () {} - - virtual const char* what() const throw () { return Data(); } - - ClassDef(Exc_t, 1); -}; - -Exc_t operator+(const Exc_t &s1, const std::string &s2); -Exc_t operator+(const Exc_t &s1, const TString &s2); -Exc_t operator+(const Exc_t &s1, const char *s2); - -void WarnCaller(const TString& warning); - - -/**************************************************************************/ -// Environment, Macro functions -/**************************************************************************/ - -void SetupEnvironment(); -void SetupGUI(); - -Bool_t CheckMacro(const Text_t* mac); -void AssertMacro(const Text_t* mac); -void Macro(const Text_t* mac); -void LoadMacro(const Text_t* mac); - - -/**************************************************************************/ -// Local cache for global Pad, GeoManager -/**************************************************************************/ - -TVirtualPad* PushPad(TVirtualPad* new_gpad=0, Int_t subpad=0); -TVirtualPad* PopPad(Bool_t modify_update_p=false); - -class PadHolder -{ -private: - Bool_t fModifyUpdateP; -public: - PadHolder(Bool_t modify_update_p, TVirtualPad* new_gpad=0, Int_t subpad=0) : - fModifyUpdateP(modify_update_p) - { PushPad(new_gpad, subpad); } - - virtual ~PadHolder() { PopPad(fModifyUpdateP); } - - ClassDef(PadHolder, 0); -}; - -class GeoManagerHolder -{ -private: - TGeoManager* fManager; - - GeoManagerHolder(const GeoManagerHolder&); // Not implemented - GeoManagerHolder& operator=(const GeoManagerHolder&); // Not implemented - -public: - GeoManagerHolder(TGeoManager* new_gmgr=0); - virtual ~GeoManagerHolder(); - - ClassDef(GeoManagerHolder, 0); -}; - - -/**************************************************************************/ -// ReferenceCount base-class (interface) -/**************************************************************************/ - -class ReferenceCount -{ -protected: - Int_t fRefCount; - -public: - ReferenceCount() : fRefCount(0) {} - virtual ~ReferenceCount() {} - - ReferenceCount(const ReferenceCount&) : fRefCount(0) {} - ReferenceCount& operator=(const ReferenceCount&) { return *this; } - - void IncRefCount() { ++fRefCount; } - void DecRefCount() { if(--fRefCount <= 0) OnZeroRefCount(); } - - virtual void OnZeroRefCount() { delete this; } - - ClassDef(ReferenceCount, 0); -}; - -/**************************************************************************/ -// ReferenceBackPtr reference-count with back pointers -/**************************************************************************/ - -class ReferenceBackPtr : public ReferenceCount -{ -protected: - std::list fBackRefs; - -public: - ReferenceBackPtr(); - virtual ~ReferenceBackPtr(); - - ReferenceBackPtr(const ReferenceBackPtr&); - ReferenceBackPtr& operator=(const ReferenceBackPtr&); - - using ReferenceCount::IncRefCount; - using ReferenceCount::DecRefCount; - virtual void IncRefCount(RenderElement* re); - virtual void DecRefCount(RenderElement* re); - - virtual void UpdateBackPtrItems(); - - ClassDef(ReferenceBackPtr, 0); -}; - - -/**************************************************************************/ -// Color management -/**************************************************************************/ - -void ColorFromIdx(Color_t ci, UChar_t* col, Bool_t alpha=kTRUE); -void ColorFromIdx(Float_t f1, Color_t c1, Float_t f2, Color_t c2, - UChar_t* col, Bool_t alpha=kTRUE); -Color_t* FindColorVar(TObject* obj, const Text_t* varname); - -} - -#endif diff --git a/EVE/Reve/ReveManager.cxx b/EVE/Reve/ReveManager.cxx deleted file mode 100644 index 475cc4685b2..00000000000 --- a/EVE/Reve/ReveManager.cxx +++ /dev/null @@ -1,489 +0,0 @@ -#include "ReveManager.h" - -#include -#include -#include -#include - -#include -#include - -#include -#include -#include -#include -#include -#include -#include - -#include - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include "TVirtualGL.h" -#include "TPluginManager.h" - -#include - -using namespace Reve; -using namespace Reve; - -Reve::ReveManager* gReve = 0; - -/**************************************************************************/ - -ReveManager::ReveManager(UInt_t w, UInt_t h) : - fBrowser (0), - fEditor (0), - fStatusBar (0), - - fMacroFolder (0), - - fViewers (0), - fScenes (0), - fViewer (0), - fGlobalScene (0), - fEventScene (0), - fCurrentEvent (0), - - fRedrawDisabled (0), - fResetCameras (kFALSE), - fDropLogicals (kFALSE), - fKeepEmptyCont (kFALSE), - fTimerActive (kFALSE), - fRedrawTimer (), - - fGeometries () -{ - // Constructor. - - static const Exc_t eH("ReveManager::ReveManager "); - - if (gReve != 0) - throw(eH + "There can be only one!"); - - gReve = this; - - fRedrawTimer.Connect("Timeout()", "Reve::ReveManager", this, "DoRedraw3D()"); - fMacroFolder = new TFolder("EVE", "Visualization macros"); - gROOT->GetListOfBrowsables()->Add(fMacroFolder); - - - // Build GUI - fBrowser = new RGBrowser(w, h); - fStatusBar = fBrowser->GetStatusBar(); - - // ListTreeEditor - fBrowser->StartEmbedding(0); - fLTEFrame = new RGLTEFrame("REVE"); - fBrowser->StopEmbedding(); - fBrowser->SetTabTitle("Reve", 0); - fEditor = fLTEFrame->fEditor; - - // GL viewer - fBrowser->StartEmbedding(1); - TGLSAViewer* glv = new TGLSAViewer(gClient->GetRoot(), 0, fEditor); - //glv->GetFrame()->SetCleanup(kNoCleanup); - glv->ToggleEditObject(); - fBrowser->StopEmbedding(); - fBrowser->SetTabTitle("GLViewer", 1); - - // Finalize it - fBrowser->InitPlugins(); - fBrowser->MapWindow(); - - // -------------------------------- - - fViewers = new ViewerList("Viewers"); - fViewers->IncDenyDestroy(); - AddToListTree(fViewers, kTRUE); - - fViewer = new Viewer("GL-One"); - fViewer->SetGLViewer(glv); - fViewer->IncDenyDestroy(); - AddRenderElement(fViewer, fViewers); - - fScenes = new SceneList ("Scenes"); - fScenes->IncDenyDestroy(); - AddToListTree(fScenes, kTRUE); - - fGlobalScene = new Scene("Geometry scene"); - fGlobalScene->IncDenyDestroy(); - AddRenderElement(fGlobalScene, fScenes); - - fEventScene = new Scene("Event scene"); - fEventScene->IncDenyDestroy(); - AddRenderElement(fEventScene, fScenes); - - fViewer->AddScene(fGlobalScene); - fViewer->AddScene(fEventScene); - - /**************************************************************************/ - /**************************************************************************/ - - fEditor->DisplayObject(GetGLViewer()); - - gSystem->ProcessEvents(); -} - -ReveManager::~ReveManager() -{ - // Destructor. -} - -/**************************************************************************/ - -TCanvas* ReveManager::AddCanvasTab(const char* name) -{ - // Add a new canvas tab. - - fBrowser->StartEmbedding(1, -1); - TCanvas* c = new TCanvas; - fBrowser->StopEmbedding(); - fBrowser->SetTabTitle(name, 1, -1); - - return c; -} - -TGWindow* ReveManager::GetMainWindow() const -{ - // Get the main window, i.e. the first created reve-browser. - - return fBrowser; -} - -TGLViewer* ReveManager::GetGLViewer() const -{ - // Get default TGLViewer. - - return fViewer->GetGLViewer(); -} - -Viewer* ReveManager::SpawnNewViewer(const Text_t* name, const Text_t* title, - Bool_t embed) -{ - // Create a new GL viewer. - - Viewer* v = new Viewer(name, title); - - if (embed) fBrowser->StartEmbedding(1); - v->SpawnGLViewer(gClient->GetRoot(), embed ? fEditor : 0); - v->IncDenyDestroy(); - if (embed) fBrowser->StopEmbedding(), fBrowser->SetTabTitle(name, 1); - AddRenderElement(v, fViewers); - return v; -} - -Scene* ReveManager::SpawnNewScene(const Text_t* name, const Text_t* title) -{ - // Create a new scene. - - Scene* s = new Scene(name, title); - AddRenderElement(s, fScenes); - return s; -} - -/**************************************************************************/ -// Macro management -/**************************************************************************/ - -TMacro* ReveManager::GetMacro(const Text_t* name) const -{ - return dynamic_cast(fMacroFolder->FindObject(name)); -} - -/**************************************************************************/ -// Editor -/**************************************************************************/ - -void ReveManager::EditRenderElement(RenderElement* rnr_element) -{ - static const Exc_t eH("ReveManager::EditRenderElement "); - - fEditor->DisplayRenderElement(rnr_element); -} - -/**************************************************************************/ -// 3D Pad management -/**************************************************************************/ - -void ReveManager::RegisterRedraw3D() -{ - // Register a request for 3D redraw. - - fRedrawTimer.Start(0, kTRUE); - fTimerActive = true; -} - -void ReveManager::DoRedraw3D() -{ - // Perform 3D redraw of scenes and viewers whose contents has - // changed. - - // printf("ReveManager::DoRedraw3D redraw triggered\n"); - - fScenes ->RepaintChangedScenes(); - fViewers->RepaintChangedViewers(fResetCameras, fDropLogicals); - - fResetCameras = kFALSE; - fDropLogicals = kFALSE; - - fTimerActive = kFALSE; -} - -void ReveManager::FullRedraw3D(Bool_t resetCameras, Bool_t dropLogicals) -{ - // Perform 3D redraw of all scenes and viewers. - - fScenes ->RepaintAllScenes(); - fViewers->RepaintAllViewers(resetCameras, dropLogicals); -} - -/**************************************************************************/ - -void ReveManager::RenderElementChanged(RenderElement* rnr_element) -{ - std::list scenes; - rnr_element->CollectSceneParents(scenes); - ScenesChanged(scenes); -} - -void ReveManager::ScenesChanged(std::list& scenes) -{ - for (RenderElement::List_i s=scenes.begin(); s!=scenes.end(); ++s) - ((Scene*)*s)->Changed(); -} - -/**************************************************************************/ - -int ReveManager::SpawnGuiAndRun(int argc, char **argv) -{ - Int_t w = 1024; - Int_t h = 768; - - TRint theApp("App", &argc, argv); - - Reve::SetupGUI(); - /* gReve = */ new ReveManager(w, h); - - run_loop: - try { - theApp.Run(); - } - catch(Exc_t& exc) { - gReve->SetStatusLine(exc.Data()); - fprintf(stderr, "Exception: %s\n", exc.Data()); - goto run_loop; - } - return 0; -} - -void ReveManager::SpawnGui() -{ - Int_t w = 1024; - Int_t h = 768; - - Reve::SetupGUI(); - /* gReve = */ new ReveManager(w, h); -} - -/**************************************************************************/ -/**************************************************************************/ - -TGListTree* ReveManager::GetListTree() const -{ - return fLTEFrame->fListTree; -} - -TGListTreeItem* -ReveManager::AddToListTree(RenderElement* re, Bool_t open, TGListTree* lt) -{ - // Add rnr-el as a top-level to a list-tree. - // Please add a single copy of a render-element as a top level - // or we will have to check for that, too. - - if (lt == 0) lt = GetListTree(); - TGListTreeItem* lti = re->AddIntoListTree(lt, (TGListTreeItem*)0); - if (open) lt->OpenItem(lti); - return lti; -} - -void ReveManager::RemoveFromListTree(RenderElement* re, TGListTree* lt, TGListTreeItem* lti) -{ - // Remove top-level rnr-el from list-tree with specified tree-item. - - static const Exc_t eH("ReveManager::RemoveFromListTree "); - - if (lti->GetParent()) - throw(eH + "not a top-level item."); - - re->RemoveFromListTree(lt, 0); -} - -/**************************************************************************/ - -TGListTreeItem* ReveManager::AddEvent(EventBase* event) -{ - fCurrentEvent = event; - fCurrentEvent->IncDenyDestroy(); - AddRenderElement(fCurrentEvent, fEventScene); - return AddToListTree(event, kTRUE); -} - -TGListTreeItem* ReveManager::AddRenderElement(RenderElement* rnr_element, - RenderElement* parent) -{ - if (parent == 0) { - if (fCurrentEvent == 0) - AddEvent(new EventBase("Event", "Auto-created event directory")); - parent = fCurrentEvent; - } - - return parent->AddElement(rnr_element); -} - -TGListTreeItem* ReveManager::AddGlobalRenderElement(RenderElement* rnr_element, - RenderElement* parent) -{ - if (parent == 0) - parent = fGlobalScene; - - return parent->AddElement(rnr_element); -} - -/**************************************************************************/ - -void ReveManager::RemoveRenderElement(RenderElement* rnr_element, - RenderElement* parent) -{ - parent->RemoveElement(rnr_element); -} - -void ReveManager::PreDeleteRenderElement(RenderElement* rnr_element) -{ - if (fEditor->GetRnrElement() == rnr_element) - fEditor->DisplayObject(0); -} - -/**************************************************************************/ - -void ReveManager::RenderElementSelect(RenderElement* rnr_element) -{ - EditRenderElement(rnr_element); -} - -Bool_t ReveManager::RenderElementPaste(RenderElement* rnr_element) -{ - RenderElement* src = fEditor->GetRnrElement(); - if (src) - return rnr_element->HandleElementPaste(src); - return kFALSE; -} - -void ReveManager::RenderElementChecked(RenderElement* rnrEl, Bool_t state) -{ - rnrEl->SetRnrState(state); - - if (fEditor->GetModel() == rnrEl->GetEditorObject()) - fEditor->DisplayRenderElement(rnrEl); - - rnrEl->ElementChanged(); -} - -/**************************************************************************/ - -void ReveManager::NotifyBrowser(TGListTreeItem* parent_lti) -{ - TGListTree* lt = GetListTree(); - if (parent_lti) - lt->OpenItem(parent_lti); - lt->ClearViewPort(); -} - -void ReveManager::NotifyBrowser(RenderElement* parent) -{ - TGListTreeItem* parent_lti = parent ? parent->FindListTreeItem(GetListTree()) : 0; - NotifyBrowser(parent_lti); -} - -/**************************************************************************/ -// GeoManager registration -/**************************************************************************/ - -TGeoManager* ReveManager::GetGeometry(const TString& filename) -{ - static const Exc_t eH("ReveManager::GetGeometry "); - - TString exp_filename = filename; - gSystem->ExpandPathName(exp_filename); - printf("%s loading: '%s' -> '%s'.\n", eH.Data(), - filename.Data(), exp_filename.Data()); - - std::map::iterator g = fGeometries.find(filename); - if (g != fGeometries.end()) { - return g->second; - } else { - if (gSystem->AccessPathName(exp_filename, kReadPermission)) - throw(eH + "file '" + exp_filename + "' not readable."); - gGeoManager = 0; - TGeoManager::Import(filename); - if (gGeoManager == 0) - throw(eH + "GeoManager import failed."); - gGeoManager->GetTopVolume()->VisibleDaughters(1); - - // Import colors exported by Gled, if they exist. - { - TFile f(exp_filename, "READ"); - TObjArray* collist = (TObjArray*) f.Get("ColorList"); - f.Close(); - if (collist != 0) { - TIter next(gGeoManager->GetListOfVolumes()); - TGeoVolume* vol; - while ((vol = (TGeoVolume*) next()) != 0) - { - Int_t oldID = vol->GetLineColor(); - TColor* col = (TColor*)collist->At(oldID); - Float_t r, g, b; - col->GetRGB(r, g, b); - Int_t newID = TColor::GetColor(r,g,b); - vol->SetLineColor(newID); - } - } - } - - fGeometries[filename] = gGeoManager; - return gGeoManager; - } -} - -/**************************************************************************/ -// Testing exceptions -/**************************************************************************/ - -void ReveManager::SetStatusLine(const char* text) -{ - fStatusBar->SetText(text); -} - -void ReveManager::ThrowException(const char* text) -{ - static const Exc_t eH("ReveManager::ThrowException "); - - throw(eH + text); -} diff --git a/EVE/Reve/ReveManager.h b/EVE/Reve/ReveManager.h deleted file mode 100644 index 07f197b1cb9..00000000000 --- a/EVE/Reve/ReveManager.h +++ /dev/null @@ -1,176 +0,0 @@ -// $Header$ - -#ifndef REVE_ReveManager_H -#define REVE_ReveManager_H - -#include -#include -#include -#include -#include - -#include -#include - -class TMacro; -class TFolder; -class TCanvas; - -class TGTab; -class TGStatusBar; -class TGListTree; -class TGListTreeItem; -class TGStatusBar; -class TGWindow; - -class TGLViewer; - -namespace Reve { - -class RGLTEFrame; -class RGBrowser; -class RGEditor; - -class RenderElement; -class PadPrimitive; - -class Viewer; class ViewerList; -class Scene; class SceneList; - -class EventBase; - - -class ReveManager -{ - ReveManager(const ReveManager&); // Not implemented - ReveManager& operator=(const ReveManager&); // Not implemented - -public: - class RedrawDisabler - { - private: - RedrawDisabler(const RedrawDisabler&); // Not implemented - RedrawDisabler& operator=(const RedrawDisabler&); // Not implemented - - ReveManager* fFrame; - public: - RedrawDisabler(ReveManager* f) : fFrame(f) - { if (fFrame) fFrame->DisableRedraw(); } - ~RedrawDisabler() - { if (fFrame) fFrame->EnableRedraw(); } - }; - -private: - - RGBrowser *fBrowser; - RGLTEFrame *fLTEFrame; - RGEditor *fEditor; - TGStatusBar *fStatusBar; - - TFolder *fMacroFolder; - - ViewerList *fViewers; - SceneList *fScenes; - - Viewer *fViewer; // First / default gl-viewer. - Scene *fGlobalScene; - Scene *fEventScene; - EventBase *fCurrentEvent; - - Int_t fRedrawDisabled; - Bool_t fFullRedraw; - Bool_t fResetCameras; - Bool_t fDropLogicals; - Bool_t fKeepEmptyCont; - Bool_t fTimerActive; - TTimer fRedrawTimer; - -protected: - std::map fGeometries; - -public: - ReveManager(UInt_t w, UInt_t h); - virtual ~ReveManager(); - - RGBrowser* GetBrowser() const { return fBrowser; } - RGLTEFrame* GetLTEFrame() const { return fLTEFrame; } - RGEditor* GetEditor() const { return fEditor; } - TGStatusBar* GetStatusBar() const { return fStatusBar; } - - SceneList* GetScenes() const { return fScenes; } - ViewerList* GetViewers() const { return fViewers; } - - Viewer* GetDefViewer() const { return fViewer; } - Scene* GetGlobalScene() const { return fGlobalScene; } - Scene* GetEventScene() const { return fEventScene; } - EventBase* GetCurrentEvent() const { return fCurrentEvent; } - - TCanvas* AddCanvasTab(const char* name); - TGWindow* GetMainWindow() const; - TGLViewer* GetGLViewer() const; - Viewer* SpawnNewViewer(const Text_t* name, const Text_t* title="", Bool_t embed=kTRUE); - Scene* SpawnNewScene(const Text_t* name, const Text_t* title=""); - - TFolder* GetMacroFolder() const { return fMacroFolder; } - TMacro* GetMacro(const Text_t* name) const; - - void EditRenderElement(RenderElement* rnr_element); - - void DisableRedraw() { ++fRedrawDisabled; } - void EnableRedraw() { --fRedrawDisabled; if(fRedrawDisabled <= 0) Redraw3D(); } - - void Redraw3D(Bool_t resetCameras=kFALSE, Bool_t dropLogicals=kFALSE) - { - if(fRedrawDisabled <= 0 && !fTimerActive) RegisterRedraw3D(); - if(resetCameras) fResetCameras = kTRUE; - if(dropLogicals) fDropLogicals = kTRUE; - } - void RegisterRedraw3D(); - void DoRedraw3D(); - void FullRedraw3D(Bool_t resetCameras=kFALSE, Bool_t dropLogicals=kFALSE); - - Bool_t GetKeepEmptyCont() const { return fKeepEmptyCont; } - void SetKeepEmptyCont(Bool_t k) { fKeepEmptyCont = k; } - - - void RenderElementChanged(RenderElement* rnr_element); - void ScenesChanged(std::list& scenes); - - static int SpawnGuiAndRun(int argc, char **argv); - static void SpawnGui(); - - // These are more like ReveManager stuff. - TGListTree* GetListTree() const; - TGListTreeItem* AddToListTree(RenderElement* re, Bool_t open, TGListTree* lt=0); - void RemoveFromListTree(RenderElement* re, TGListTree* lt, TGListTreeItem* lti); - - TGListTreeItem* AddEvent(EventBase* event); - TGListTreeItem* AddRenderElement(RenderElement* rnr_element, - RenderElement* parent=0); - TGListTreeItem* AddGlobalRenderElement(RenderElement* rnr_element, - RenderElement* parent=0); - - void RemoveRenderElement(RenderElement* rnr_element, RenderElement* parent); - void PreDeleteRenderElement(RenderElement* rnr_element); - - void RenderElementSelect(RenderElement* rnr_element); - Bool_t RenderElementPaste(RenderElement* rnr_element); - void RenderElementChecked(RenderElement* rnrEl, Bool_t state); - - void NotifyBrowser(TGListTreeItem* parent_lti=0); - void NotifyBrowser(RenderElement* parent); - - // Hmmph ... geometry management? - TGeoManager* GetGeometry(const TString& filename); - - void SetStatusLine(const char* text); - void ThrowException(const char* text="foo"); - - ClassDef(ReveManager, 0); // Reve application manager. -}; - -} // namespace Reve - -extern Reve::ReveManager* gReve; - -#endif diff --git a/EVE/Reve/Scene.cxx b/EVE/Reve/Scene.cxx deleted file mode 100644 index 7150fc62c70..00000000000 --- a/EVE/Reve/Scene.cxx +++ /dev/null @@ -1,112 +0,0 @@ -// $Header$ - -#include "Scene.h" -#include "Viewer.h" -#include - -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// Reve::Scene -// - -ClassImp(Scene) - -Scene::Scene(const Text_t* n, const Text_t* t) : - RenderElementList(n, t), - fPad (0), - fGLScene(0), - fChanged (kFALSE), - fSmartRefresh (kTRUE) -{ - fPad = new Pad; - fPad->GetListOfPrimitives()->Add(this); - fGLScene = new TGLScenePad(fPad); - fGLScene->SetName(n); - fGLScene->SetAutoDestruct(kFALSE); -} - -Scene::~Scene() -{ - gReve->GetViewers()->SceneDestructing(this); -} - -/**************************************************************************/ - -void Scene::CollectSceneParents(List_t& scenes) -{ - scenes.push_back(this); -} - -/**************************************************************************/ - -void Scene::Repaint() -{ - fGLScene->PadPaint(fPad); - fChanged = kFALSE; -} - -/**************************************************************************/ - -void Scene::SetName(const Text_t* n) -{ - RenderElementList::SetName(n); - fGLScene->SetName(n); -} - -void Scene::Paint(Option_t* option) -{ - if (fRnrChildren) - { - for(List_i i=fChildren.begin(); i!=fChildren.end(); ++i) - (*i)->PadPaint(option); - } -} - - -/**************************************************************************/ -/**************************************************************************/ -/**************************************************************************/ - -//______________________________________________________________________ -// Reve::SceneList -// - -ClassImp(SceneList) - -SceneList::SceneList(const Text_t* n, const Text_t* t) : - RenderElementList(n, t) -{ - SetChildClass(Scene::Class()); -} - -SceneList::~SceneList() -{} - -/**************************************************************************/ - -void SceneList::RepaintChangedScenes() -{ - for(List_i i=fChildren.begin(); i!=fChildren.end(); ++i) - { - Scene* s = (Scene*) *i; - if (s->IsChanged()) - { - // printf(" Scene '%s' changed ... repainting.\n", s->GetName()); - s->Repaint(); - } - } -} - -void SceneList::RepaintAllScenes() -{ - for(List_i i=fChildren.begin(); i!=fChildren.end(); ++i) - { - Scene* s = (Scene*) *i; - // printf(" Scene '%s' repainting.\n", s->GetName()); - s->Repaint(); - } -} diff --git a/EVE/Reve/Scene.h b/EVE/Reve/Scene.h deleted file mode 100644 index 8066990864f..00000000000 --- a/EVE/Reve/Scene.h +++ /dev/null @@ -1,76 +0,0 @@ -// $Header$ - -#ifndef REVE_Scene_H -#define REVE_Scene_H - -#include -#include - -class TGLScenePad; - -namespace Reve { - -/**************************************************************************/ -// Scene -/**************************************************************************/ - -class Scene : public RenderElementList -{ -private: - Scene(const Scene&); // Not implemented - Scene& operator=(const Scene&); // Not implemented - -protected: - Pad *fPad; - TGLScenePad *fGLScene; - - Bool_t fChanged; - Bool_t fSmartRefresh; - -public: - Scene(const Text_t* n="Scene", const Text_t* t=""); - virtual ~Scene(); - - virtual void CollectSceneParents(List_t& scenes); - - void Changed() { fChanged = kTRUE; } - Bool_t IsChanged() const { return fChanged; } - void Repaint(); - - TGLScenePad* GetGLScene() const { return fGLScene; } - void SetGLScene(TGLScenePad* s) { fGLScene = s; } - - virtual void SetName(const Text_t* n); - virtual void Paint(Option_t* option = ""); - - virtual const TGPicture* GetListTreeIcon() { return RenderElement::fgListTreeIcons[2]; } - - ClassDef(Scene, 0); // Reve representation of TGLScene. -}; // endclass Scene - - -/**************************************************************************/ -// SceneList -/**************************************************************************/ - -class SceneList : public RenderElementList -{ -private: - SceneList(const SceneList&); // Not implemented - SceneList& operator=(const SceneList&); // Not implemented - -protected: - -public: - SceneList(const Text_t* n="SceneList", const Text_t* t=""); - virtual ~SceneList(); - - void RepaintChangedScenes(); - void RepaintAllScenes(); - - ClassDef(SceneList, 0); // List of Scenes. -}; // endclass SceneList - -} - -#endif diff --git a/EVE/Reve/SceneInfo.cxx b/EVE/Reve/SceneInfo.cxx deleted file mode 100644 index c2613b565d6..00000000000 --- a/EVE/Reve/SceneInfo.cxx +++ /dev/null @@ -1,66 +0,0 @@ -// $Header$ - -#include "SceneInfo.h" -#include "Scene.h" -#include "ReveManager.h" - -#include - -using namespace Reve; - -//______________________________________________________________________ -// SceneInfo -// - -ClassImp(SceneInfo) - -SceneInfo::SceneInfo(Viewer* viewer, Scene* scene, TGLSceneInfo* sinfo) : - RenderElement (), - TNamed (Form("SI - %s", scene->GetName()), - Form("SceneInfo of scene '%s'", scene->GetName())), - fViewer (viewer), - fScene (scene), - fGLSceneInfo (sinfo) -{} - -SceneInfo::~SceneInfo() -{} - -/**************************************************************************/ - -TGLSceneBase* SceneInfo::GetGLScene() const -{ - return fGLSceneInfo->GetScene(); -} - -/**************************************************************************/ - -void SceneInfo::SetRnrSelf(Bool_t rnr) -{ - RenderElement::SetRnrSelf(rnr); - fGLSceneInfo->SetActive(fRnrSelf); -} - -void SceneInfo::SetRnrState(Bool_t rnr) -{ - RenderElement::SetRnrState(rnr); - fGLSceneInfo->SetActive(fRnrSelf); -} - -/**************************************************************************/ - -Bool_t SceneInfo::AcceptRenderElement(RenderElement* /*el*/) -{ - static const Exc_t eH("SceneInfo::AcceptRenderElement "); - - gReve->SetStatusLine(eH + "this class does not accept children."); - return kFALSE; -} - -Bool_t SceneInfo::HandleElementPaste(RenderElement* /*el*/) -{ - static const Exc_t eH("SceneInfo::HandleElementPaste "); - - gReve->SetStatusLine(eH + "this class does not accept children."); - return kFALSE; -} diff --git a/EVE/Reve/SceneInfo.h b/EVE/Reve/SceneInfo.h deleted file mode 100644 index f27ae7ec2fe..00000000000 --- a/EVE/Reve/SceneInfo.h +++ /dev/null @@ -1,48 +0,0 @@ -// $Header$ - -#ifndef REVE_SceneInfo_H -#define REVE_SceneInfo_H - -#include - -class TGLSceneBase; -class TGLSceneInfo; - -namespace Reve { - -class Viewer; -class Scene; - -class SceneInfo : public RenderElement, - public TNamed -{ -private: - SceneInfo(const SceneInfo&); // Not implemented - SceneInfo& operator=(const SceneInfo&); // Not implemented - -protected: - Viewer *fViewer; - Scene *fScene; - TGLSceneInfo *fGLSceneInfo; - -public: - SceneInfo(Viewer* viewer, Scene* scene, TGLSceneInfo* sinfo); - virtual ~SceneInfo(); - - Viewer * GetViewer() const { return fViewer; } - Scene * GetScene() const { return fScene; } - TGLSceneInfo * GetGLSceneInfo() const { return fGLSceneInfo; } - TGLSceneBase * GetGLScene() const; - - virtual void SetRnrSelf(Bool_t rnr); - virtual void SetRnrState(Bool_t rnr); - - virtual Bool_t AcceptRenderElement(RenderElement* el); - virtual Bool_t HandleElementPaste(RenderElement* el); - - ClassDef(SceneInfo, 0); // Reve representation of TGLSceneInfo. -}; // endclass SceneInfo - -} - -#endif diff --git a/EVE/Reve/StraightLineSet.cxx b/EVE/Reve/StraightLineSet.cxx deleted file mode 100644 index 78566ca769a..00000000000 --- a/EVE/Reve/StraightLineSet.cxx +++ /dev/null @@ -1,166 +0,0 @@ -// $Header$ - -#include "StraightLineSet.h" - -#include -#include -#include -#include - -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// StraightLineSet -// - -ClassImp(StraightLineSet) - -StraightLineSet::StraightLineSet(const Text_t* n, const Text_t* t): - RenderElement (), - TNamed (n, t), - - fLinePlex (sizeof(Line), 4), - fMarkerPlex (sizeof(Marker), 8), - fOwnLinesIds (kFALSE), - fOwnMarkersIds (kFALSE), - fRnrMarkers (kTRUE), - fRnrLines (kTRUE), - fLastLine (0), - fTrans (kFALSE), - fHMTrans () -{ - fMainColorPtr = &fLineColor; - fLineColor = 4; - fMarkerColor = 2; - fMarkerStyle = 20; -} - -/**************************************************************************/ - -void StraightLineSet::AddLine(Float_t x1, Float_t y1, Float_t z1, - Float_t x2, Float_t y2, Float_t z2) -{ - fLastLine = new (fLinePlex.NewAtom()) Line(x1, y1, z1, x2, y2, z2); -} - -/**************************************************************************/ - -void StraightLineSet::AddMarker(Int_t line, Float_t pos) -{ - /*Marker* marker = */new (fMarkerPlex.NewAtom()) Marker(line, pos); -} - -/**************************************************************************/ - -void StraightLineSet::ComputeBBox() -{ - static const Exc_t eH("StraightLineSet::ComputeBBox "); - if(fLinePlex.Size() == 0) { - BBoxZero(); - return; - } - - BBoxInit(); - - VoidCPlex::iterator li(fLinePlex); - while (li.next()) { - BBoxCheckPoint(((Line*)li())->fV1); - BBoxCheckPoint(((Line*)li())->fV2); - } -} - -/**************************************************************************/ - -void StraightLineSet::Paint(Option_t* /*option*/) -{ - static const Exc_t eH("StraightLineSet::Paint "); - - TBuffer3D buff(TBuffer3DTypes::kGeneric); - - // Section kCore - buff.fID = this; - buff.fColor = fLineColor; - buff.fTransparency = 0; - buff.fLocalFrame = kFALSE; - fHMTrans.SetBuffer3D(buff); - buff.SetSectionsValid(TBuffer3D::kCore); - - Int_t reqSections = gPad->GetViewer3D()->AddObject(buff); - if (reqSections != TBuffer3D::kNone) - Error(eH, "only direct GL rendering supported."); -} - -/**************************************************************************/ - -TClass* StraightLineSet::ProjectedClass() const -{ - return NLTSLineSet::Class(); -} - -//______________________________________________________________________ -// NLTSLineSet -// - -ClassImp(NLTSLineSet) - -NLTSLineSet::NLTSLineSet() : StraightLineSet(), NLTProjected () -{} - -/**************************************************************************/ - -void NLTSLineSet::SetProjection(NLTProjector* proj, NLTProjectable* model) -{ - NLTProjected::SetProjection(proj, model); - - // copy line and marker attributes - * (TAttMarker*)this = * dynamic_cast(fProjectable); - * (TAttLine*)this = * dynamic_cast(fProjectable); -} -/**************************************************************************/ - -void NLTSLineSet::UpdateProjection() -{ - NLTProjection& proj = * fProjector->GetProjection(); - StraightLineSet& orig = * dynamic_cast(fProjectable); - - // lines - Int_t NL = orig.GetLinePlex().Size(); - fLinePlex.Reset(sizeof(Line), NL); - Line* l; - Float_t p1[3]; - Float_t p2[3]; - VoidCPlex::iterator li(orig.GetLinePlex()); - - Double_t s1, s2, s3; - orig.RefHMTrans().GetScale(s1, s2, s3); - ZTrans mx; mx.Scale(s1, s2, s3); - Double_t x, y, z; - orig.RefHMTrans().GetPos(x, y,z); - while (li.next()) - { - l = (Line*) li(); - p1[0] = l->fV1[0]; p1[1] = l->fV1[1]; p1[2] = l->fV1[2]; - p2[0] = l->fV2[0]; p2[1] = l->fV2[1]; p2[2] = l->fV2[2]; - mx.MultiplyIP(p1); - mx.MultiplyIP(p2); - p1[0] += x; p1[1] += y; p1[2] += z; - p2[0] += x; p2[1] += y; p2[2] += z; - proj.ProjectPointFv(p1); - proj.ProjectPointFv(p2); - AddLine(p1[0], p1[1], p1[2], p2[0], p2[1], p2[2]); - } - - // markers - Int_t NM = orig.GetMarkerPlex().Size(); - fMarkerPlex.Reset(sizeof(Marker), NM); - Marker* m; - VoidCPlex::iterator mi(orig.GetMarkerPlex()); - while (mi.next()) - { - m = (Marker*) mi(); - AddMarker(m->fLineID, m->fPos); - } -} diff --git a/EVE/Reve/StraightLineSet.h b/EVE/Reve/StraightLineSet.h deleted file mode 100644 index 46af2810fe7..00000000000 --- a/EVE/Reve/StraightLineSet.h +++ /dev/null @@ -1,138 +0,0 @@ -// $Header$ - -#ifndef REVE_StraightLineSet_H -#define REVE_StraightLineSet_H - -#include - -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include -class TRandom; - -namespace Reve { - -class StraightLineSet : public RenderElement, - public NLTProjectable, - public TNamed, - public TQObject, - public TAtt3D, - public TAttLine, - public TAttMarker, - public TAttBBox -{ -private: - StraightLineSet(const StraightLineSet&); // Not implemented - StraightLineSet& operator=(const StraightLineSet&); // Not implemented - -public: - struct Line - { - Float_t fV1[3]; - Float_t fV2[3]; - TRef fRef; - - Line(Float_t x1, Float_t y1, Float_t z1,Float_t x2, Float_t y2, Float_t z2) - { - fV1[0] = x1, fV1[1] = y1, fV1[2] = z1; - fV2[0] = x2, fV2[1] = y2, fV2[2] = z2; - } - }; - - struct Marker - { - Int_t fLineID; - Float_t fPos; - TRef fRef; - - Marker(Int_t lineID, Float_t pos) : fLineID(lineID), fPos(pos) {}; - }; - -protected: - VoidCPlex fLinePlex; - VoidCPlex fMarkerPlex; - - Bool_t fOwnLinesIds; //Flag specifying if id-objects are owned by the QuadSet - Bool_t fOwnMarkersIds; //Flag specifying if id-objects are owned by the QuadSet - - Bool_t fRnrMarkers; - Bool_t fRnrLines; - - Line* fLastLine; //! - - Bool_t fTrans; - ZTrans fHMTrans; -public: - StraightLineSet(const Text_t* n="StraightLine", const Text_t* t=""); - virtual ~StraightLineSet() {} - - virtual Bool_t CanEditMainHMTrans() { return kTRUE; } - virtual ZTrans* PtrMainHMTrans() { return &fHMTrans; } - - ZTrans& RefHMTrans() { return fHMTrans; } - void SetTransMatrix(Double_t* carr) { fHMTrans.SetFrom(carr); } - void SetTransMatrix(const TGeoMatrix& mat) { fHMTrans.SetFrom(mat); } - - - virtual void SetLineColor(Color_t col) { SetMainColor(col); } - - - void AddLine(Float_t x1, Float_t y1, Float_t z1, Float_t x2, Float_t y2, Float_t z2); - void AddMarker(Int_t lineID, Float_t pos); - - VoidCPlex& GetLinePlex() { return fLinePlex; } - VoidCPlex& GetMarkerPlex() { return fMarkerPlex; } - - virtual void ComputeBBox(); - virtual void Paint(Option_t* option=""); - - virtual void SetRnrMarkers(Bool_t x) {fRnrMarkers = x;} - virtual Bool_t GetRnrMarkers(){return fRnrMarkers;} - - virtual void SetRnrLines(Bool_t x) {fRnrLines = x;} - virtual Bool_t GetRnrLines(){return fRnrLines;} - - virtual TClass* ProjectedClass() const; - - ClassDef(StraightLineSet, 1); // Set of lines and optional markers. -}; // endclass StraightLineSet - - - -/**************************************************************************/ - -class NLTSLineSet : public StraightLineSet, - public NLTProjected -{ -private: - NLTSLineSet(const NLTSLineSet&); // Not implemented - NLTSLineSet& operator=(const NLTSLineSet&); // Not implemented - -protected: - -public: - NLTSLineSet(); - virtual ~NLTSLineSet() {} - - virtual Bool_t CanEditMainHMTrans() { return kFALSE; } - - virtual void SetProjection(NLTProjector* proj, NLTProjectable* model); - - virtual void UpdateProjection(); - - ClassDef(NLTSLineSet, 1); // NLT projected StraightLineSet. -}; // endclass NLTSLineSet - -} // Reve - -#endif diff --git a/EVE/Reve/StraightLineSetEditor.cxx b/EVE/Reve/StraightLineSetEditor.cxx deleted file mode 100644 index 48cce20dba5..00000000000 --- a/EVE/Reve/StraightLineSetEditor.cxx +++ /dev/null @@ -1,76 +0,0 @@ -// $Header$ - -#include "StraightLineSetEditor.h" -#include - -#include -#include - -#include -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// StraightLineSetEditor -// - -ClassImp(StraightLineSetEditor) - -StraightLineSetEditor::StraightLineSetEditor(const TGWindow *p, Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - fM(0) - // Initialize widget pointers to 0 -{ - MakeTitle("StraightLineSet"); - - TGHorizontalFrame* frame = new TGHorizontalFrame(this); - - fRnrMarkers = new TGCheckButton(frame, "RnrMarkers"); - frame->AddFrame(fRnrMarkers, new TGLayoutHints(kLHintsLeft, 1, 2, 1, 1)); - fRnrMarkers->Connect - ("Toggled(Bool_t)", - "Reve::StraightLineSetEditor", this, "DoRnrMarkers()"); - - fRnrLines = new TGCheckButton(frame, "RnrLines"); - frame->AddFrame(fRnrLines, new TGLayoutHints(kLHintsLeft, 2, 1, 1, 1)); - fRnrLines->Connect - ("Toggled(Bool_t)", - "Reve::StraightLineSetEditor", this, "DoRnrLines()"); - - AddFrame(frame, new TGLayoutHints(kLHintsTop, 0, 0, 0, 0)); -} - -StraightLineSetEditor::~StraightLineSetEditor() -{} - -/**************************************************************************/ - -void StraightLineSetEditor::SetModel(TObject* obj) -{ - fM = dynamic_cast(obj); - - // Set values of widgets - fRnrMarkers->SetState(fM->GetRnrMarkers() ? kButtonDown : kButtonUp); - fRnrLines->SetState(fM->GetRnrLines() ? kButtonDown : kButtonUp); -} - -/**************************************************************************/ - -// Implements callback/slot methods - -void StraightLineSetEditor::DoRnrMarkers() -{ - fM->SetRnrMarkers(fRnrMarkers->IsOn()); - Update(); -} - -void StraightLineSetEditor::DoRnrLines() -{ - fM->SetRnrLines(fRnrLines->IsOn()); - Update(); -} diff --git a/EVE/Reve/StraightLineSetEditor.h b/EVE/Reve/StraightLineSetEditor.h deleted file mode 100644 index 6b1a06c2cd2..00000000000 --- a/EVE/Reve/StraightLineSetEditor.h +++ /dev/null @@ -1,44 +0,0 @@ -// $Header$ - -#ifndef REVE_StraightLineSetEditor_H -#define REVE_StraightLineSetEditor_H - -#include - -class TGCheckButton; -class TGNumberEntry; -class TGColorSelect; - -namespace Reve { - -class StraightLineSet; - -class StraightLineSetEditor : public TGedFrame -{ -private: - StraightLineSetEditor(const StraightLineSetEditor&); // Not implemented - StraightLineSetEditor& operator=(const StraightLineSetEditor&); // Not implemented - -protected: - StraightLineSet* fM; // fModel dynamic-casted to StraightLineSetEditor - - // Declare widgets - TGCheckButton* fRnrMarkers; - TGCheckButton* fRnrLines; - -public: - StraightLineSetEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, UInt_t options = kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - virtual ~StraightLineSetEditor(); - - virtual void SetModel(TObject* obj); - - // Declare callback/slot methods - void DoRnrMarkers(); - void DoRnrLines(); - - ClassDef(StraightLineSetEditor, 1); // Editor for StraightLineSet -}; // endclass StraightLineSetEditor - -} - -#endif diff --git a/EVE/Reve/StraightLineSetGL.cxx b/EVE/Reve/StraightLineSetGL.cxx deleted file mode 100644 index 1817c0bdbe2..00000000000 --- a/EVE/Reve/StraightLineSetGL.cxx +++ /dev/null @@ -1,172 +0,0 @@ -// $Header$ - -#include "StraightLineSetGL.h" -#include -#include - -#include -#include - -#include - -using namespace Reve; - -//______________________________________________________________________ -// StraightLineSetGL -// - -ClassImp(StraightLineSetGL) - -StraightLineSetGL::StraightLineSetGL() : TGLObject(), fM(0) -{ - // fDLCache = false; // Disable display list. -} - -StraightLineSetGL::~StraightLineSetGL() -{} - -/**************************************************************************/ - -Bool_t StraightLineSetGL::SetModel(TObject* obj, const Option_t* /*opt*/) -{ - if(SetModelCheckClass(obj, StraightLineSet::Class())) { - fM = dynamic_cast(obj); - return kTRUE; - } - return kFALSE; -} - -void StraightLineSetGL::SetBBox() -{ - // !! This ok if master sub-classed from TAttBBox - SetAxisAlignedBBox(((StraightLineSet*)fExternalObj)->AssertBBox()); -} - -//______________________________________________________________________________ -Bool_t StraightLineSetGL::ShouldCache(TGLRnrCtx & rnrCtx) const -{ - // Override from TGLDrawable. - // To account for large point-sizes we modify the projection matrix - // during selection and thus we need a direct draw. - - if (rnrCtx.Selection()) return kFALSE; - return fDLCache; -} - -/**************************************************************************/ - -void StraightLineSetGL::DirectDraw(TGLRnrCtx & rnrCtx) const -{ - // printf("StraightLineSetGL::DirectDraw Style %d, LOD %d\n", flags.Style(), flags.LOD()); - - StraightLineSet& mL = * fM; - - glPushAttrib(GL_POINT_BIT | GL_LINE_BIT | GL_ENABLE_BIT); - - // lines - GLUtilNS::GL_Capability_Switch lights_off(GL_LIGHTING, false); - if(mL.GetRnrLines() && mL.GetLinePlex().Size() > 0) - { - glDisable(GL_LIGHTING); - glColorMaterial(GL_FRONT_AND_BACK, GL_DIFFUSE); - glEnable(GL_COLOR_MATERIAL); - UChar_t color[4]; - Reve::ColorFromIdx(mL.GetLineColor(), color); - glColor4ubv(color); - glLineWidth(mL.GetLineWidth()); - if (mL.GetLineStyle() > 1) { - Int_t fac = 1; - UShort_t pat = 0xffff; - switch (mL.GetLineStyle()) { - case 2: pat = 0x3333; break; - case 3: pat = 0x5555; break; - case 4: pat = 0xf040; break; - case 5: pat = 0xf4f4; break; - case 6: pat = 0xf111; break; - case 7: pat = 0xf0f0; break; - case 8: pat = 0xff11; break; - case 9: pat = 0x3fff; break; - case 10: pat = 0x08ff; fac = 2; break; - } - glLineStipple(1, pat); - glEnable(GL_LINE_STIPPLE); - } - - VoidCPlex::iterator li(mL.GetLinePlex()); - if(rnrCtx.SecSelection()) - { - GLuint name = 0; - glPushName(1); - glPushName(0); - while (li.next()) - { - StraightLineSet::Line& l = * (StraightLineSet::Line*) li(); - glLoadName(name); - { - glBegin(GL_LINES); - glVertex3f(l.fV1[0], l.fV1[1], l.fV1[2]); - glVertex3f(l.fV2[0], l.fV2[1], l.fV2[2]); - glEnd(); - } - name ++; - } - glPopName(); - glPopName(); - } - else - { - glBegin(GL_LINES); - while (li.next()) - { - StraightLineSet::Line& l = * (StraightLineSet::Line*) li(); - glVertex3f(l.fV1[0], l.fV1[1], l.fV1[2]); - glVertex3f(l.fV2[0], l.fV2[1], l.fV2[2]); - } - glEnd(); - } - } - glPopAttrib(); - - - // markers - if(mL.GetRnrMarkers() && mL.GetMarkerPlex().Size() > 0) - { - VoidCPlex::iterator mi(mL.GetMarkerPlex()); - Float_t* pnts = new Float_t[mL.GetMarkerPlex().Size()*3]; - Float_t* pnt = pnts; - Int_t lidx = -1; - while (mi.next()) - { - StraightLineSet::Marker& m = * (StraightLineSet::Marker*) mi(); - lidx = m.fLineID; - StraightLineSet::Line& l = * (StraightLineSet::Line*) mL.GetLinePlex().Atom(lidx); - pnt[0] = l.fV1[0] + (l.fV2[0] - l.fV1[0])*m.fPos; - pnt[1] = l.fV1[1] + (l.fV2[1] - l.fV1[1])*m.fPos; - pnt[2] = l.fV1[2] + (l.fV2[2] - l.fV1[2])*m.fPos;; - pnt += 3; - } - if(rnrCtx.SecSelection()) glPushName(2); - GLUtilNS::RenderPolyMarkers((TAttMarker&)mL, pnts, mL.GetMarkerPlex().Size(), - rnrCtx.Selection(), rnrCtx.SecSelection()); - if(rnrCtx.SecSelection()) glPopName(); - delete [] pnts; - } - -} - -/**************************************************************************/ - -void StraightLineSetGL::ProcessSelection(TGLRnrCtx & /*rnrCtx*/, - TGLSelectRecord & rec) -{ - if (rec.GetN() != 3) return; - if(rec.GetItem(1) == 1) - { - printf("selected line %d\n", rec.GetItem(2)); - } - else - { - StraightLineSet::Marker& m = * (StraightLineSet::Marker*) fM->GetMarkerPlex().Atom(rec.GetItem(2)); - printf("Selected point %d on line %d\n", rec.GetItem(2), m.fLineID); - } -} diff --git a/EVE/Reve/StraightLineSetGL.h b/EVE/Reve/StraightLineSetGL.h deleted file mode 100644 index c7afaa8cc4e..00000000000 --- a/EVE/Reve/StraightLineSetGL.h +++ /dev/null @@ -1,45 +0,0 @@ -// $Header$ - -#ifndef REVE_StraightLineSetGL_H -#define REVE_StraightLineSetGL_H - -#include - -class TGLViewer; -class TGLScene; - -namespace Reve { - -class StraightLineSet; - -class StraightLineSetGL : public TGLObject -{ -private: - StraightLineSetGL(const StraightLineSetGL&); // Not implemented - StraightLineSetGL& operator=(const StraightLineSetGL&); // Not implemented - -protected: - StraightLineSet* fM; // fModel dynamic-casted to StraightLineSetGL - - virtual void DirectDraw(TGLRnrCtx & rnrCtx) const; - -public: - StraightLineSetGL(); - virtual ~StraightLineSetGL(); - - virtual Bool_t SetModel(TObject* obj, const Option_t* opt=0); - virtual void SetBBox(); - - // To support two-level selectionvirtual - Bool_t IgnoreSizeForOfInterest() const { return kTRUE; } - - virtual Bool_t ShouldCache(TGLRnrCtx & rnrCtx) const; - virtual Bool_t SupportsSecondarySelect() const { return kTRUE; } - virtual void ProcessSelection(TGLRnrCtx & rnrCtx, TGLSelectRecord & rec); - - ClassDef(StraightLineSetGL, 0); -}; // endclass StraightLineSetGL - -} - -#endif diff --git a/EVE/Reve/TGClassBrowser.cxx b/EVE/Reve/TGClassBrowser.cxx deleted file mode 100644 index e631b374594..00000000000 --- a/EVE/Reve/TGClassBrowser.cxx +++ /dev/null @@ -1,124 +0,0 @@ - -#include "TROOT.h" -#include "TSystem.h" -#include "TGClient.h" -#include "TGListTree.h" -#include "TGLayout.h" -#include "TSystemDirectory.h" -#include "TGMimeTypes.h" -#include "TFile.h" -#include "TKey.h" -#include "TInterpreter.h" -#include "TClass.h" -#include "TDataMember.h" -#include "TMethod.h" -#include "TMethodArg.h" - -#include "TGClassBrowser.h" - -ClassImp(TGClassBrowser) - -//______________________________________________________________________________ -TGClassBrowser::TGClassBrowser(const TGWindow *p, UInt_t w, UInt_t h) : - TGMainFrame(p, w, h) - -{ - SetCleanup(kDeepCleanup); - fCanvas = new TGCanvas(this, 100, 100); - fListTree = new TGListTree(fCanvas, kHorizontalFrame); - AddFrame(fCanvas, new TGLayoutHints(kLHintsLeft | kLHintsTop | - kLHintsExpandX | kLHintsExpandY)); - - TGListTreeItem *item = fListTree->AddItem(0,"Classes"); - fListTree->Connect("DoubleClicked(TGListTreeItem *, Int_t)", - "TGClassBrowser", this, "DoubleClicked(TGListTreeItem *, Int_t)"); - fClassIcon = gClient->GetPicture("class.png"); - fMemberIcon = gClient->GetPicture("member.png"); - fMethodIcon = gClient->GetPicture("method.png"); - - MapSubwindows(); - Resize(GetDefaultSize()); - MapWindow(); - TClass *cl; - TIter nextcl(gROOT->GetListOfClasses()); - while ((cl = (TClass *)nextcl())) { - TGListTreeItem *itm = fListTree->AddItem(item, cl->GetName(), - fClassIcon, fClassIcon); - itm->SetTipText(Form("Decl: %s : %d\nImpl: %s : %d", - cl->GetDeclFileName(), cl->GetDeclFileLine(), - cl->GetImplFileName(), cl->GetImplFileLine())); - } -} - -//______________________________________________________________________________ -TGClassBrowser::~TGClassBrowser() -{ - // Destructor. - - delete fListTree; - Cleanup(); -} - -//______________________________________________________________________________ -void TGClassBrowser::DisplayClass(TGListTreeItem *, const TString &) -{ - // display details of ROOT class - -} - -//______________________________________________________________________________ -void TGClassBrowser::DoubleClicked(TGListTreeItem *item, Int_t /*btn*/) -{ - // Process double clicks in TGListTree. - - TClass *cl; - TIter nextcl(gROOT->GetListOfClasses()); - if (item == fListTree->GetFirstItem()) { - while ((cl = (TClass *)nextcl())) { - if (!fListTree->FindChildByName(item, cl->GetName())) { - TGListTreeItem *itm = fListTree->AddItem(item, cl->GetName(), - fClassIcon, fClassIcon); - itm->SetTipText(Form("Decl: %s : %d\nImpl: %s : %d", - cl->GetDeclFileName(), cl->GetDeclFileLine(), - cl->GetImplFileName(), cl->GetImplFileLine())); - } - } - fListTree->ClearViewPort(); - return; - } - cl = (TClass*)gROOT->GetListOfClasses()->FindObject(item->GetText()); - if (cl) { - TClass *bc; - TDataMember *dm; - TMethod *m; - - TIter nextbc(cl->GetListOfBases()); - while ((bc = (TClass *) nextbc())) { - fListTree->AddItem(item, bc->GetName(), fClassIcon, fClassIcon); - } - - TIter nextdm(cl->GetListOfDataMembers()); - while ((dm = (TDataMember *) nextdm())) { - if (dm->IsEnum()) continue; - fListTree->AddItem(item, Form("%s %s",dm->GetFullTypeName(), dm->GetName()), - fMemberIcon, fMemberIcon); - } - - TIter nextm(cl->GetListOfMethods()); - while ((m = (TMethod *) nextm())) { - TString method = Form("%s %s(", m->GetReturnTypeName(), m->GetName()); - TIter nextarg(m->GetListOfMethodArgs()); - TMethodArg *a; - while ((a = (TMethodArg*) nextarg())) { - method += a->GetFullTypeName(); - method += ", "; - } - method.Remove(TString::kTrailing,' '); - method.Remove(TString::kTrailing,','); - method += ")"; - fListTree->AddItem(item, method.Data(), fMethodIcon, fMethodIcon); - } - } - fListTree->ClearViewPort(); -} - diff --git a/EVE/Reve/TGClassBrowser.h b/EVE/Reve/TGClassBrowser.h deleted file mode 100644 index eba5adedb1d..00000000000 --- a/EVE/Reve/TGClassBrowser.h +++ /dev/null @@ -1,33 +0,0 @@ -#ifndef ROOT_TGClassBrowser -#define ROOT_TGClassBrowser - -#ifndef ROOT_TGFrame -#include "TGFrame.h" -#endif - -class TGCanvas; -class TGListTree; -class TGListTreeItem; -class TGPicture; - -class TGClassBrowser : public TGMainFrame { - -protected: - TGCanvas *fCanvas; - TGListTree *fListTree; - const TGPicture *fClassIcon; - const TGPicture *fMemberIcon; - const TGPicture *fMethodIcon; - -public: - TGClassBrowser(const TGWindow *p, UInt_t w, UInt_t h); - virtual ~TGClassBrowser(); - - void DisplayClass(TGListTreeItem *item, const TString &fname); - void DoubleClicked(TGListTreeItem *item, Int_t btn); - - ClassDef(TGClassBrowser, 0) // ROOT Classes browser -}; - -#endif - diff --git a/EVE/Reve/TGCommandPlugin.cxx b/EVE/Reve/TGCommandPlugin.cxx deleted file mode 100644 index 097e30cf24c..00000000000 --- a/EVE/Reve/TGCommandPlugin.cxx +++ /dev/null @@ -1,127 +0,0 @@ - -#include "TROOT.h" -#include "TSystem.h" -#include "TRint.h" -#include "TApplication.h" -#include "TGClient.h" -#include "TGLabel.h" -#include "TGFrame.h" -#include "TGLayout.h" -#include "TGComboBox.h" -#include "TGTextView.h" -#include "TGTextEntry.h" -#include "TGTextEdit.h" -#include "TInterpreter.h" -#include "Getline.h" - -#include "TGCommandPlugin.h" - -ClassImp(TGCommandPlugin) - -//______________________________________________________________________________ -TGCommandPlugin::TGCommandPlugin(const TGWindow *p, UInt_t w, UInt_t h) : - TGMainFrame(p, w, h) -{ - - SetCleanup(kDeepCleanup); - fHf = new TGHorizontalFrame(this, 100, 20); - fCommandBuf = new TGTextBuffer(256); - fComboCmd = new TGComboBox(fHf, "", 1); - fCommand = fComboCmd->GetTextEntry(); - fCommandBuf = fCommand->GetBuffer(); - fComboCmd->Resize(200, fCommand->GetDefaultHeight()); - fHf->AddFrame(fComboCmd, new TGLayoutHints(kLHintsCenterY | - kLHintsRight | kLHintsExpandX, 5, 5, 1, 1)); - fHf->AddFrame(fLabel = new TGLabel(fHf, "Command (local):"), - new TGLayoutHints(kLHintsCenterY | kLHintsRight, - 5, 5, 1, 1)); - AddFrame(fHf, new TGLayoutHints(kLHintsLeft | kLHintsTop | - kLHintsExpandX, 3, 3, 3, 3)); - fCommand->Connect("ReturnPressed()", "TGCommandPlugin", this, - "HandleCommand()"); - - Pixel_t pxl; - gClient->GetColorByName("#ccccff", pxl); - fStatus = new TGTextView(this, 10, 100, 1); - fStatus->SetSelectBack(pxl); - fStatus->SetSelectFore(TGFrame::GetBlackPixel()); - AddFrame(fStatus, new TGLayoutHints(kLHintsLeft | kLHintsTop | - kLHintsExpandX | kLHintsExpandY, 3, 3, 3, 3)); - fPid = gSystem->GetPid(); - TString defhist(Form("%s/.root_hist", gSystem->UnixPathName( - gSystem->HomeDirectory()))); - FILE *lunin = fopen(defhist.Data(), "rt"); - if (lunin) { - char histline[256]; - while (fgets(histline, 256, lunin)) { - histline[strlen(histline)-1] = 0; // remove trailing "\n" - fComboCmd->InsertEntry(histline, 0, -1); - } - fclose(lunin); - } - MapSubwindows(); - Resize(GetDefaultSize()); - MapWindow(); -} - -//______________________________________________________________________________ -TGCommandPlugin::~TGCommandPlugin() -{ - // Destructor. - - Cleanup(); -} - -//______________________________________________________________________________ -void TGCommandPlugin::CheckRemote(const char * /*str*/) -{ - // Check if actual ROOT session is a remote one or a local one. - - Pixel_t pxl; - TString sPrompt = ((TRint*)gROOT->GetApplication())->GetPrompt(); - Int_t end = sPrompt.Index(":root [", 0); - if (end > 0 && end != kNPOS) { - // remote session - sPrompt.Remove(end); - gClient->GetColorByName("#ff0000", pxl); - fLabel->SetTextColor(pxl); - fLabel->SetText(Form("Command (%s):", sPrompt.Data())); - } - else { - // local session - gClient->GetColorByName("#000000", pxl); - fLabel->SetTextColor(pxl); - fLabel->SetText("Command (local):"); - } - fHf->Layout(); -} - -//______________________________________________________________________________ -void TGCommandPlugin::HandleCommand() -{ - // Handle command line from the "command" combo box. - - const char *string = fCommandBuf->GetString(); - if (strlen(string) > 1) { - // form temporary file path - TString pathtmp = Form("%s/ride.%d.log", gSystem->TempDirectory(), fPid); - TString sPrompt = ((TRint*)gROOT->GetApplication())->GetPrompt(); - FILE *lunout = fopen(pathtmp.Data(), "a+t"); - if (lunout) { - fputs(Form("%s%s\n",sPrompt.Data(), string), lunout); - fclose(lunout); - } - gSystem->RedirectOutput(pathtmp.Data(), "a"); - gApplication->SetBit(TApplication::kProcessRemotely); - gROOT->ProcessLine(string); - fComboCmd->InsertEntry(string, 0, -1); - Gl_histadd((char *)string); - gSystem->RedirectOutput(0); - fStatus->LoadFile(pathtmp.Data()); - fStatus->ShowBottom(); - CheckRemote(string); - fCommand->Clear(); - } - -} - diff --git a/EVE/Reve/TGCommandPlugin.h b/EVE/Reve/TGCommandPlugin.h deleted file mode 100644 index 82d1ed55116..00000000000 --- a/EVE/Reve/TGCommandPlugin.h +++ /dev/null @@ -1,36 +0,0 @@ -#ifndef ROOT_TGCommandPlugin -#define ROOT_TGCommandPlugin - -#ifndef ROOT_TGFrame -#include "TGFrame.h" -#endif - -class TGLabel; -class TGComboBox; -class TGTextEntry; -class TGTextBuffer; -class TGTextView; - -class TGCommandPlugin : public TGMainFrame { - -protected: - Int_t fPid; // current process id - TGHorizontalFrame *fHf; - TGLabel *fLabel; // "command :" label - TGComboBox *fComboCmd; // commands combobox - TGTextEntry *fCommand; // command text entry widget - TGTextBuffer *fCommandBuf; // command text buffer - TGTextView *fStatus; - -public: - - TGCommandPlugin(const TGWindow *p, UInt_t w, UInt_t h); - virtual ~TGCommandPlugin(); - - void CheckRemote(const char * /*str*/); - void HandleCommand(); - - ClassDef(TGCommandPlugin, 0) -}; - -#endif diff --git a/EVE/Reve/TGFileBrowser.cxx b/EVE/Reve/TGFileBrowser.cxx deleted file mode 100644 index 11724014233..00000000000 --- a/EVE/Reve/TGFileBrowser.cxx +++ /dev/null @@ -1,805 +0,0 @@ - -#include "TROOT.h" -#include "TSystem.h" -#include "TApplication.h" -#include "TGClient.h" -#include "TGListTree.h" -#include "TGLayout.h" -#include "TGComboBox.h" -#include "TContextMenu.h" -#include "TGTextEntry.h" -#include "TGTab.h" -#include "TGLabel.h" -#include "TSystemDirectory.h" -#include "TGMimeTypes.h" -#include "TClass.h" -#include "TInterpreter.h" -#include "TRegexp.h" -#include "TEnv.h" -#include "TImage.h" -#include "TBrowser.h" -#include -#include - -#include "TGFileBrowser.h" -#include "TGNewBrowser.h" - -#ifdef WIN32 -const char rootdir[] = "\\"; -#else -const char rootdir[] = "/"; -#endif - -const char *filters[] = { - "", - "*.*", - "*.[C|c|h]*", - "*.root", - "*.txt" -}; - -//////////////////////////////////////////////////////////////////////////////////// -class TCursorSwitcher { -private: - TGWindow *fW1; - TGWindow *fW2; -public: - TCursorSwitcher(TGWindow *w1, TGWindow *w2) : fW1(w1), fW2(w2) { - if (w1) gVirtualX->SetCursor(w1->GetId(), gVirtualX->CreateCursor(kWatch)); - if (w2) gVirtualX->SetCursor(w2->GetId(), gVirtualX->CreateCursor(kWatch)); - } - ~TCursorSwitcher() { - if (fW1) gVirtualX->SetCursor(fW1->GetId(), gVirtualX->CreateCursor(kPointer)); - if (fW2) gVirtualX->SetCursor(fW2->GetId(), gVirtualX->CreateCursor(kPointer)); - } -}; - -ClassImp(TGFileBrowser) - -//______________________________________________________________________________ -TGFileBrowser::TGFileBrowser(TBrowser* b, const char *name, UInt_t w, UInt_t h) : - TGMainFrame(gClient->GetRoot(), w, h), TBrowserImp(b), - fNewBrowser(0) -{ - CreateBrowser(name); - Resize(w, h); - if (fBrowser) Show(); -} - -//______________________________________________________________________________ -TGFileBrowser::TGFileBrowser(TBrowser* b, const char *name, Int_t x, Int_t y, - UInt_t w, UInt_t h) : - TGMainFrame(gClient->GetRoot(), w, h), TBrowserImp(b), - fNewBrowser(0) -{ - CreateBrowser(name); - MoveResize(x, y, w, h); - SetWMPosition(x, y); - if (fBrowser) Show(); -} - -//______________________________________________________________________________ -void TGFileBrowser::CreateBrowser(const char *name) -{ - fCachedPic = 0; - SetCleanup(kDeepCleanup); - - /* - fNewBrowser = 0; - if (p && p != gClient->GetDefaultRoot()) - fNewBrowser = (TGNewBrowser *)p->GetMainFrame(); - if (fNewBrowser) - fNewBrowser->SetBrowserFrame(this); - */ - fTopFrame = new TGHorizontalFrame(this, 100, 30); - fDrawOption = new TGComboBox(fTopFrame, ""); - TGTextEntry *dropt_entry = fDrawOption->GetTextEntry(); - dropt_entry->SetToolTipText("Object Draw Option", 300); - fDrawOption->Resize(80, 20); - TGListBox *lb = fDrawOption->GetListBox(); - lb->Resize(lb->GetWidth(), 120); - Int_t dropt = 1; - fDrawOption->AddEntry("", dropt++); - fDrawOption->AddEntry(" alp", dropt++); - fDrawOption->AddEntry(" box", dropt++); - fDrawOption->AddEntry(" colz", dropt++); - fDrawOption->AddEntry(" lego", dropt++); - fDrawOption->AddEntry(" lego1", dropt++); - fDrawOption->AddEntry(" lego2", dropt++); - fDrawOption->AddEntry(" same", dropt++); - fDrawOption->AddEntry(" surf", dropt++); - fDrawOption->AddEntry(" surf1", dropt++); - fDrawOption->AddEntry(" surf2", dropt++); - fDrawOption->AddEntry(" surf3", dropt++); - fDrawOption->AddEntry(" surf4", dropt++); - fDrawOption->AddEntry(" surf5", dropt++); - fDrawOption->AddEntry(" text", dropt++); - fTopFrame->AddFrame(fDrawOption, new TGLayoutHints(kLHintsCenterY | - kLHintsRight, 2, 2, 2, 2)); - fTopFrame->AddFrame(new TGLabel(fTopFrame, "Draw Option: "), - new TGLayoutHints(kLHintsCenterY | kLHintsRight, - 2, 2, 2, 2)); - AddFrame(fTopFrame, new TGLayoutHints(kLHintsLeft | kLHintsTop | - kLHintsExpandX, 2, 2, 2, 2)); - fCanvas = new TGCanvas(this, 100, 100); - fListTree = new TGListTree(fCanvas, kHorizontalFrame); - AddFrame(fCanvas, new TGLayoutHints(kLHintsLeft | kLHintsTop | - kLHintsExpandX | kLHintsExpandY)); - fListTree->Connect("DoubleClicked(TGListTreeItem *, Int_t)", - "TGFileBrowser", this, "DoubleClicked(TGListTreeItem *, Int_t)"); - fListTree->Connect("Clicked(TGListTreeItem *, Int_t, Int_t, Int_t)", - "TGFileBrowser", this, "Clicked(TGListTreeItem *, Int_t, Int_t, Int_t)"); - - fRootIcon = gClient->GetPicture("rootdb_t.xpm"); - fFileIcon = gClient->GetPicture("doc_t.xpm"); - - fBotFrame = new TGHorizontalFrame(this, 100, 30); - fBotFrame->AddFrame(new TGLabel(fBotFrame, "Filter: "), - new TGLayoutHints(kLHintsCenterY | kLHintsLeft, - 2, 2, 2, 2)); - fFileType = new TGComboBox(fBotFrame, " All Files (*.*)"); - Int_t ftype = 1; - fFileType->AddEntry(" All Files (*.*)", ftype++); - fFileType->AddEntry(" C/C++ Files (*.c;*.cxx;*.h;...)", ftype++); - fFileType->AddEntry(" ROOT Files (*.root)", ftype++); - fFileType->AddEntry(" Text Files (*.txt)", ftype++); - fFileType->Resize(200, fFileType->GetTextEntry()->GetDefaultHeight()); - fBotFrame->AddFrame(fFileType, new TGLayoutHints(kLHintsLeft | kLHintsTop | - kLHintsExpandX, 2, 2, 2, 2)); - fFileType->Connect("Selected(Int_t)", "TGFileBrowser", this, "ApplyFilter(Int_t)"); - AddFrame(fBotFrame, new TGLayoutHints(kLHintsLeft | kLHintsTop | - kLHintsExpandX, 2, 2, 2, 2)); - - fContextMenu = new TContextMenu("FileBrowserContextMenu") ; - fFilter = 0; - fGroupSize = 1000; - fListLevel = 0; - fCurrentDir = 0; - fRootDir = 0; - TString gv = gEnv->GetValue("Browser.GroupView", "10000"); - Int_t igv = atoi(gv.Data()); - if (igv > 10) - fGroupSize = igv; - - if (gEnv->GetValue("Browser.ShowHidden", 0)) - fShowHidden = kTRUE; - else - fShowHidden = kFALSE; - - MapSubwindows(); - Resize(GetDefaultSize()); - SetWindowName(name); - SetIconName(name); - MapWindow(); -} - -//______________________________________________________________________________ -void TGFileBrowser::ReallyDelete() -{ - // Really delete the browser and the this GUI. - - gInterpreter->DeleteGlobal(fBrowser); - delete fBrowser; // will in turn delete this object -} - -//______________________________________________________________________________ -TGFileBrowser::~TGFileBrowser() -{ - // Destructor. - - delete fContextMenu; - delete fListTree; - Cleanup(); -} - - -/**************************************************************************/ -// TBrowserImp virtuals -/**************************************************************************/ - -//______________________________________________________________________________ -void TGFileBrowser::Add(TObject *obj, const char *name, Int_t check) -{ - // Add items to the browser. This function has to be called - // by the Browse() member function of objects when they are - // called by a browser. If check < 0 (default) no check box is drawn, - // if 0 then unchecked checkbox is added, if 1 checked checkbox is added. - - if (obj && obj->InheritsFrom("TSystemDirectory")) - return; - const TGPicture *pic=0; - if (obj && obj->InheritsFrom("TKey")) - AddKey(fListLevel, obj, name); - else if (obj) { - GetObjPicture(&pic, obj); - if (!name) name = obj->GetName(); - if(check > -1) { - if (!fListTree->FindChildByName(fListLevel, name)) { - TGListTreeItem *item = fListTree->AddItem(fListLevel, name, obj, pic, pic, kTRUE); - fListTree->CheckItem(item, (Bool_t)check); - TString tip(obj->ClassName()); - if (obj->GetTitle()) { - tip += " "; - tip += obj->GetTitle(); - } - fListTree->SetToolTipItem(item, tip.Data()); - } - } - else { - if (!fListTree->FindChildByName(fListLevel, name)) - fListTree->AddItem(fListLevel, name, obj, pic, pic); - } - } - //fListTree->ClearViewPort(); -} - -//______________________________________________________________________________ -void TGFileBrowser::BrowseObj(TObject *obj) -{ - // Browse object. This, in turn, will trigger the calling of - // TRootBrowser::Add() which will fill the IconBox and the tree. - // Emits signal "BrowseObj(TObject*)". - - obj->Browse(fBrowser); -} - -//______________________________________________________________________________ -Option_t *TGFileBrowser::GetDrawOption() const -{ - // returns drawing option - - return fDrawOption->GetTextEntry()->GetText(); -} - -//______________________________________________________________________________ -void TGFileBrowser::RecursiveRemove(TObject *obj) -{ - - TGListTreeItem *itm = 0, *item = 0; - if (obj->InheritsFrom("TFile")) { - itm = fListTree->FindChildByData(0, gROOT->GetListOfFiles()); - if (itm) - item = fListTree->FindChildByData(itm, obj); - if (item) - fListTree->DeleteItem(item); - itm = fRootDir ? fRootDir->GetFirstChild() : 0; - while (itm) { - item = fListTree->FindItemByObj(itm, obj); - if (item) { - fListTree->DeleteChildren(item); - item->SetUserData(0); - } - itm = itm->GetNextSibling(); - } - } - if (!obj->InheritsFrom("TFile") && fRootDir) - fListTree->RecursiveDeleteItem(fRootDir, obj); - fListTree->ClearViewPort(); -} - -//______________________________________________________________________________ -void TGFileBrowser::Refresh(Bool_t /*force*/) -{ - - TCursorSwitcher cursorSwitcher(this, fListTree); - static UInt_t prev = 0; - UInt_t curr = gROOT->GetListOfBrowsables()->GetSize(); - if (!prev) prev = curr; - - if (prev != curr) { // refresh gROOT - TGListTreeItem *sav = fListLevel; - fListLevel = 0; - BrowseObj(gROOT); - fListLevel = sav; - prev = curr; - } -} - - -/**************************************************************************/ -// Other -/**************************************************************************/ - -//______________________________________________________________________________ -void TGFileBrowser::AddFSDirectory(const char* /*entry*/, const char* path) -{ - if (path == 0 && fRootDir == 0) { - fRootDir = fListTree->AddItem(0, rootdir); - } else { - // MT: i give up! wanted to place entries for selected - // directories like home, pwd, alice-macros. - // TGListTreeItem *lti = fListTree->AddItem(0, entry); - // - } -} - -//______________________________________________________________________________ -void TGFileBrowser::AddKey(TGListTreeItem *itm, TObject *obj, const char *name) -{ - // display content of ROOT file - - // Int_t from, to; - TGListTreeItem *where; - static TGListTreeItem *olditem = itm; - static TGListTreeItem *item = itm; - static const TGPicture *pic = 0; - static const TGPicture *pic2 = gClient->GetPicture("leaf_t.xpm"); - - if ((fCnt == 0) || (olditem != itm)) { - olditem = item = itm; - } - if (!name) name = obj->GetName(); - if (fNKeys > fGroupSize) { - where = itm->GetFirstChild(); - while (where) { - if (fListTree->FindItemByObj(where, obj)) - return; - where = where->GetNextSibling(); - } - } - if ((fNKeys > fGroupSize) && (fCnt % fGroupSize == 0)) { - if (item != itm) { - TString newname = Form("%s-%s", item->GetText(), name); - item->Rename(newname.Data()); - } - item = fListTree->AddItem(itm, name); - } - if ((fCnt > fGroupSize) && (fCnt >= fNKeys-1)) { - TString newname = Form("%s-%s", item->GetText(), name); - item->Rename(newname.Data()); - } - GetObjPicture(&pic, obj); - if (!pic) pic = pic2; - if (!fListTree->FindChildByName(item, name)) { - fListTree->AddItem(item, name, obj, pic, pic); - } - fCnt++; -} - -//______________________________________________________________________________ -void TGFileBrowser::ApplyFilter(Int_t id) -{ - // Apply filter selected in combo box to the file tree view. - - // Long64_t size; - // Long_t fid, flags, modtime; - - if (fFilter) delete fFilter; - fFilter = 0; - if (id > 1) - fFilter = new TRegexp(filters[id], kTRUE); - TGListTreeItem *item = fCurrentDir; - if (!item) - item = fRootDir; - fListTree->DeleteChildren(item); - DoubleClicked(item, 1); - //fListTree->AdjustPosition(item); - fListTree->ClearViewPort(); -} - -//______________________________________________________________________________ -void TGFileBrowser::Chdir(TGListTreeItem *item) -{ - // Make object associated with item the current directory. - - if (item) { - TGListTreeItem *i = item; - while (i) { - TObject *obj = (TObject*) i->GetUserData(); - if ((obj) && obj->InheritsFrom("TFile")) { - gROOT->ProcessLine(Form("((TFile *)0x%lx)->cd()", obj)); - break; - } - i = i->GetParent(); - } - } -} - -//______________________________________________________________________________ -void TGFileBrowser::Clicked(TGListTreeItem *item, Int_t btn, Int_t x, Int_t y) -{ - - char path[1024]; - Long64_t size = 0; - Long_t id = 0, flags = 0, modtime = 0; - fListLevel = item; - if (item && btn == kButton3) { - TObject *obj = (TObject *) item->GetUserData(); - if (obj) { - if (obj->InheritsFrom("TKey")) { - Chdir(item); - const char *clname = (const char *)gROOT->ProcessLine(Form("((TKey *)0x%lx)->GetClassName();", obj)); - if (clname) { - TClass *cl = TClass::GetClass(clname); - void *add = gROOT->FindObject((char *) obj->GetName()); - if (add && cl->IsTObject()) { - obj = (TObject*)add; - item->SetUserData(obj); - } - } - } - fContextMenu->Popup(x, y, obj); - } - else { - fListTree->GetPathnameFromItem(item, path); - if (strlen(path) > 3) { - TString dirname = DirName(item); - gSystem->GetPathInfo(dirname.Data(), &id, &size, &flags, &modtime); - if (flags & 2) { - fCurrentDir = item; - TSystemDirectory d(item->GetText(), dirname.Data()); - fContextMenu->Popup(x, y, &d); - } - else { - fCurrentDir = item->GetParent(); - TSystemFile f(item->GetText(), dirname.Data()); - fContextMenu->Popup(x, y, &f); - } - } - } - fListTree->ClearViewPort(); - } - else { - if (!item->GetUserData()) { - fListTree->GetPathnameFromItem(item, path); - if (strlen(path) > 1) { - TString dirname = DirName(item); - gSystem->GetPathInfo(dirname.Data(), &id, &size, &flags, &modtime); - if (flags & 2) - fCurrentDir = item; - else - fCurrentDir = item->GetParent(); - } - } - } -} - -//______________________________________________________________________________ -TString TGFileBrowser::DirName(TGListTreeItem* item) -{ - // returns an absolute path - - TGListTreeItem* parent; - TString dirname = item->GetText(); - - while ((parent=item->GetParent())) { - dirname = gSystem->ConcatFileName(parent->GetText(),dirname); - item = parent; - } - - return dirname; -} - -//______________________________________________________________________________ -static Bool_t IsTextFile(const char *candidate) -{ - // Returns true if given a text file - // Uses the specification given on p86 of the Camel book - // - Text files have no NULLs in the first block - // - and less than 30% of characters with high bit set - - Int_t i; - Int_t nchars; - Int_t weirdcount = 0; - char buffer[512]; - FILE *infile; - FileStat_t buf; - - gSystem->GetPathInfo(candidate, buf); - if (!(buf.fMode & kS_IFREG)) - return kFALSE; - - infile = fopen(candidate, "r"); - if (infile) { - // Read a block - nchars = fread(buffer, 1, 512, infile); - fclose (infile); - // Examine the block - for (i = 0; i < nchars; i++) { - if (buffer[i] & 128) - weirdcount++; - if (buffer[i] == '\0') - // No NULLs in text files - return kFALSE; - } - if ((nchars > 0) && ((weirdcount * 100 / nchars) > 30)) - return kFALSE; - } else { - // Couldn't open it. Not a text file then - return kFALSE; - } - return kTRUE; -} - -//______________________________________________________________________________ -void TGFileBrowser::DoubleClicked(TGListTreeItem *item, Int_t /*btn*/) -{ - // Process double clicks in TGListTree. - - const TGPicture *pic=0; - TString dirname = DirName(item); - TGListTreeItem *itm; - FileStat_t sbuf; - Long64_t size; - Long_t id, flags, modtime; - - TCursorSwitcher switcher(this, fListTree); - fListLevel = item; - TObject *obj = (TObject *) item->GetUserData(); - if (obj && !obj->InheritsFrom("TSystemFile")) { - if (obj->InheritsFrom("TFile")) { - fNKeys = gROOT->ProcessLine(Form("((TFile *)0x%lx)->GetListOfKeys()->GetEntries();", obj)); - } - if (obj->InheritsFrom("TKey")) { - Chdir(item); - const char *clname = (const char *)gROOT->ProcessLine(Form("((TKey *)0x%lx)->GetClassName();", obj)); - if (clname) { - TClass *cl = TClass::GetClass(clname); - void *add = gROOT->FindObject((char *) obj->GetName()); - if (add && cl->IsTObject()) { - obj = (TObject*)add; - item->SetUserData(obj); - } - } - } - obj->Browse(fBrowser); - fNKeys = 0; - fCnt = 0; - fListTree->ClearViewPort(); - return; - } - flags = id = size = modtime = 0; - gSystem->GetPathInfo(dirname.Data(), &id, &size, &flags, &modtime); - Int_t isdir = (Int_t)flags & 2; - - TString savdir = gSystem->WorkingDirectory(); - if (isdir) { - fCurrentDir = item; - TSystemDirectory dir(item->GetText(),DirName(item)); - TList *files = dir.GetListOfFiles(); - if (files) { - files->Sort(); - TIter next(files); - TSystemFile *file; - TString fname; - // directories first - while ((file=(TSystemFile*)next())) { - fname = file->GetName(); - if (file->IsDirectory()) { - if (!fShowHidden && fname.BeginsWith(".")) - continue; - if ((fname!="..") && (fname!=".")) { // skip it - if (!fListTree->FindChildByName(item, fname)) { - itm = fListTree->AddItem(item, fname); - } - } - } - } - // then files... - TIter nextf(files); - while ((file=(TSystemFile*)nextf())) { - fname = file->GetName(); - if (!file->IsDirectory() && (fFilter == 0 || - (fFilter && fname.Index(*fFilter) != kNPOS))) { - if (!fShowHidden && fname.BeginsWith(".")) - continue; - size = modtime = 0; - if (gSystem->GetPathInfo(fname, sbuf) == 0) { - size = sbuf.fSize; - modtime = sbuf.fMtime; - } - pic = gClient->GetMimeTypeList()->GetIcon(fname, kTRUE); - if (!pic) - pic = fFileIcon; - if (!fListTree->FindChildByName(item, fname)) { - itm = fListTree->AddItem(item,fname,pic,pic); - if (size && modtime) { - char *tiptext = FormatFileInfo(fname.Data(), size, modtime); - itm->SetTipText(tiptext); - delete [] tiptext; - } - } - } - } - delete files; - } - } - else { - fCurrentDir = item->GetParent(); - TSystemFile f(item->GetText(), dirname.Data()); - TString fname = f.GetName(); - if (fname.EndsWith(".root")) { - TObject *rfile = 0; - gSystem->ChangeDirectory(gSystem->DirName(dirname.Data())); - rfile = gROOT->GetListOfFiles()->FindObject(obj); - if (!rfile) { - rfile = (TObject *)gROOT->ProcessLine(Form("new TFile(\"%s\")",fname.Data())); - item->SetUserData(rfile); - } - if (rfile) { - fNKeys = gROOT->ProcessLine(Form("((TFile *)0x%lx)->GetListOfKeys()->GetEntries();", rfile)); - fCnt = 0; - gROOT->ProcessLine(Form("((TFile *)0x%lx)->Browse((TBrowser *)0x%lx)", rfile, fBrowser)); - fNKeys = 0; - fCnt = 0; - } - } - else if (fname.EndsWith(".png")) { - gSystem->ChangeDirectory(gSystem->DirName(dirname.Data())); - XXExecuteDefaultAction(&f); - } - else if (IsTextFile(dirname.Data())) { - gSystem->ChangeDirectory(gSystem->DirName(dirname.Data())); - if (fNewBrowser) { - TGTab *tabRight = fNewBrowser->GetTabRight(); - TGCompositeFrame *frame = tabRight->GetCurrentContainer(); - TGFrameElement *fe = (TGFrameElement *)frame->GetList()->First(); - if (fe) { - TGCompositeFrame *embed = (TGCompositeFrame *)fe->fFrame; - if (embed->InheritsFrom("TGTextEditor")) { - gROOT->ProcessLine(Form("((TGTextEditor *)0x%lx)->LoadFile(\"%s\");", - embed, f.GetName())); - } - else if (embed->InheritsFrom("TGTextEdit")) { - gROOT->ProcessLine(Form("((TGTextEdit *)0x%lx)->LoadFile(\"%s\");", - embed, f.GetName())); - } - else { - XXExecuteDefaultAction(&f); - } - } - } - } - else { - gSystem->ChangeDirectory(gSystem->DirName(dirname.Data())); - XXExecuteDefaultAction(&f); - } - } - gSystem->ChangeDirectory(savdir.Data()); - fListTree->ClearViewPort(); -} - -//____________________________________________________________________________ -Long_t TGFileBrowser::XXExecuteDefaultAction(TObject *obj) -{ - // Execute default action for selected object (action is specified - // in the $HOME/.root.mimes or $ROOTSYS/etc/root.mimes file. - - char action[512]; - TString act; - TString ext = obj->GetName(); - fBrowser->SetDrawOption(GetDrawOption()); - - if (gClient->GetMimeTypeList()->GetAction(obj->GetName(), action)) { - act = action; - act.ReplaceAll("%s", obj->GetName()); - gInterpreter->SaveGlobalsContext(); - - if (act[0] == '!') { - act.Remove(0, 1); - gSystem->Exec(act.Data()); - return 0; - } else { - return gApplication->ProcessLine(act.Data()); - } - } - return 0; -} - -//______________________________________________________________________________ -char *TGFileBrowser::FormatFileInfo(const char *fname, Long64_t size, Long_t modtime) -{ - - Long64_t fsize, bsize; - TString infos = fname; - infos += "\n"; - - fsize = bsize = size; - if (fsize > 1024) { - fsize /= 1024; - if (fsize > 1024) { - // 3.7MB is more informative than just 3MB - infos += Form("Size: %lld.%lldM", fsize/1024, (fsize%1024)/103); - } else { - infos += Form("Size: %lld.%lldK", bsize/1024, (bsize%1024)/103); - } - } else { - infos += Form("Size: %lld", bsize); - } - struct tm *newtime; - time_t loctime = (time_t) modtime; - newtime = localtime(&loctime); - infos += "\n"; - infos += Form("%d-%02d-%02d %02d:%02d", newtime->tm_year + 1900, - newtime->tm_mon+1, newtime->tm_mday, newtime->tm_hour, - newtime->tm_min); - return StrDup(infos.Data()); -} - -//______________________________________________________________________________ -void TGFileBrowser::GetObjPicture(const TGPicture **pic, TObject *obj) -{ - // Retrieve icons associated with class "name". Association is made - // via the user's ~/.root.mimes file or via $ROOTSYS/etc/root.mimes. - - TClass *objClass = 0; - static TImage *im = 0; - if (!im) { - im = TImage::Create(); - } - - if (obj->InheritsFrom("TKey")) { - const char *clname = (const char *)gROOT->ProcessLine(Form("((TKey *)0x%lx)->GetClassName();", obj)); - if (clname) - objClass = TClass::GetClass(clname); - } - else if (obj->InheritsFrom("TKeyMapFile")) { - const char *title = (const char *)gROOT->ProcessLine(Form("((TKeyMapFile *)0x%lx)->GetTitle();", obj)); - if (title) - objClass = TClass::GetClass(title); - } - else - objClass = obj->IsA(); - const char *name = obj->GetIconName() ? obj->GetIconName() : objClass->GetName(); - TString xpm_magic(name, 3); - Bool_t xpm = xpm_magic == "/* "; - const char *iconname = xpm ? obj->GetName() : name; - - if (obj->IsA()->InheritsFrom("TGeoVolume")) { - iconname = obj->GetIconName() ? obj->GetIconName() : obj->IsA()->GetName(); - } - - if (fCachedPicName == iconname) { - *pic = fCachedPic; - return; - } - *pic = gClient->GetMimeTypeList()->GetIcon(iconname, kTRUE); - if (!(*pic) && xpm) { - if (im && im->SetImageBuffer((char**)&name, TImage::kXpm)) { - im->Scale(im->GetWidth()/4, im->GetHeight()/4); - *pic = gClient->GetPicturePool()->GetPicture(iconname, im->GetPixmap(), - im->GetMask()); - } - gClient->GetMimeTypeList()->AddType("[thumbnail]", iconname, iconname, iconname, "->Browse()"); - return; - } - if (*pic == 0) { - if (!obj->IsFolder()) - *pic = fFileIcon; - } - fCachedPic = *pic; - fCachedPicName = iconname; -} - -//______________________________________________________________________________ -void TGFileBrowser::GotoDir(const char *path) -{ - - TGListTreeItem *item, *itm; - char *token; - static const char seps[] = "/\\"; - // Establish string and get the first token: - token = strtok(strdup(path), seps); - // Note: strtok is deprecated; consider using strtok_s instead - item = fRootDir; - if (item == 0) return; - fListTree->HighlightItem(item); - fListTree->OpenItem(item); - DoubleClicked(item, 1); - while (token) { - // while there are tokens in path - itm = fListTree->FindChildByName(item, token); - if (itm) { - item = itm; - fListTree->HighlightItem(item); - fListTree->OpenItem(item); - DoubleClicked(item, 1); - } - // get next token: - token = strtok( NULL, seps ); - } - fListTree->ClearViewPort(); - fListTree->AdjustPosition(item); -} - - diff --git a/EVE/Reve/TGFileBrowser.h b/EVE/Reve/TGFileBrowser.h deleted file mode 100644 index 465ccba1f56..00000000000 --- a/EVE/Reve/TGFileBrowser.h +++ /dev/null @@ -1,91 +0,0 @@ -#ifndef ROOT_TGFileBrowser -#define ROOT_TGFileBrowser - -#ifndef ROOT_TGFrame -#include "TGFrame.h" -#endif - -#ifndef ROOT_TBrowserImp -#include "TBrowserImp.h" -#endif - -class TGCanvas; -class TGListTree; -class TGListTreeItem; -class TGPicture; -class TGLabel; -class TGComboBox; -class TGTextEntry; -class TGTextBuffer; -class TGTextView; -class TContextMenu; -class TRegexp; -class TGMenuBar; -class TGPopupMenu; -class TGStatusBar; -class TGPictureButton; -class TString; -class TGNewBrowser; - -class TGFileBrowser : public TGMainFrame, public TBrowserImp { - -protected: - // TGNewBrowser *fNewBrowser; - TGHorizontalFrame *fTopFrame; - TGHorizontalFrame *fBotFrame; - TGCanvas *fCanvas; - TGListTree *fListTree; - TGListTreeItem *fListLevel; // current TGListTree level - TGListTreeItem *fCurrentDir; // - TGListTreeItem *fRootDir; // - TGComboBox *fDrawOption; // draw options combobox - TGComboBox *fFileType; // file type combobox - TContextMenu *fContextMenu; // context menu pointer - const TGPicture *fRootIcon; - const TGPicture *fFileIcon; - const TGPicture *fCachedPic; // - TString fCachedPicName; // - TRegexp *fFilter; - Int_t fGroupSize; // total number of items when icon box switched to "global view" mode - Long_t fNKeys, fCnt; - Bool_t fGrouped; // - Bool_t fShowHidden; - - TGNewBrowser *fNewBrowser; - - void CreateBrowser(const char *name); - -public: - TGFileBrowser(TBrowser* b=0, const char *name="ROOT Browser", UInt_t w=200, UInt_t h=400); - TGFileBrowser(TBrowser* b, const char *name, Int_t x, Int_t y, UInt_t w, UInt_t h); - virtual ~TGFileBrowser(); - - virtual void Add(TObject *obj, const char *name = 0, Int_t check = -1); - virtual void BrowseObj(TObject *obj); - virtual void RecursiveRemove(TObject *obj); - virtual void Refresh(Bool_t force = kFALSE); - virtual void Show() { MapRaised(); } - Option_t *GetDrawOption() const; - - TGNewBrowser *GetNewBrowser() const { return fNewBrowser; } - void SetNewBrowser(TGNewBrowser* b) { fNewBrowser = b; } - - void AddFSDirectory(const char* entry, const char* path=0); - void AddKey(TGListTreeItem *itm, TObject *obj, const char *name = 0); - void ApplyFilter(Int_t id); - void Chdir(TGListTreeItem *item); - void Clicked(TGListTreeItem *item, Int_t btn, Int_t x, Int_t y); - TString DirName(TGListTreeItem* item); - void DoubleClicked(TGListTreeItem *item, Int_t btn); - Long_t XXExecuteDefaultAction(TObject *obj); - char *FormatFileInfo(const char *fname, Long64_t size, Long_t modtime); - void GetObjPicture(const TGPicture **pic, TObject *obj); - void GotoDir(const char *path); - - // overridden from TGMainFrame - void ReallyDelete(); - - ClassDef(TGFileBrowser, 0) // File browser. -}; - -#endif diff --git a/EVE/Reve/TGNewBrowser.cxx b/EVE/Reve/TGNewBrowser.cxx deleted file mode 100644 index 38e0bd446b0..00000000000 --- a/EVE/Reve/TGNewBrowser.cxx +++ /dev/null @@ -1,810 +0,0 @@ - -#include "TROOT.h" -#include "TSystem.h" -#include "TApplication.h" -#include "TBrowser.h" -#include "TGClient.h" -#include "TGFrame.h" -#include "TGTab.h" -#include "TGMenu.h" -#include "TGLayout.h" -#include "TGSplitter.h" -#include "TGStatusBar.h" -#include "Varargs.h" -#include "TInterpreter.h" -#include "TBrowser.h" -#include "TGFileDialog.h" -#include "TObjString.h" -#include - -#include "TGNewBrowser.h" -#include "TGFileBrowser.h" - -#include "Getline.h" - -#ifdef WIN32 -#include -#endif - -static const char *gOpenFileTypes[] = { - "ROOT files", "*.root", - "All files", "*", - 0, 0 -}; - -static const char *gPluginFileTypes[] = { - "ROOT files", "*.C", - "All files", "*", - 0, 0 -}; - -enum ENewBrowserMessages { - kBrowse = 11011, - kOpenFile, - kNewEditor, - kNewCanvas, - kExecPlugin, - kCloseTab, - kCloseWindow, - kQuitRoot -}; - -//______________________________________________________________________________ -TGNewBrowser::TGNewBrowser(const char *name, UInt_t width, UInt_t height, Bool_t initshow) - : TGMainFrame(gClient->GetDefaultRoot(), width, height) -{ - // Create browser with a specified width and height. - - CreateBrowser(name); - Resize(width, height); - if (initshow) { - InitPlugins(); - MapWindow(); - } - gVirtualX->SetInputFocus(GetId()); -} - -//______________________________________________________________________________ -TGNewBrowser::TGNewBrowser(const char *name, Int_t x, Int_t y, - UInt_t width, UInt_t height, Bool_t initshow) - : TGMainFrame(gClient->GetDefaultRoot(), width, height) -{ - // Create browser with a specified width and height and at position x, y. - - CreateBrowser(name); - MoveResize(x, y, width, height); - SetWMPosition(x, y); - if (initshow) { - InitPlugins(); - MapWindow(); - } - gVirtualX->SetInputFocus(GetId()); -} - - -//______________________________________________________________________________ -void TGNewBrowser::CreateBrowser(const char *name) -{ - - fVf = new TGVerticalFrame(this, 100, 100); - - fLH0 = new TGLayoutHints(kLHintsNormal); - fLH1 = new TGLayoutHints(kLHintsTop | kLHintsLeft, 0, 4, 0, 0); - fLH2 = new TGLayoutHints(kLHintsTop | kLHintsExpandX, 1, 1, 1, 3); - fLH3 = new TGLayoutHints(kLHintsLeft | kLHintsTop | kLHintsExpandX); - fLH4 = new TGLayoutHints(kLHintsLeft | kLHintsTop | kLHintsExpandX | kLHintsExpandY,2,2,2,2); - fLH5 = new TGLayoutHints(kLHintsLeft | kLHintsTop | kLHintsExpandX | kLHintsExpandY); - fLH6 = new TGLayoutHints(kLHintsBottom | kLHintsExpandX); - fLH7 = new TGLayoutHints(kLHintsLeft | kLHintsTop | kLHintsExpandY); - - // Menubar Frame - fTopMenuFrame = new TGHorizontalFrame(fVf, 100, 20); - - fPreMenuFrame = new TGHorizontalFrame(fTopMenuFrame, 0, 20, kRaisedFrame); - fMenuBar = new TGMenuBar(fPreMenuFrame, 10, 10, kHorizontalFrame); - fMenuFile = new TGPopupMenu(gClient->GetDefaultRoot()); - fMenuFile->AddEntry("&Browse... Ctrl+B", kBrowse); - fMenuFile->AddEntry("&Open... Ctrl+O", kOpenFile); - fMenuFile->AddEntry("New &Editor Ctrl+E", kNewEditor); - fMenuFile->AddEntry("New &Canvas Ctrl+C", kNewCanvas); - fMenuFile->AddEntry("Exec &Plugin... Ctrl+P", kExecPlugin); - fMenuFile->AddSeparator(); - fMenuFile->AddEntry("Close &Tab Ctrl+T", kCloseTab); - fMenuFile->AddEntry("Close &Window Ctrl+W", kCloseWindow); - fMenuFile->AddSeparator(); - fMenuFile->AddEntry("&Quit Root Ctrl+Q", kQuitRoot); - fMenuBar->AddPopup("Framewor&k", fMenuFile, fLH1); - fMenuFile->Connect("Activated(Int_t)", "TGNewBrowser", this, - "HandleMenu(Int_t)"); - fPreMenuFrame->AddFrame(fMenuBar, fLH2); - fTopMenuFrame->AddFrame(fPreMenuFrame, fLH0); - - fMenuFrame = new TGHorizontalFrame(fTopMenuFrame, 100, 20, kRaisedFrame); - fTopMenuFrame->AddFrame(fMenuFrame, fLH5); - - fVf->AddFrame(fTopMenuFrame, fLH3); - fActMenuBar = fMenuBar; - - // Toolbar Frame - fToolbarFrame = new TGHorizontalFrame(fVf, 100, 20, kHorizontalFrame | - kRaisedFrame); - fVf->AddFrame(fToolbarFrame, fLH3); - - fHf = new TGHorizontalFrame(fVf, 100, 100); - // Tabs & co... - fV1 = new TGVerticalFrame(fHf, 250, 100, kFixedWidth); - fV2 = new TGVerticalFrame(fHf, 600, 100); - fH1 = new TGHorizontalFrame(fV2, 100, 100); - fH2 = new TGHorizontalFrame(fV2, 100, 100, kFixedHeight); - - // Left tab - fTabLeft = new TGTab(fV1,100,100); - //fTabLeft->AddTab("Tab 1"); - fTabLeft->Resize(fTabLeft->GetDefaultSize()); - fV1->AddFrame(fTabLeft, fLH4); - - // Vertical splitter - fVSplitter = new TGVSplitter(fHf, 4, 4); - fVSplitter->SetFrame(fV1, kTRUE); - fHf->AddFrame(fV1, fLH7); - fHf->AddFrame(fVSplitter, fLH7); - - // Right tab - fTabRight = new TGTab(fH1, 500, 100); - //fTabRight->AddTab("Tab 1"); - fTabRight->Resize(fTabRight->GetDefaultSize()); - fH1->AddFrame(fTabRight, fLH5); - fTabRight->Connect("Selected(Int_t)", "TGNewBrowser", this, "DoTab(Int_t)"); - fV2->AddFrame(fH1, fLH4); - - // Horizontal splitter - fHSplitter = new TGHSplitter(fV2, 4, 4); - fV2->AddFrame(fHSplitter, fLH3); - - // Bottom tab - fTabBottom = new TGTab(fH2, 100, 100); - //fTabBottom->AddTab("Tab 1"); - fH2->AddFrame(fTabBottom, fLH4); - fV2->AddFrame(fH2, fLH3); - - fHSplitter->SetFrame(fH2, kFALSE); - fHf->AddFrame(fV2, fLH5); - fVf->AddFrame(fHf, fLH5); - AddFrame(fVf, fLH5); - - // status bar - fStatusBar = new TGStatusBar(this, 400, 20); - Int_t parts[] = { 80, 20 }; - fStatusBar->SetParts(parts, 2); - AddFrame(fStatusBar, fLH6); - - fEditFrame = 0; - fEditTab = 0; - fNbTab[0] = fNbTab[1] = fNbTab[2] = 0; - fCrTab[0] = fCrTab[1] = fCrTab[2] = -1; - - // Set a name to the main frame - SetWindowName(name); - SetIconName(name); - SetClassHints("Browser", "Browser"); - - SetWMSizeHints(600, 350, 10000, 10000, 2, 2); - MapSubwindows(); - Resize(GetDefaultSize()); - AddInput(kKeyPressMask | kKeyReleaseMask); - - fVf->HideFrame(fToolbarFrame); -} - -//______________________________________________________________________________ -TGNewBrowser::~TGNewBrowser() -{ - // Clean up all widgets, frames and layouthints that were used - - delete fLH0; - delete fLH1; - delete fLH2; - delete fLH3; - delete fLH4; - delete fLH5; - delete fLH6; - delete fLH7; - delete fMenuFile; - delete fMenuBar; - delete fMenuFrame; - delete fToolbarFrame; - delete fVSplitter; - delete fHSplitter; - delete fTabLeft; - delete fTabRight; - delete fTabBottom; - delete fH1; - delete fH2; - delete fV1; - delete fV2; - delete fHf; - delete fStatusBar; - delete fVf; -} - -//______________________________________________________________________________ -void TGNewBrowser::CloseWindow() -{ - // Called when window is closed via the window manager. - - TGFrameElement *el; - Int_t i; - Disconnect(fMenuFile, "Activated(Int_t)", this, "HandleMenu(Int_t)"); - for (i=0;iGetNumberOfTabs();i++) { - el = (TGFrameElement *)fTabLeft->GetTabContainer(i)->GetList()->First(); - if (el && el->fFrame) { - el->fFrame->SetFrameElement(0); - if (el->fFrame->InheritsFrom("TGMainFrame")) - ((TGMainFrame *)el->fFrame)->CloseWindow(); - else - delete el->fFrame; - el->fFrame = 0; - if (el->fLayout && (el->fLayout != fgDefaultHints) && - (el->fLayout->References() > 0)) { - el->fLayout->RemoveReference(); - } - fTabLeft->GetTabContainer(i)->GetList()->Remove(el); - delete el; - } - } - for (i=0;iGetNumberOfTabs();i++) { - el = (TGFrameElement *)fTabRight->GetTabContainer(i)->GetList()->First(); - if (el && el->fFrame) { - el->fFrame->SetFrameElement(0); - if (el->fFrame->InheritsFrom("TGMainFrame")) - ((TGMainFrame *)el->fFrame)->CloseWindow(); - else - delete el->fFrame; - el->fFrame = 0; - if (el->fLayout && (el->fLayout != fgDefaultHints) && - (el->fLayout->References() > 0)) { - el->fLayout->RemoveReference(); - } - fTabRight->GetTabContainer(i)->GetList()->Remove(el); - delete el; - } - } - for (i=0;iGetNumberOfTabs();i++) { - el = (TGFrameElement *)fTabBottom->GetTabContainer(i)->GetList()->First(); - if (el && el->fFrame) { - el->fFrame->SetFrameElement(0); - if (el->fFrame->InheritsFrom("TGMainFrame")) - ((TGMainFrame *)el->fFrame)->CloseWindow(); - else - delete el->fFrame; - el->fFrame = 0; - if (el->fLayout && (el->fLayout != fgDefaultHints) && - (el->fLayout->References() > 0)) { - el->fLayout->RemoveReference(); - } - fTabBottom->GetTabContainer(i)->GetList()->Remove(el); - delete el; - } - } - DeleteWindow(); -} - -//______________________________________________________________________________ -void TGNewBrowser::DoTab(Int_t id) -{ - // Handle Tab navigation. - - TGTab *sender = (TGTab *)gTQSender; - if ((sender) && (sender == fTabRight)) { - SwitchMenus(sender->GetTabContainer(id)); - } -} - -//______________________________________________________________________________ -void TGNewBrowser::ExecPlugin(const char *fname, Int_t pos, Int_t subpos) -{ - // Execute a macro and embed the created frame in the tab "pos" - // and tab element "subpos". - - StartEmbedding(pos, subpos); - gROOT->Macro(fname); - StopEmbedding(); -} - -//______________________________________________________________________________ -Bool_t TGNewBrowser::HandleKey(Event_t *event) -{ - char input[10]; - Int_t n; - UInt_t keysym; - - if (event->fType == kGKeyPress) { - gVirtualX->LookupString(event, input, sizeof(input), keysym); - n = strlen(input); - - switch ((EKeySym)keysym) { // ignore these keys - case kKey_Shift: - case kKey_Control: - case kKey_Meta: - case kKey_Alt: - case kKey_CapsLock: - case kKey_NumLock: - case kKey_ScrollLock: - return kTRUE; - default: - break; - } - if (event->fState & kKeyControlMask) { // Cntrl key modifier pressed - switch ((EKeySym)keysym & ~0x20) { // treat upper and lower the same - case kKey_B: - fMenuFile->Activated(kBrowse); - return kTRUE; - case kKey_O: - fMenuFile->Activated(kOpenFile); - return kTRUE; - case kKey_E: - fMenuFile->Activated(kNewEditor); - return kTRUE; - case kKey_C: - fMenuFile->Activated(kNewCanvas); - return kTRUE; - case kKey_P: - fMenuFile->Activated(kExecPlugin); - return kTRUE; - case kKey_T: - fMenuFile->Activated(kCloseTab); - return kTRUE; - case kKey_W: - fMenuFile->Activated(kCloseWindow); - return kTRUE; - case kKey_Q: - fMenuFile->Activated(kQuitRoot); - return kTRUE; - default: - break; - } - } - } - return TGMainFrame::HandleKey(event); -} - -//______________________________________________________________________________ -void TGNewBrowser::HandleMenu(Int_t id) -{ - // Handle menu items. - - static Int_t cNr = 1; - static Int_t eNr = 1; - TGPopupMenu *sender = (TGPopupMenu *)gTQSender; - if (sender != fMenuFile) - return; - switch (id) { - case kBrowse: - new TBrowser(); - break; - case kOpenFile: - { - static TString dir("."); - TGFileInfo fi; - fi.fFileTypes = gOpenFileTypes; - fi.fIniDir = StrDup(dir); - new TGFileDialog(gClient->GetDefaultRoot(), this, - kFDOpen,&fi); - dir = fi.fIniDir; - if (fi.fMultipleSelection && fi.fFileNamesList) { - TObjString *el; - TIter next(fi.fFileNamesList); - while ((el = (TObjString *) next())) { - gROOT->ProcessLine(Form("new TFile(\"%s\");", - gSystem->UnixPathName(el->GetString()))); - } - } - else if (fi.fFilename) { - gROOT->ProcessLine(Form("new TFile(\"%s\");", - gSystem->UnixPathName(fi.fFilename))); - } - } - break; - case kNewEditor: - StartEmbedding(1); - ++eNr; - gROOT->ProcessLine(Form("new TGTextEditor((const char *)0, (const TGWindow *)0x%lx)", - gClient->GetRoot())); - StopEmbedding(); - SetTabTitle(Form("Editor %d", eNr), 1); - break; - case kNewCanvas: - StartEmbedding(1); - ++cNr; - gROOT->ProcessLine(Form("new TCanvas(\"BrowserCanvas%d\", \"Browser Canvas %d\")", cNr, cNr)); - StopEmbedding(); - SetTabTitle(Form("Canvas %d", cNr), 1); - break; - case kExecPlugin: - { - static TString dir("."); - TGFileInfo fi; - fi.fFileTypes = gPluginFileTypes; - fi.fIniDir = StrDup(dir); - new TGFileDialog(gClient->GetDefaultRoot(), this, - kFDOpen,&fi); - dir = fi.fIniDir; - if (fi.fFilename) { - ExecPlugin(fi.fFilename, kRight); - } - } - break; - case kCloseTab: - RemoveFrame(kRight, fTabRight->GetCurrent()); - break; - case kCloseWindow: - CloseWindow(); - break; - case kQuitRoot: - gApplication->Terminate(0); - break; - default: - break; - } -} - -//______________________________________________________________________________ -void TGNewBrowser::RemoveFrame(Int_t pos, Int_t subpos) -{ - // Remove tab element "subpos" from tab "pos". - - TGTab *edit = 0; - switch (pos) { - case kLeft: // left - edit = fTabLeft; - break; - case kRight: // right - edit = fTabRight; - fMenuFrame->HideFrame(fActMenuBar); - fMenuFrame->GetList()->Remove(fActMenuBar); - fActMenuBar = 0; - break; - case kBottom: // bottom - edit = fTabBottom; - break; - } - TGFrameElement *el = (TGFrameElement *)edit->GetTabContainer(subpos)->GetList()->First(); - if (el && el->fFrame) { - el->fFrame->SetFrameElement(0); - if (el->fFrame->InheritsFrom("TGMainFrame")) - ((TGMainFrame *)el->fFrame)->CloseWindow(); - else - delete el->fFrame; - el->fFrame = 0; - if (el->fLayout && (el->fLayout != fgDefaultHints) && - (el->fLayout->References() > 0)) { - el->fLayout->RemoveReference(); - } - edit->GetTabContainer(subpos)->GetList()->Remove(el); - delete el; - } - fNbTab[pos]--; - edit->RemoveTab(subpos); -} - -//______________________________________________________________________________ -TGTab* TGNewBrowser::GetTab(Int_t pos) const -{ - switch (pos) { - case kLeft: return fTabLeft; - case kRight: return fTabRight; - case kBottom: return fTabBottom; - default: return 0; - } -} - -//______________________________________________________________________________ -void TGNewBrowser::SetTab(Int_t pos, Int_t subpos) -{ - TGTab *tab = GetTab(pos); - if (subpos == -1) - subpos = fCrTab[pos]; - - if (tab->SetTab(subpos, kFALSE)) { // Block signal emit - if (pos == kRight) - SwitchMenus(tab->GetTabContainer(subpos)); - tab->Layout(); - } -} - -//______________________________________________________________________________ -void TGNewBrowser::SetTabTitle(const char *title, Int_t pos, Int_t subpos) -{ - TGTab *edit = GetTab(pos); - if (subpos == -1) - subpos = fCrTab[pos]; - - TGTabElement *el = edit->GetTabTab(subpos); - if (el) { - el->SetText(new TGString(title)); - edit->Layout(); - } -} - -//______________________________________________________________________________ -void TGNewBrowser::ShowMenu(TGCompositeFrame *menu) -{ - // Show the selected frame's menu and hide previous one. - - TGFrameElement *el = 0; - // temporary solution until I find a proper way to handle - // these bloody menus... - fBindList->Delete(); - TIter nextm(fMenuBar->GetList()); - while ((el = (TGFrameElement *) nextm())) { - TGMenuTitle *t = (TGMenuTitle *) el->fFrame; - Int_t code = t->GetHotKeyCode(); - BindKey(fMenuBar, code, kKeyMod1Mask); - BindKey(fMenuBar, code, kKeyMod1Mask | kKeyShiftMask); - BindKey(fMenuBar, code, kKeyMod1Mask | kKeyLockMask); - BindKey(fMenuBar, code, kKeyMod1Mask | kKeyShiftMask | kKeyLockMask); - BindKey(fMenuBar, code, kKeyMod1Mask | kKeyMod2Mask); - BindKey(fMenuBar, code, kKeyMod1Mask | kKeyShiftMask | kKeyMod2Mask); - BindKey(fMenuBar, code, kKeyMod1Mask | kKeyMod2Mask | kKeyLockMask); - BindKey(fMenuBar, code, kKeyMod1Mask | kKeyShiftMask | kKeyMod2Mask | kKeyLockMask); - } - fMenuFrame->HideFrame(fActMenuBar); - fMenuFrame->ShowFrame(menu); - menu->Layout(); - fMenuFrame->Layout(); - fActMenuBar = menu; -} - -//______________________________________________________________________________ -TGCompositeFrame* TGNewBrowser::StartEmbedding(Int_t pos, Int_t subpos) -{ - // Start embedding external frame in the tab "pos" and tab element "subpos". - - fEditTab = GetTab(pos); - - if (fEditFrame == 0) { - if (subpos == -1) { - fCrTab[pos] = fNbTab[pos]++; - fEditFrame = fEditTab->AddTab(Form("Tab %d",fNbTab[pos])); - fEditFrame->MapWindow(); - TGTabElement *tabel = fEditTab->GetTabTab(fEditTab->GetNumberOfTabs()-1); - if(tabel) tabel->MapWindow(); - fEditTab->SetTab(fEditTab->GetNumberOfTabs()-1); - fEditTab->Layout(); - } - else { - fCrTab[pos] = subpos; - fEditFrame = fEditTab->GetTabContainer(subpos); - fEditTab->SetTab(subpos); - } - fEditFrame->SetEditable(); - } - return fEditFrame; -} - -//______________________________________________________________________________ -void TGNewBrowser::StopEmbedding(TGLayoutHints *layout) -{ - // Stop embedding external frame in the current editable frame. - - if (fEditFrame != 0) { - fEditFrame->SetEditable(kFALSE); - if (layout) { - TGFrameElement *el = (TGFrameElement*) fEditFrame->GetList()->Last(); - // !!!! MT what to do with the old layout? Leak it for now ... - el->fLayout = layout; - } - fEditFrame->Layout(); - if (fEditTab == fTabRight) - SwitchMenus(fEditFrame); - fEditFrame = fEditTab = 0; - } -} - -//______________________________________________________________________________ -void TGNewBrowser::SwitchMenus(TGCompositeFrame *from) -{ - // Move the menu from original frame to our TGMenuFrame, or display the - // menu associated to the current tab. - - TGFrameElement *fe = (TGFrameElement *)from->GetList()->First(); - if (!fe) { - if (fActMenuBar != fMenuBar) - ShowMenu(fMenuBar); - return; - } - TGCompositeFrame *embed = (TGCompositeFrame *)fe->fFrame; - TGFrameElement *el = 0; - if (embed && embed->GetList()) { - TIter next(embed->GetList()); - while ((el = (TGFrameElement *)next())) { - if (el->fFrame->InheritsFrom("TGMenuBar")) { - TGMenuBar *menu = (TGMenuBar *)el->fFrame; - if (fActMenuBar == menu) - return; - TGFrameElement *nw; - TIter nel(fMenuFrame->GetList()); - while ((nw = (TGFrameElement *) nel())) { - if (nw->fFrame == menu) { - ShowMenu(menu); - return; - } - } - ((TGCompositeFrame *)menu->GetParent())->HideFrame(menu); - menu->ReparentWindow(fMenuFrame); - fMenuFrame->AddFrame(menu, fLH2); - TGFrameElement *mel; - TIter mnext(menu->GetList()); - while ((mel = (TGFrameElement *) mnext())) { - TGMenuTitle *t = (TGMenuTitle *) mel->fFrame; - TGPopupMenu *popup = menu->GetPopup(t->GetName()); - RecursiveReparent(popup); - if (popup->GetEntry("Close Canvas")) { - TGMenuEntry *exit = popup->GetEntry("Close Canvas"); - popup->HideEntry(exit->GetEntryId()); - } - if (popup->GetEntry("Close Viewer")) { - TGMenuEntry *exit = popup->GetEntry("Close Viewer"); - popup->HideEntry(exit->GetEntryId()); - } - if (popup->GetEntry("Quit ROOT")) { - TGMenuEntry *exit = popup->GetEntry("Quit ROOT"); - popup->HideEntry(exit->GetEntryId()); - } - if (popup->GetEntry("Exit")) { - TGMenuEntry *exit = popup->GetEntry("Exit"); - popup->HideEntry(exit->GetEntryId()); - } - } - ShowMenu(menu); - return; - } - } - } - if (fActMenuBar != fMenuBar) - ShowMenu(fMenuBar); -} - -//______________________________________________________________________________ -void TGNewBrowser::RecursiveReparent(TGPopupMenu *popup) -{ - TGMenuEntry *entry = 0; - TIter next(popup->GetListOfEntries()); - while ((entry = (TGMenuEntry *)next())) { - if (entry->GetPopup()) { - RecursiveReparent(entry->GetPopup()); - } - } - popup->ReparentWindow(gClient->GetDefaultRoot()); -} - -//______________________________________________________________________________ -/* -void TGNewBrowser::ReallyDelete() -{ - // Really delete the browser and the this GUI. - - gInterpreter->DeleteGlobal(fBrowser); - delete fBrowser; // will in turn delete this object -} -*/ - -//______________________________________________________________________________ -TGFileBrowser* TGNewBrowser::MakeFileBrowser() -{ - // Create a file-browser. Caller should provide - // Start/StopEmbedding() calls and populate the new browser. - - TBrowserImp imp; - TBrowser *tb = new TBrowser("Pipi", "Strel", &imp); - TGFileBrowser *fb = new TGFileBrowser(tb, "File browser", 200, 500); - tb->SetBrowserImp((TBrowserImp *)fb); - fb->SetBrowser(tb); - fb->SetNewBrowser(this); - return fb; -} - -//______________________________________________________________________________ -void TGNewBrowser::InitPlugins() -{ - // Initialize default plugins. Could be also of the form: - // StartEmbedding(0); - // TPluginHandler *ph; - // ph = gROOT->GetPluginManager()->FindHandler("TGClassBrowser"); - // if (ph && ph->LoadPlugin() != -1) { - // ph->ExecPlugin(3, gClient->GetRoot(), 200, 500); - // } - // StopEmbedding(); - - // --- Left vertical area - - // File browser plugin... - StartEmbedding(0); - //gROOT->ProcessLine(Form("new TGFileBrowser((const TGWindow *)0x%lx, 200, 500)", - // gClient->GetRoot())); - { - TGFileBrowser *fb = MakeFileBrowser(); - fb->BrowseObj(gROOT); - fb->AddFSDirectory("/"); - fb->GotoDir(gSystem->WorkingDirectory()); - fb->Show(); - } - StopEmbedding(); - SetTabTitle("Files", 0); - - // Class browser plugin - StartEmbedding(0); - gROOT->ProcessLine(Form("new TGClassBrowser((const TGWindow *)0x%lx, 200, 500)", - gClient->GetRoot())); - StopEmbedding(); - SetTabTitle("Classes", 0); - - // --- Right main area - - // Editor plugin... - StartEmbedding(1); - gROOT->ProcessLine(Form("new TGTextEditor((const char *)0, (const TGWindow *)0x%lx)", - gClient->GetRoot())); - StopEmbedding(); - SetTabTitle("Editor 1", 1); - - // HTML plugin... - gSystem->Load("libGuiHtml"); - if (gSystem->Load("libRHtml") >= 0) { - StartEmbedding(1); - gROOT->ProcessLine(Form("new TGHtmlBrowser(\"http://root.cern.ch/root/html/ClassIndex.html\", \ - (const TGWindow *)0x%lx)", gClient->GetRoot())); - StopEmbedding(); - SetTabTitle("HTML", 1); - } - - // Canvas plugin... - StartEmbedding(1); - gROOT->ProcessLine("new TCanvas(\"BrowserCanvas1\", \"Browser Canvas 1\")"); - StopEmbedding(); - SetTabTitle("Canvas 1", 1); - -#if 0 - // GLViewer plugin... - StartEmbedding(1); - gROOT->ProcessLine(Form("new TGLSAViewer((TGFrame *)0x%lx, 0);", gClient->GetRoot())); - StopEmbedding(); - SetTabTitle("GL Viewer", 1); - - // PROOF plugin... - StartEmbedding(1); - gROOT->ProcessLine("new TSessionViewer();"); - StopEmbedding(); - SetTabTitle("PROOF", 1); -#endif - - // --- Right bottom area - - // Command plugin... - StartEmbedding(2); - gROOT->ProcessLine(Form("new TGCommandPlugin((const TGWindow *)0x%lx, 700, 300)", - gClient->GetRoot())); - StopEmbedding(); - SetTabTitle("Command", 2); - - // --- Select first tab everywhere - SetTab(0, 0); - SetTab(1, 0); - SetTab(2, 0); -} - -/* -//______________________________________________________________________________ -TBrowserImp *TGNewBrowser::NewBrowser(TBrowser *b, const char *title, UInt_t width, UInt_t height) -{ - TGNewBrowser *browser = new TGNewBrowser(b, title, width, height); - return (TBrowserImp *)browser; -} - -//______________________________________________________________________________ -TBrowserImp *TGNewBrowser::NewBrowser(TBrowser *b, const char *title, Int_t x, Int_t y, UInt_t width, UInt_t height) -{ - TGNewBrowser *browser = new TGNewBrowser(b, title, x, y, width, height); - return (TBrowserImp *)browser; -} -*/ diff --git a/EVE/Reve/TGNewBrowser.h b/EVE/Reve/TGNewBrowser.h deleted file mode 100644 index 77d5663f967..00000000000 --- a/EVE/Reve/TGNewBrowser.h +++ /dev/null @@ -1,108 +0,0 @@ -#ifndef ROOT_TGNewBrowser -#define ROOT_TGNewBrowser - -#ifndef ROOT_TGFrame -#include "TGFrame.h" -#endif - -//#ifndef ROOT_TBrowserImp -//#include "TBrowserImp.h" -//#endif - -class TGLayoutHints; -class TGTab; -class TGListTree; -class TGListTreeItem; -class TGPicture; -class TGLabel; -class TGComboBox; -class TGTextEntry; -class TGTextBuffer; -class TGTextView; -class TContextMenu; -class TRegexp; -class TGMenuBar; -class TGPopupMenu; -class TGStatusBar; -class TGPictureButton; -class TGVSplitter; -class TGHSplitter; - -class TGFileBrowser; - -class TGNewBrowser : public TGMainFrame { //, public TBrowserImp { - -protected: - - TGLayoutHints *fLH0, *fLH1, *fLH2, *fLH3, *fLH4; - TGLayoutHints *fLH5, *fLH6, *fLH7; - TGTab *fTabLeft; - TGTab *fTabRight; - TGTab *fTabBottom; - TGTab *fEditTab; - TGVerticalFrame *fVf; - TGHorizontalFrame *fHf; - TGHorizontalFrame *fH1; - TGHorizontalFrame *fH2; - TGVerticalFrame *fV1; - TGVerticalFrame *fV2; - TGVSplitter *fVSplitter; - TGHSplitter *fHSplitter; - TGCompositeFrame *fEditFrame; - TGHorizontalFrame *fTopMenuFrame; - TGHorizontalFrame *fPreMenuFrame; - TGHorizontalFrame *fMenuFrame; - TGHorizontalFrame *fToolbarFrame; - TGMenuBar *fMenuBar; - TGPopupMenu *fMenuFile; - TGCompositeFrame *fActMenuBar; - TGStatusBar *fStatusBar; - Int_t fNbTab[3]; - Int_t fCrTab[3]; - Int_t fPid; // current process id - -public: - enum EInsertPosition { - kLeft, kRight, kBottom - }; - - TGNewBrowser(const char *name = "ROOT Browser", UInt_t width = 800, UInt_t height = 500, Bool_t initshow=kTRUE); - TGNewBrowser(const char *name, Int_t x, Int_t y, UInt_t width, UInt_t height, Bool_t initshow=kTRUE); - virtual ~TGNewBrowser(); - - TGFileBrowser* MakeFileBrowser(); - void InitPlugins(); - - void CreateBrowser(const char *name); - void CloseWindow(); - void DoTab(Int_t id); - TGFrame *GetActFrame() const { return (TGFrame *)fEditFrame; } - TGStatusBar *GetStatusBar() const { return fStatusBar; } - TGTab *GetTabLeft() const { return fTabLeft; } - TGTab *GetTabRight() const { return fTabRight; } - TGTab *GetTabBottom() const { return fTabBottom; } - TGTab *GetTab(Int_t pos) const; - void SetTab(Int_t pos = kRight, Int_t subpos = -1); - void SetTabTitle(const char *title, Int_t pos = kRight, Int_t subpos = -1); - void HandleMenu(Int_t id); - using TGCompositeFrame::RemoveFrame; - void RecursiveReparent(TGPopupMenu *popup); - void RemoveFrame(Int_t pos, Int_t subpos); - void ShowMenu(TGCompositeFrame *menu); - TGCompositeFrame *StartEmbedding(Int_t pos = kRight, Int_t subpos = -1); - void StopEmbedding(TGLayoutHints *layout=0); - void SwitchMenus(TGCompositeFrame *from); - - virtual void ExecPlugin(const char *fname, Int_t pos = kRight, Int_t subpos = -1); - virtual Bool_t HandleKey(Event_t *event); - - // static TBrowserImp *NewBrowser(TBrowser *b = 0, const char *title = "ROOT Browser", UInt_t width = 800, UInt_t height = 500); - // static TBrowserImp *NewBrowser(TBrowser *b, const char *title, Int_t x, Int_t y, UInt_t width, UInt_t height); - - // overridden from TGMainFrame - // void ReallyDelete(); - - ClassDef(TGNewBrowser, 0) -}; - -#endif diff --git a/EVE/Reve/TGeoShapeExtract.cxx b/EVE/Reve/TGeoShapeExtract.cxx deleted file mode 100644 index 7e46e1ae8ed..00000000000 --- a/EVE/Reve/TGeoShapeExtract.cxx +++ /dev/null @@ -1,67 +0,0 @@ -// $Header$ - -// Copyright (C) 1999-2005, Matevz Tadel. All rights reserved. -// This file is part of GLED, released under GNU General Public License version 2. -// For the licensing terms see $GLEDSYS/LICENSE or http://www.gnu.org/. - -//__________________________________________________________________________ -// TGeoShapeExtract -// -// Vessel to carry hand-picked geometry from gled to reve. -// This class exists in both frameworks. - -#include "TGeoShapeExtract.h" - -#include -#include - -ClassImp(TGeoShapeExtract) - -/**************************************************************************/ - -TGeoShapeExtract::TGeoShapeExtract(const Text_t* n, const Text_t* t) : - TNamed(n,t), - mRnrSelf (true), - mRnrElements (true), - mShape (0), - mElements (0) -{ - memset(mTrans, 0, sizeof(mTrans)); - mTrans[0] = mTrans[5] = mTrans[10] = mTrans[15] = 1; - mRGBA [0] = mRGBA [1] = mRGBA [2] = mRGBA [3] = 1; -} - -TGeoShapeExtract::~TGeoShapeExtract() -{ - delete mShape; - delete mElements; -} - -/**************************************************************************/ - -Bool_t TGeoShapeExtract::HasElements() -{ - return mElements != 0 && mElements->GetSize() > 0; -} - -void TGeoShapeExtract::AddElement(TGeoShapeExtract* gse) -{ - if (mElements == 0) - mElements = new TList; - - mElements->Add(gse); -} - -/**************************************************************************/ - -void TGeoShapeExtract::SetTrans(const Double_t arr[16]) -{ - for(Int_t i=0; i<16; ++i) - mTrans[i] = arr[i]; -} - -void TGeoShapeExtract::SetRGBA (const Float_t arr[4]) -{ - for(Int_t i=0; i<4; ++i) - mRGBA[i] = arr[i]; -} diff --git a/EVE/Reve/TGeoShapeExtract.h b/EVE/Reve/TGeoShapeExtract.h deleted file mode 100644 index c91687debd4..00000000000 --- a/EVE/Reve/TGeoShapeExtract.h +++ /dev/null @@ -1,54 +0,0 @@ -// $Header$ - -// Copyright (C) 1999-2005, Matevz Tadel. All rights reserved. -// This file is part of GLED, released under GNU General Public License version 2. -// For the licensing terms see $GLEDSYS/LICENSE or http://www.gnu.org/. - -#ifndef RootGeo_TGeoShapeExtract_H -#define RootGeo_TGeoShapeExtract_H - -#include - -class TList; -class TGeoShape; - -class TGeoShapeExtract : public TNamed -{ - friend class ZGeoRepacker; - - TGeoShapeExtract(const TGeoShapeExtract&); // Not implemented - TGeoShapeExtract& operator=(const TGeoShapeExtract&); // Not implemented - -protected: - Double_t mTrans[16]; - Float_t mRGBA[4]; - Bool_t mRnrSelf; - Bool_t mRnrElements; - TGeoShape* mShape; - TList* mElements; - -public: - TGeoShapeExtract(const Text_t* n="TGeoShapeExtract", const Text_t* t=0); - ~TGeoShapeExtract(); - - Bool_t HasElements(); - void AddElement(TGeoShapeExtract* gse); - - void SetTrans(const Double_t arr[16]); - void SetRGBA (const Float_t arr[4]); - void SetRnrSelf(Bool_t r) { mRnrSelf = r; } - void SetRnrElements(Bool_t r) { mRnrElements = r; } - void SetShape(TGeoShape* s) { mShape = s; } - void SetElements(TList* e) { mElements = e; } - - Double_t* GetTrans() { return mTrans; } - Float_t* GetRGBA() { return mRGBA; } - Bool_t GetRnrSelf() { return mRnrSelf; } - Bool_t GetRnrElements() { return mRnrElements; } - TGeoShape* GetShape() { return mShape; } - TList* GetElements() { return mElements; } - - ClassDef(TGeoShapeExtract, 1) -}; // endclass TGeoShapeExtract - -#endif diff --git a/EVE/Reve/TTreeTools.cxx b/EVE/Reve/TTreeTools.cxx deleted file mode 100644 index 785708e5183..00000000000 --- a/EVE/Reve/TTreeTools.cxx +++ /dev/null @@ -1,109 +0,0 @@ -// $Header$ - -//__________________________________________________________________________ -// TTreeTools -// -// Collection of classes for TTree interaction. - -#include "TTreeTools.h" -#include -#include - -/**************************************************************************/ -/**************************************************************************/ - -ClassImp(TSelectorToEventList) - -TSelectorToEventList::TSelectorToEventList(TEventList* evl, const Text_t* sel) : - TSelectorDraw(), fEvList(evl) -{ - fInput.Add(new TNamed("varexp", "")); - fInput.Add(new TNamed("selection", sel)); - SetInputList(&fInput); -} - -Bool_t TSelectorToEventList::Process(Long64_t entry) -{ - if(GetSelect()->EvalInstance(0) != 0) - fEvList->Enter(entry); - return kTRUE; -} - -/**************************************************************************/ -/**************************************************************************/ - -ClassImp(TTreeQuery) - -Int_t TTreeQuery::Select(TTree* t, const Text_t* selection) -{ - TSelectorToEventList sel(this, selection); - t->Process(&sel, "goff"); - return GetN(); -} - -/**************************************************************************/ -// TPointSelectorConsumer, TPointSelector -/**************************************************************************/ - -ClassImp(TPointSelectorConsumer) -ClassImp(TPointSelector) - -TPointSelector::TPointSelector(TTree* t, - TPointSelectorConsumer* c, - const Text_t* vexp, const Text_t* sel) : - TSelectorDraw(), - - fTree (t), - fConsumer (c), - fVarexp (vexp), - fSelection (sel), - fSubIdExp (), - fSubIdNum (0) -{ - SetInputList(&fInput); -} - -Long64_t TPointSelector::Select(const Text_t* selection) -{ - TString var(fVarexp); - if (fSubIdExp.IsNull()) { - fSubIdNum = 0; - } else { - fSubIdNum = fSubIdExp.CountChar(':') + 1; - var += ":" + fSubIdExp; - } - - TString sel; - if (selection != 0) - sel = selection; - else - sel = fSelection; - - fInput.Delete(); - fInput.Add(new TNamed("varexp", var.Data())); - fInput.Add(new TNamed("selection", sel.Data())); - - if (fConsumer) - fConsumer->InitFill(fSubIdNum); - - // 'para' option -> hack allowing arbitrary dimensions. - if(fTree) - fTree->Process(this, "goff para"); - - return fSelectedRows; -} - -Long64_t TPointSelector::Select(TTree* t, const Text_t* selection) -{ - fTree = t; - return Select(selection); -} - -void TPointSelector::TakeAction() -{ - fSelectedRows += fNfill; - // printf("TPointSelector::TakeAction nfill=%d, nall=%lld\n", fNfill, fSelectedRows); - if (fConsumer) { - fConsumer->TakeAction(this); - } -} diff --git a/EVE/Reve/TTreeTools.h b/EVE/Reve/TTreeTools.h deleted file mode 100644 index a44f56f2d8f..00000000000 --- a/EVE/Reve/TTreeTools.h +++ /dev/null @@ -1,121 +0,0 @@ -// $Header - -#ifndef REVE_TTreeTools_H -#define REVE_TTreeTools_H - -#include -#include - -/**************************************************************************/ -// TSelectorToEventList -/**************************************************************************/ - -class TSelectorToEventList : public TSelectorDraw -{ - TSelectorToEventList(const TSelectorToEventList&); // Not implemented - TSelectorToEventList& operator=(const TSelectorToEventList&); // Not implemented - -protected: - TEventList* fEvList; - TList fInput; -public: - TSelectorToEventList(TEventList* evl, const Text_t* sel); - - virtual Int_t Version() const { return 1; } - virtual Bool_t Process(Long64_t entry); - - ClassDef(TSelectorToEventList, 1) -}; - -/**************************************************************************/ -// TTreeQuery -/**************************************************************************/ - -class TTreeQuery : public TEventList -{ -public: - TTreeQuery() : TEventList() {} - - Int_t Select(TTree* t, const Text_t* selection); - - ClassDef(TTreeQuery, 1) -}; - -/**************************************************************************/ -// TPointSelectorConsumer, TPointSelector -/**************************************************************************/ - -class TPointSelector; - -class TPointSelectorConsumer -{ -public: - enum TreeVarType_e { TVT_XYZ, TVT_RPhiZ }; - -protected: - TreeVarType_e fSourceCS; // Coordinate-System of the source tree variables - -public: - TPointSelectorConsumer(TreeVarType_e cs=TVT_XYZ) :fSourceCS(cs) {} - virtual ~TPointSelectorConsumer() {} - - virtual void InitFill(Int_t /*subIdNum*/) {} - virtual void TakeAction(TPointSelector*) = 0; - - TreeVarType_e GetSourceCS() const { return fSourceCS; } - void SetSourceCS(TreeVarType_e cs) { fSourceCS = cs; } - - ClassDef(TPointSelectorConsumer, 1); -}; - -class TPointSelector : public TSelectorDraw -{ - TPointSelector(const TPointSelector&); // Not implemented - TPointSelector& operator=(const TPointSelector&); // Not implemented - -protected: - TTree *fTree; - TPointSelectorConsumer *fConsumer; - - TString fVarexp; - TString fSelection; - - TString fSubIdExp; - Int_t fSubIdNum; - - TList fInput; - -public: - TPointSelector(TTree* t=0, TPointSelectorConsumer* c=0, - const Text_t* vexp="", const Text_t* sel=""); - virtual ~TPointSelector() {} - - virtual Long64_t Select(const Text_t* selection=0); - virtual Long64_t Select(TTree* t, const Text_t* selection=0); - virtual void TakeAction(); - - - TTree* GetTree() const { return fTree; } - void SetTree(TTree* t) { fTree = t; } - - TPointSelectorConsumer* GetConsumer() const { return fConsumer; } - void SetConsumer(TPointSelectorConsumer* c) { fConsumer = c; } - - const Text_t* GetVarexp() const { return fVarexp; } - void SetVarexp(const Text_t* v) { fVarexp = v; } - - const Text_t* GetSelection() const { return fSelection; } - void SetSelection(const Text_t* s) { fSelection = s; } - - const Text_t* GetSubIdExp() const { return fSubIdExp; } - void SetSubIdExp(const Text_t* s) { fSubIdExp = s; } - - Int_t GetSubIdNum() const { return fSubIdNum; } - - ClassDef(TPointSelector, 1); -}; - -/**************************************************************************/ -/**************************************************************************/ - -#endif diff --git a/EVE/Reve/Track.cxx b/EVE/Reve/Track.cxx deleted file mode 100644 index f0e324844a2..00000000000 --- a/EVE/Reve/Track.cxx +++ /dev/null @@ -1,1563 +0,0 @@ -// $Header$ - -#include "Track.h" -#include "MCHelixLine.hi" -#include "PointSet.h" - -#include -#include -#include -#include - -// Updates -#include -#include -#include -#include - -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________________ -// Track -// -// Visual representation of a track. -// - -ClassImp(Reve::Track) - -//______________________________________________________________________________ -Track::Track() : - Line(), - - fV(), - fP(), - fBeta(0), - fPdg(0), - fCharge(0), - fLabel(kMinInt), - fIndex(kMinInt), - fPathMarks(), - - fRnrStyle(0) -{ - // Default constructor. -} - -//______________________________________________________________________________ -Track::Track(TParticle* t, Int_t label, TrackRnrStyle* rs): - Line(), - - fV(t->Vx(), t->Vy(), t->Vz()), - fP(t->Px(), t->Py(), t->Pz()), - fBeta(t->P()/t->Energy()), - fPdg(0), - fCharge(0), - fLabel(label), - fIndex(kMinInt), - fPathMarks(), - - fRnrStyle(0) -{ - // Constructor from TParticle. - - SetRnrStyle(rs); - fMainColorPtr = &fLineColor; - - TParticlePDG* pdgp = t->GetPDG(); - if (pdgp) { - fPdg = pdgp->PdgCode(); - fCharge = (Int_t) TMath::Nint(pdgp->Charge()/3); - } - - SetName(t->GetName()); -} - -//______________________________________________________________________________ -Track::Track(Reve::MCTrack* t, TrackRnrStyle* rs): - Line(), - - fV(t->Vx(), t->Vy(), t->Vz()), - fP(t->Px(), t->Py(), t->Pz()), - fBeta(t->P()/t->Energy()), - fPdg(0), - fCharge(0), - fLabel(t->label), - fIndex(t->index), - fPathMarks(), - - fRnrStyle(0) -{ - // Constructor from Reve Monte Carlo track. - - SetRnrStyle(rs); - fMainColorPtr = &fLineColor; - - TParticlePDG* pdgp = t->GetPDG(); - if(pdgp == 0) { - t->ResetPdgCode(); pdgp = t->GetPDG(); - } - fCharge = (Int_t) TMath::Nint(pdgp->Charge()/3); - - SetName(t->GetName()); -} - -//______________________________________________________________________________ -Track::Track(Reve::RecTrack* t, TrackRnrStyle* rs) : - Line(), - - fV(t->V), - fP(t->P), - fBeta(t->beta), - fPdg(0), - fCharge(t->sign), - fLabel(t->label), - fIndex(t->index), - fPathMarks(), - - fRnrStyle(0) -{ - // Constructor from Reve reconstructed track. - - SetRnrStyle(rs); - fMainColorPtr = &fLineColor; - - SetName(t->GetName()); -} - -//______________________________________________________________________________ -Track::Track(const Track& t) : - Line(), - fV(t.fV), - fP(t.fP), - fBeta(t.fBeta), - fPdg(t.fPdg), - fCharge(t.fCharge), - fLabel(t.fLabel), - fIndex(t.fIndex), - fPathMarks(), - fRnrStyle(0) -{ - // Copy constructor. - - SetMainColor(t.GetMainColor()); - // Line - fRnrLine = t.fRnrLine; - fRnrPoints = t.fRnrPoints; - // TLineAttrib - fLineColor = t.fLineColor; - fLineStyle = t.fLineStyle; - fLineWidth = t.fLineWidth; - SetPathMarks(t); - SetRnrStyle (t.fRnrStyle); -} - -//______________________________________________________________________________ -Track::~Track() -{ - // Destructor. - - SetRnrStyle(0); - for (vpPathMark_i i=fPathMarks.begin(); i!=fPathMarks.end(); ++i) - delete *i; -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void Track::SetStdTitle() -{ - // Set standard track title based on most data-member values. - - TString idx(fIndex == kMinInt ? "" : Form("%d", fIndex)); - TString lbl(fLabel == kMinInt ? "" : Form("%d", fLabel)); - SetTitle(Form("Index=%s, Label=%s\nChg=%d, Pdg=%d\n" - "pT=%.3f, pZ=%.3f\nV=(%.3f, %.3f, %.3f)", - idx.Data(), lbl.Data(), fCharge, fPdg, - fP.Perp(), fP.z, fV.x, fV.y, fV.z)); -} - -//______________________________________________________________________________ -void Track::SetTrackParams(const Track& t) -{ - // Copy track parameters from t. - // PathMarks are cleared. - - fV = t.fV; - fP = t.fP; - fBeta = t.fBeta; - fPdg = t.fPdg; - fCharge = t.fCharge; - fLabel = t.fLabel; - fIndex = t.fIndex; - - SetMainColor(t.GetMainColor()); - // Line - fRnrLine = t.fRnrLine; - fRnrPoints = t.fRnrPoints; - // TLineAttrib - fLineColor = t.fLineColor; - fLineStyle = t.fLineStyle; - fLineWidth = t.fLineWidth; - fPathMarks.clear(); - SetRnrStyle(t.fRnrStyle); -} - -//______________________________________________________________________________ -void Track::SetPathMarks(const Track& t) -{ - // Copy path-marks from t. - - const std::vector& refs = t.GetPathMarksRef(); - for(std::vector::const_iterator i=refs.begin(); i!=refs.end(); ++i) - { - fPathMarks.push_back(new PathMark(**i)); - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void Track::SetRnrStyle(TrackRnrStyle* rs) -{ - // Set track's render style. - // Reference counts of old and new render-style are updated. - - if (fRnrStyle == rs) return; - if (fRnrStyle) fRnrStyle->DecRefCount(this); - fRnrStyle = rs; - if (fRnrStyle) rs->IncRefCount(this); -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void Track::SetAttLineAttMarker(TrackList* tl) -{ - // Set line and marker attributes from TrackList. - - SetLineColor(tl->GetLineColor()); - SetLineStyle(tl->GetLineStyle()); - SetLineWidth(tl->GetLineWidth()); - - SetMarkerColor(tl->GetMarkerColor()); - SetMarkerStyle(tl->GetMarkerStyle()); - SetMarkerSize(tl->GetMarkerSize()); -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void Track::MakeTrack(Bool_t recurse) -{ - // Calculate track representation based on track data and current - // settings of the render-style. - // If recurse is true, descend into children. - - TrackRnrStyle& RS((fRnrStyle != 0) ? *fRnrStyle : TrackRnrStyle::fgDefStyle); - - Float_t px = fP.x, py = fP.y, pz = fP.z; - - MCVertex mc_v0; - mc_v0.x = fV.x; - mc_v0.y = fV.y; - mc_v0.z = fV.z; - mc_v0.t = 0; - - std::vector track_points; - Bool_t decay = kFALSE; - - if ((TMath::Abs(fV.z) > RS.fMaxZ) || (fV.x*fV.x + fV.y*fV.y > RS.fMaxR*RS.fMaxR)) - goto make_polyline; - - if (fCharge != 0 && TMath::Abs(RS.fMagField) > 1e-5 && fP.Perp2() > 1e-12) - { - // Charged particle in magnetic field with non-zero pT. - - Float_t a = RS.fgkB2C * RS.fMagField * fCharge; - - MCHelix helix(fRnrStyle, &mc_v0, TMath::C()*fBeta, &track_points, a); //m->cm - helix.Init(TMath::Sqrt(px*px+py*py), pz); - // Set max number of points for loop-to-vertex. - // loop-to-bounds (last step) does this separately. - helix.NMax = 4096; - - if (!fPathMarks.empty()) - { - for(std::vector::iterator i=fPathMarks.begin(); i!=fPathMarks.end(); ++i) - { - Reve::PathMark* pm = *i; - - if (RS.fFitReferences && pm->type == Reve::PathMark::Reference) - { - if(TMath::Abs(pm->V.z) > RS.fMaxZ || - TMath::Sqrt(pm->V.x*pm->V.x + pm->V.y*pm->V.y) > RS.fMaxR) - goto helix_bounds; - - // printf("%s fit reference \n", fName.Data()); - helix.LoopToVertex(px, py, pz, pm->V.x, pm->V.y, pm->V.z); - px = pm->P.x; - py = pm->P.y; - pz = pm->P.z; - } - else if(RS.fFitDaughters && pm->type == Reve::PathMark::Daughter) - { - if(TMath::Abs(pm->V.z) > RS.fMaxZ || - TMath::Sqrt(pm->V.x*pm->V.x + pm->V.y*pm->V.y) > RS.fMaxR) - goto helix_bounds; - - // printf("%s fit daughter \n", fName.Data()); - helix.LoopToVertex(px, py, pz, pm->V.x, pm->V.y, pm->V.z); - px -= pm->P.x; - py -= pm->P.y; - pz -= pm->P.z; - } - else if(RS.fFitDecay && pm->type == Reve::PathMark::Decay) - { - if(TMath::Abs(pm->V.z) > RS.fMaxZ || - TMath::Sqrt(pm->V.x*pm->V.x + pm->V.y*pm->V.y) > RS.fMaxR) - goto helix_bounds; - helix.LoopToVertex(px, py, pz, pm->V.x, pm->V.y, pm->V.z); - decay = true; - break; - } - if (track_points.size() > 4096) - { - Warning("Track::MakeTrack", "exceeding 4k points (%u) for '%s'; aborting extrapolation.", - track_points.size(), GetName()); - goto make_polyline; - } - } - } - helix_bounds: - // go to bounds - if(!decay || RS.fFitDecay == kFALSE) - { - helix.LoopToBounds(px,py,pz); - // printf("%s loop to bounds \n",fName.Data() ); - } - - } else { - - // Neutral particle or no field - - MCLine line(fRnrStyle, &mc_v0, TMath::C()*fBeta, &track_points); - - if(!fPathMarks.empty()) - { - for(std::vector::iterator i=fPathMarks.begin(); i!=fPathMarks.end(); ++i) - { - Reve::PathMark* pm = *i; - - if(RS.fFitDaughters && pm->type == Reve::PathMark::Daughter) - { - if(TMath::Abs(pm->V.z) > RS.fMaxZ || - TMath::Sqrt(pm->V.x*pm->V.x + pm->V.y*pm->V.y) > RS.fMaxR) - { - goto line_bounds; - } - line.GotoVertex(pm->V.x, pm->V.y, pm->V.z); - fP.x -= pm->P.x; - fP.y -= pm->P.y; - fP.z -= pm->P.z; - } - - if(RS.fFitDecay && pm->type == Reve::PathMark::Decay) - { - if(TMath::Abs(pm->V.z) > RS.fMaxZ || - TMath::Sqrt(pm->V.x*pm->V.x + pm->V.y*pm->V.y) > RS.fMaxR) - { - goto line_bounds; - } - line.GotoVertex(pm->V.x, pm->V.y, pm->V.z); - decay = true; - break; - } - } - } - - line_bounds: - if(!decay || RS.fFitDecay == kFALSE) - line.GotoBounds(px,py,pz); - - } -make_polyline: - { - Int_t size = TMath::Min(4096, (Int_t) track_points.size()); - // printf("track '%s' N = %u\n", GetName(), track_points.size()); - Reset(size); - for(Int_t i=0; i(*i); - if(t) t->MakeTrack(recurse); - } - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -TClass* Track::ProjectedClass() const -{ - // Virtual from NLTProjectable, return NLTTrack class. - - return NLTTrack::Class(); -} - -/******************************************************************************/ - -namespace { - -struct cmp_pathmark -{ - bool operator()(PathMark* const & a, PathMark* const & b) - { return a->time < b->time; } -}; - -} - -//______________________________________________________________________________ -void Track::SortPathMarksByTime() -{ - // Sort registerd pat-marks by time. - - std::sort(fPathMarks.begin(), fPathMarks.end(), cmp_pathmark()); -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void Track::ImportHits() -{ - // Import hits with same label as the track. - // Uses macro "hits_from_label.C". - - Reve::LoadMacro("hits_from_label.C"); - gROOT->ProcessLine(Form("hits_from_label(%d, (Reve::RenderElement*)%p);", - fLabel, this)); -} - -//______________________________________________________________________________ -void Track::ImportClusters() -{ - // Import clusters with same label as the track. - // Uses macro "clusters_from_label.C". - - Reve::LoadMacro("clusters_from_label.C"); - gROOT->ProcessLine(Form("clusters_from_label(%d, (Reve::RenderElement*)%p);", - fLabel, this)); -} - -//______________________________________________________________________________ -void Track::ImportClustersFromIndex() -{ - // Import clusters marked with same reconstructed track index as the track. - // Uses macro "clusters_from_index.C". - - static const Exc_t eH("Track::ImportClustersFromIndex "); - - if (fIndex == kMinInt) - throw(eH + "index not set."); - - Reve::LoadMacro("clusters_from_index.C"); - gROOT->ProcessLine(Form("clusters_from_index(%d, (Reve::RenderElement*)%p);", - fIndex, this)); -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void Track::ImportKine() -{ - // Import kinematics of the track's label recursively. - // Uses macro "kine_tracks.C". - - static const Exc_t eH("Track::ImportKine "); - - if (fLabel == kMinInt) - throw(eH + "label not set."); - - Int_t label; - if (fLabel < 0) { - Warning(eH, "label negative, taking absolute value."); - label = -fLabel; - } else { - label = fLabel; - } - - Reve::LoadMacro("kine_tracks.C"); - gROOT->ProcessLine(Form("kine_track(%d, kTRUE, kTRUE, kTRUE, kTRUE, (Reve::RenderElement*)%p);", - label, this)); - -} - -//______________________________________________________________________________ -void Track::ImportKineWithArgs(Bool_t importMother, Bool_t importDaugters, - Bool_t colorPdg, Bool_t recurse) -{ - // Import kinematics of the track's label. Arguments steer the - // import process: - // importMother import particle with track's label - // importDaugters import direct daughters of label - // colorPdg color kinematics by PDG code - // recurse recursive import of daughters' daughters - // Uses macro "kine_tracks.C". - - static const Exc_t eH("Track::ImportKineWithArgs "); - - if (fLabel == kMinInt) - throw(eH + "label not set."); - - Int_t label; - if (fLabel < 0) { - Warning(eH, "label negative, taking absolute value."); - label = -fLabel; - } else { - label = fLabel; - } - - Reve::LoadMacro("kine_tracks.C"); - gROOT->ProcessLine(Form("kine_track(%d, %d, %d, %d, %d, (Reve::RenderElement*)%p);", - label, importMother, importDaugters, colorPdg, recurse, this)); -} - -/******************************************************************************/ - -void Track::PrintParticle() -{ - // Print track parameters. - - printf("particle %s sign %d\n", GetName(), fCharge); - printf("V (%f, %f, %f) \n", fV.x, fV.y, fV.z); - printf("P (%f, %f, %f) Pt(%f)\n", fP.x, fP.y, fP.z, fP.Perp()); -} - -//______________________________________________________________________________ -void Track::PrintKineStack() -{ - // Print kinematics pertaining to track's label. - // Uses macro "print_kine_from_label.C". - - static const Exc_t eH("Track::PrintKineStack "); - - if (fLabel == kMinInt) - throw(eH + "label not set."); - - Int_t label; - if (fLabel < 0) { - Warning(eH, "label negative, taking absolute value."); - label = -fLabel; - } else { - label = fLabel; - } - - Reve::LoadMacro("print_kine_from_label.C"); - gROOT->ProcessLine(Form("print_kine_from_label(%d);", label)); -} - -//______________________________________________________________________________ -void Track::PrintPathMarks() -{ - // Print registered path-marks. - - static const Exc_t eH("Track::PrintPathMarks "); - - printf("Track '%s', number of path marks %d, label %d\n", - GetName(), fPathMarks.size(), fLabel); - - PathMark* pm; - for(vpPathMark_i i=fPathMarks.begin(); i!=fPathMarks.end(); i++) - { - pm = *i; - printf(" %-9s p: %8f %8f %8f Vertex: %8e %8e %8e %g \n", - pm->type_name(), - pm->P.x, pm->P.y, pm->P.z, - pm->V.x, pm->V.y, pm->V.z, - pm->time); - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void Track::CtrlClicked(Reve::Track* track) -{ - // Emits "CtrlClicked(Reve::Track*)" signal. - // Called from TrackGL on secondary-selection. - - Emit("CtrlClicked(Reve::Track*)", (Long_t)track); -} - -//______________________________________________________________________________ -void Track::SetLineStyle(Style_t lstyle) -{ - // Set line-style of the track. - // The style is propagated to projected tracks. - - TAttLine::SetLineStyle(lstyle); - std::list::iterator pi = fProjectedList.begin(); - while (pi != fProjectedList.end()) - { - Track* pt = dynamic_cast(*pi); - if (pt) - { - pt->SetLineStyle(lstyle); - pt->ElementChanged(); - } - ++pi; - } -} - - -/******************************************************************************/ -/******************************************************************************/ - -//______________________________________________________________________________ -// TrackRnrStyle -// -// Holding structure for a number of track rendering parameters. -// -// This is decoupled from Track/TrackList to allow sharing of the -// RnrStyle among several instances. Back references are kept so the -// tracks can be recreated when the parameters change. -// -// TrackList has Get/Set methods for RnrStlye. TrackEditor and -// TrackListEditor provide editor access. - -ClassImp(Reve::TrackRnrStyle) - -Float_t TrackRnrStyle::fgDefMagField = 5; -const Float_t TrackRnrStyle::fgkB2C = 0.299792458e-3; -TrackRnrStyle TrackRnrStyle::fgDefStyle; - -//______________________________________________________________________________ -TrackRnrStyle::TrackRnrStyle() : - TObject(), - ReferenceBackPtr(), - - fMagField(fgDefMagField), - - fMaxR (350), - fMaxZ (450), - - fMaxOrbs (0.5), - fMinAng (45), - fDelta (0.1), - - fEditPathMarks(kFALSE), - fPMAtt(), - - fFitDaughters (kTRUE), - fFitReferences (kTRUE), - fFitDecay (kTRUE), - - fRnrDaughters (kTRUE), - fRnrReferences (kTRUE), - fRnrDecay (kTRUE), - - fRnrFV(kFALSE), - fFVAtt() -{ - // Default constructor. - - fPMAtt.SetMarkerColor(4); - fPMAtt.SetMarkerStyle(2); - - fFVAtt.SetMarkerSize(0.6); - fFVAtt.SetMarkerColor(4); - fFVAtt.SetMarkerStyle(2); -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void TrackRnrStyle::RebuildTracks() -{ - // Rebuild all tracks using this render-style. - - Track* track; - std::list::iterator i = fBackRefs.begin(); - while (i != fBackRefs.end()) - { - track = dynamic_cast(*i); - track->MakeTrack(); - track->ElementChanged(); - ++i; - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void TrackRnrStyle::SetMaxR(Float_t x) -{ - // Set maximum radius and rebuild tracks. - - fMaxR = x; - RebuildTracks(); -} - -//______________________________________________________________________________ -void TrackRnrStyle::SetMaxZ(Float_t x) -{ - // Set maximum z and rebuild tracks. - - fMaxZ = x; - RebuildTracks(); -} - -//______________________________________________________________________________ -void TrackRnrStyle::SetMaxOrbs(Float_t x) -{ - // Set maximum number of orbits and rebuild tracks. - - fMaxOrbs = x; - RebuildTracks(); -} - -//______________________________________________________________________________ -void TrackRnrStyle::SetMinAng(Float_t x) -{ - // Set minimum step angle and rebuild tracks. - - fMinAng = x; - RebuildTracks(); -} - -//______________________________________________________________________________ -void TrackRnrStyle::SetDelta(Float_t x) -{ - // Set maximum error and rebuild tracks. - - fDelta = x; - RebuildTracks(); -} - -//______________________________________________________________________________ -void TrackRnrStyle::SetFitDaughters(Bool_t x) -{ - // Set daughter creation point fitting and rebuild tracks. - - fFitDaughters = x; - RebuildTracks(); -} - -//______________________________________________________________________________ -void TrackRnrStyle::SetFitReferences(Bool_t x) -{ - // Set track-reference fitting and rebuild tracks. - - fFitReferences = x; - RebuildTracks(); -} - -//______________________________________________________________________________ -void TrackRnrStyle::SetFitDecay(Bool_t x) -{ - // Set decay fitting and rebuild tracks. - - fFitDecay = x; - RebuildTracks(); -} - -//______________________________________________________________________________ -void TrackRnrStyle::SetRnrDecay(Bool_t rnr) -{ - // Set decay rendering and rebuild tracks. - - fRnrDecay = rnr; - RebuildTracks(); -} - -//______________________________________________________________________________ -void TrackRnrStyle::SetRnrDaughters(Bool_t rnr) -{ - // Set daughter rendering and rebuild tracks. - - fRnrDaughters = rnr; - RebuildTracks(); -} - -//______________________________________________________________________________ -void TrackRnrStyle::SetRnrReferences(Bool_t rnr) -{ - // Set track-reference rendering and rebuild tracks. - - fRnrReferences = rnr; - RebuildTracks(); -} - - -/**************************************************************************/ -/**************************************************************************/ - -//______________________________________________________________________________ -// TrackList -// - -ClassImp(Reve::TrackList) - -//______________________________________________________________________________ -TrackList::TrackList(TrackRnrStyle* rs) : - RenderElementList(), - TAttMarker(1, 20, 1), - TAttLine(1,1,1), - - fRecurse(kTRUE), - fRnrStyle(0), - fRnrLine(kTRUE), - fRnrPoints(kFALSE), - - fMinPt (0), fMaxPt (0), fLimPt (0), - fMinP (0), fMaxP (0), fLimP (0) -{ - // Constructor. If TrackRenderStyle argument is 0, a new default - // render-style is created. - - fChildClass = Track::Class(); // override member from base RenderElementList - - fMainColorPtr = &fLineColor; - if (fRnrStyle== 0) rs = new TrackRnrStyle; - SetRnrStyle(rs); -} - -//______________________________________________________________________________ -TrackList::TrackList(const Text_t* name, TrackRnrStyle* rs) : - RenderElementList(name), - TAttMarker(1, 20, 1), - TAttLine(1,1,1), - - fRecurse(kTRUE), - fRnrStyle (0), - fRnrLine(kTRUE), - fRnrPoints(kFALSE), - - fMinPt (0), fMaxPt (0), fLimPt (0), - fMinP (0), fMaxP (0), fLimP (0) -{ - // Constructor. If TrackRenderStyle argument is 0, a new default - // render-style is created. - - fChildClass = Track::Class(); // override member from base RenderElementList - - fMainColorPtr = &fLineColor; - if (fRnrStyle== 0) rs = new TrackRnrStyle; - SetRnrStyle(rs); -} - -//______________________________________________________________________________ -TrackList::~TrackList() -{ - // Destructor. - - SetRnrStyle(0); -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void TrackList::SetRnrStyle(TrackRnrStyle* rs) -{ - // Set default render-style for tracks. - // This is not enforced onto the tracks themselves but this is the - // render-style that is show in the TrackListEditor. - - if (fRnrStyle == rs) return; - if (fRnrStyle) fRnrStyle->DecRefCount(); - fRnrStyle = rs; - if (fRnrStyle) rs->IncRefCount(); -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void TrackList::MakeTracks(Bool_t recurse) -{ - // Regenerate the visual representations of tracks. - // The momentum limits are rescanned during the same traversal. - - fLimPt = fLimP = 0; - - for (List_i i=fChildren.begin(); i!=fChildren.end(); ++i) - { - Track* track = (Track*)(*i); - track->MakeTrack(recurse); - - fLimPt = TMath::Max(fLimPt, track->fP.Perp()); - fLimP = TMath::Max(fLimP, track->fP.Mag()); - if (recurse) - FindMomentumLimits(*i, recurse); - } - - fLimPt = RoundMomentumLimit(fLimPt); - fLimP = RoundMomentumLimit(fLimP); - if (fMaxPt == 0) fMaxPt = fLimPt; - if (fMaxP == 0) fMaxP = fLimP; - - gReve->Redraw3D(); -} - -//______________________________________________________________________________ -void TrackList::FindMomentumLimits(RenderElement* el, Bool_t recurse) -{ - // Loop over track elements of argument el and find highest pT and p. - // These are stored in members fLimPt and fLimP. - - for (List_i i=el->BeginChildren(); i!=el->EndChildren(); ++i) - { - Track* track = dynamic_cast(*i); - if (track) - { - fLimPt = TMath::Max(fLimPt, track->fP.Perp()); - fLimP = TMath::Max(fLimP, track->fP.Mag()); - if (recurse) - FindMomentumLimits(*i, recurse); - } - } -} - -//______________________________________________________________________________ -Float_t TrackList::RoundMomentumLimit(Float_t x) -{ - // Round the momentum limit up to a nice value. - - using namespace TMath; - Double_t fac = Power(10, 1 - Floor(Log10(x))); - return Ceil(fac*x) / fac; -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void TrackList::SetRnrLine(Bool_t rnr) -{ - // Set rendering of track as line for the list and the elements. - - for (List_i i=BeginChildren(); i!=EndChildren(); ++i) - { - Track* track = (Track*)(*i); - if (track->GetRnrLine() == fRnrLine) - track->SetRnrLine(rnr); - if (fRecurse) - SetRnrLine(rnr, *i); - } - fRnrLine = rnr; -} - -//______________________________________________________________________________ -void TrackList::SetRnrLine(Bool_t rnr, RenderElement* el) -{ - // Set rendering of track as line for children of el. - - Track* track; - for (List_i i=el->BeginChildren(); i!=el->EndChildren(); ++i) - { - track = dynamic_cast(*i); - if (track && (track->GetRnrLine() == fRnrLine)) - track->SetRnrLine(rnr); - if (fRecurse) - SetRnrLine(rnr, *i); - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void TrackList::SetRnrPoints(Bool_t rnr) -{ - // Set rendering of track as points for the list and the elements. - - for (List_i i=BeginChildren(); i!=EndChildren(); ++i) - { - Track* track = (Track*)(*i); - if (track->GetRnrPoints() == fRnrPoints) - track->SetRnrPoints(rnr); - if (fRecurse) - SetRnrPoints(rnr, *i); - } - fRnrPoints = rnr; -} - -//______________________________________________________________________________ -void TrackList::SetRnrPoints(Bool_t rnr, RenderElement* el) -{ - // Set rendering of track as points for children of el. - - Track* track; - for (List_i i=el->BeginChildren(); i!=el->EndChildren(); ++i) - { - track = dynamic_cast(*i); - if (track) - if (track->GetRnrPoints() == fRnrPoints) - track->SetRnrPoints(rnr); - if (fRecurse) - SetRnrPoints(rnr, *i); - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void TrackList::SetMainColor(Color_t col) -{ - // Set main (line) color for the list and the elements. - - for (List_i i=BeginChildren(); i!=EndChildren(); ++i) - { - Track* track = (Track*)(*i); - if (track->GetLineColor() == fLineColor) - track->SetLineColor(col); - if (fRecurse) - SetLineColor(col, *i); - } - RenderElement::SetMainColor(col); -} - -//______________________________________________________________________________ -void TrackList::SetLineColor(Color_t col, RenderElement* el) -{ - // Set line color for children of el. - - Track* track; - for (List_i i=el->BeginChildren(); i!=el->EndChildren(); ++i) - { - track = dynamic_cast(*i); - if (track && track->GetLineColor() == fLineColor) - track->SetLineColor(col); - if (fRecurse) - SetLineColor(col, *i); - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void TrackList::SetLineWidth(Width_t width) -{ - // Set line width for the list and the elements. - - for (List_i i=BeginChildren(); i!=EndChildren(); ++i) - { - Track* track = (Track*)(*i); - if (track->GetLineWidth() == fLineWidth) - track->SetLineWidth(width); - if (fRecurse) - SetLineWidth(width, *i); - } - fLineWidth=width; -} - -//______________________________________________________________________________ -void TrackList::SetLineWidth(Width_t width, RenderElement* el) -{ - // Set line width for children of el. - - Track* track; - for (List_i i=el->BeginChildren(); i!=el->EndChildren(); ++i) - { - track = dynamic_cast(*i); - if (track && track->GetLineWidth() == fLineWidth) - track->SetLineWidth(width); - if (fRecurse) - SetLineWidth(width, *i); - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void TrackList::SetLineStyle(Style_t style) -{ - // Set line style for the list and the elements. - - for (List_i i=BeginChildren(); i!=EndChildren(); ++i) - { - Track* track = (Track*)(*i); - if (track->GetLineStyle() == fLineStyle) - track->SetLineStyle(style); - if (fRecurse) - SetLineStyle(style, *i); - } - fLineStyle=style; -} - -//______________________________________________________________________________ -void TrackList::SetLineStyle(Style_t style, RenderElement* el) -{ - // Set line style for children of el. - - Track* track; - for (List_i i=el->BeginChildren(); i!=el->EndChildren(); ++i) - { - track = dynamic_cast(*i); - if (track && track->GetLineStyle() == fLineStyle) - track->SetLineStyle(style); - if (fRecurse) - SetLineStyle(style, *i); - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void TrackList::SetMarkerStyle(Style_t style) -{ - // Set marker style for the list and the elements. - - for (List_i i=BeginChildren(); i!=EndChildren(); ++i) - { - Track* track = (Track*)(*i); - if (track->GetMarkerStyle() == fMarkerStyle) - track->SetMarkerStyle(style); - if (fRecurse) - SetMarkerStyle(style, *i); - } - fMarkerStyle=style; -} - -//______________________________________________________________________________ -void TrackList::SetMarkerStyle(Style_t style, RenderElement* el) -{ - // Set marker style for children of el. - - Track* track; - for (List_i i=el->BeginChildren(); i!=el->EndChildren(); ++i) - { - track = dynamic_cast(*i); - if (track && track->GetMarkerStyle() == fMarkerStyle) - track->SetMarkerStyle(style); - if(fRecurse) - SetMarkerStyle(style, *i); - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void TrackList::SetMarkerColor(Color_t col) -{ - // Set marker color for the list and the elements. - - for (List_i i=BeginChildren(); i!=EndChildren(); ++i) - { - Track* track = (Track*)(*i); - if (track->GetMarkerColor() == fMarkerColor) - track->SetMarkerColor(col); - if (fRecurse) - SetMarkerColor(col, *i); - } - fMarkerColor=col; -} - -//______________________________________________________________________________ -void TrackList::SetMarkerColor(Color_t col, RenderElement* el) -{ - // Set marker color for children of el. - - Track* track; - for (List_i i=el->BeginChildren(); i!=el->EndChildren(); ++i) - { - track = dynamic_cast(*i); - if (track && track->GetMarkerColor() == fMarkerColor) - track->SetMarkerColor(col); - if (fRecurse) - SetMarkerColor(col, *i); - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void TrackList::SetMarkerSize(Size_t size) -{ - // Set marker size for the list and the elements. - - for (List_i i=BeginChildren(); i!=EndChildren(); ++i) - { - Track* track = (Track*)(*i); - if (track->GetMarkerSize() == fMarkerSize) - track->SetMarkerSize(size); - if (fRecurse) - SetMarkerSize(size, *i); - } - fMarkerSize=size; -} - -//______________________________________________________________________________ -void TrackList::SetMarkerSize(Size_t size, RenderElement* el) -{ - // Set marker size for children of el. - - Track* track; - for (List_i i=el->BeginChildren(); i!=el->EndChildren(); ++i) - { - track = dynamic_cast(*i); - if (track && track->GetMarkerSize() == fMarkerSize) - track->SetMarkerSize(size); - if (fRecurse) - SetMarkerSize(size, *i); - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void TrackList::SelectByPt(Float_t min_pt, Float_t max_pt) -{ - // Select visibility of tracks by transverse momentum. - // If data-member fRecurse is set, the selection is applied - // recursively to all children. - - fMinPt = min_pt; - fMaxPt = max_pt; - - const Float_t minptsq = min_pt*min_pt; - const Float_t maxptsq = max_pt*max_pt; - - for (List_i i=BeginChildren(); i!=EndChildren(); ++i) - { - const Float_t ptsq = ((Track*)(*i))->fP.Perp2(); - Bool_t on = ptsq >= minptsq && ptsq <= maxptsq; - (*i)->SetRnrState(on); - if (on && fRecurse) - SelectByPt(min_pt, max_pt, *i); - } -} - -//______________________________________________________________________________ -void TrackList::SelectByPt(Float_t min_pt, Float_t max_pt, RenderElement* el) -{ - // Select visibility of el's children tracks by transverse momentum. - - const Float_t minptsq = min_pt*min_pt; - const Float_t maxptsq = max_pt*max_pt; - - for (List_i i=el->BeginChildren(); i!=el->EndChildren(); ++i) - { - Track* track = dynamic_cast(*i); - if (track) - { - const Float_t ptsq = track->fP.Perp2(); - Bool_t on = ptsq >= minptsq && ptsq <= maxptsq; - track->SetRnrState(on); - if (on && fRecurse) - SelectByPt(min_pt, max_pt, *i); - } - } -} - -//______________________________________________________________________________ -void TrackList::SelectByP(Float_t min_p, Float_t max_p) -{ - // Select visibility of tracks by momentum. - // If data-member fRecurse is set, the selection is applied - // recursively to all children. - - fMinP = min_p; - fMaxP = max_p; - - const Float_t minpsq = min_p*min_p; - const Float_t maxpsq = max_p*max_p; - - for (List_i i=BeginChildren(); i!=EndChildren(); ++i) - { - const Float_t psq = ((Track*)(*i))->fP.Mag2(); - Bool_t on = psq >= minpsq && psq <= maxpsq; - (*i)->SetRnrState(psq >= minpsq && psq <= maxpsq); - if (on && fRecurse) - SelectByP(min_p, max_p, *i); - } -} - -//______________________________________________________________________________ -void TrackList::SelectByP(Float_t min_p, Float_t max_p, RenderElement* el) -{ - // Select visibility of el's children tracks by momentum. - - const Float_t minpsq = min_p*min_p; - const Float_t maxpsq = max_p*max_p; - - for (List_i i=el->BeginChildren(); i!=el->EndChildren(); ++i) - { - Track* track = dynamic_cast(*i); - if (track) - { - const Float_t psq = ((Track*)(*i))->fP.Mag2(); - Bool_t on = psq >= minpsq && psq <= maxpsq; - track->SetRnrState(on); - if (on && fRecurse) - SelectByP(min_p, max_p, *i); - } - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -Track* TrackList::FindTrackByLabel(Int_t label) -{ - // Find track by label, select it and display it in the editor. - - for (List_i i=fChildren.begin(); i!=fChildren.end(); ++i) { - if (((Track*)(*i))->GetLabel() == label) { - TGListTree *lt = gReve->GetLTEFrame()->GetListTree(); - TGListTreeItem *mlti = lt->GetSelected(); - if (mlti->GetUserData() != this) - mlti = FindListTreeItem(lt); - TGListTreeItem *tlti = (*i)->FindListTreeItem(lt, mlti); - lt->HighlightItem(tlti); - lt->SetSelected(tlti); - gReve->EditRenderElement(*i); - return (Track*) *i; - } - } - return 0; -} - -//______________________________________________________________________________ -Track* TrackList::FindTrackByIndex(Int_t index) -{ - // Find track by index, select it and display it in the editor. - - for (List_i i=fChildren.begin(); i!=fChildren.end(); ++i) { - if (((Track*)(*i))->GetIndex() == index) { - TGListTree *lt = gReve->GetLTEFrame()->GetListTree(); - TGListTreeItem *mlti = lt->GetSelected(); - if (mlti->GetUserData() != this) - mlti = FindListTreeItem(lt); - TGListTreeItem *tlti = (*i)->FindListTreeItem(lt, mlti); - lt->HighlightItem(tlti); - lt->SetSelected(tlti); - gReve->EditRenderElement(*i); - return (Track*) *i; - } - } - return 0; -} - -//______________________________________________________________________________ -void TrackList::ImportHits() -{ - // Import hits for all track. - - for (List_i i=fChildren.begin(); i!=fChildren.end(); ++i) { - ((Track*)(*i))->ImportHits(); - } -} - -//______________________________________________________________________________ -void TrackList::ImportClusters() -{ - // Import clusters for all track. - - for (List_i i=fChildren.begin(); i!=fChildren.end(); ++i) { - ((Track*)(*i))->ImportClusters(); - } -} - -/******************************************************************************/ - -//______________________________________________________________________________ -TClass* TrackList::ProjectedClass() const -{ - // Virtual from NLTProjectable, returns NLTTrackList class. - - return NLTTrackList::Class(); -} - - -/******************************************************************************/ -/******************************************************************************/ - -#include "RGEditor.h" - -//______________________________________________________________________________ -// TrackCounter -// -// Provides event-based method for tagging of good / bad (or primary / -// secondary) tracks. A report can be written into a text file. -// -// Track status is toggled by using secondary-selection / ctrl-click -// functionality of the GL viewer. -// -// Some of the functionality is implemented in TrackCounterEditor -// class. - -ClassImp(TrackCounter) - -TrackCounter* TrackCounter::fgInstance = 0; - -//______________________________________________________________________________ -TrackCounter::TrackCounter(const Text_t* name, const Text_t* title) : - RenderElement(), - TNamed(name, title), - - fBadLineStyle (6), - fClickAction (CA_ToggleTrack), - fAllTracks (0), - fGoodTracks (0), - fTrackLists () -{ - // Constructor. - // Connects to global signal "Reve::Track", "CtrlClicked(Reve::Track*)". - - if (fgInstance == 0) fgInstance = this; - TQObject::Connect("Reve::Track", "CtrlClicked(Reve::Track*)", - "Reve::TrackCounter", this, "DoTrackAction(Reve::Track*)"); -} - -//______________________________________________________________________________ -TrackCounter::~TrackCounter() -{ - // Destructor. - // Disconnect from the global track signals. - - TQObject::Disconnect("Reve::Track", "DoTrackAction(Reve::Track*)"); - if (fgInstance == this) fgInstance = 0; -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void TrackCounter::Reset() -{ - // Reset internal track-counters and track-list. - - printf("TrackCounter::Reset()\n"); - fAllTracks = 0; - fGoodTracks = 0; - TIter next(&fTrackLists); - TrackList* tlist; - while ((tlist = dynamic_cast(next()))) - tlist->DecDenyDestroy(); - fTrackLists.Clear("nodelete"); -} - -//______________________________________________________________________________ -void TrackCounter::RegisterTracks(TrackList* tlist, Bool_t goodTracks) -{ - // Register tracks from tlist and tlist itself. - // If goodTracks is true, they are considered as primary/good - // tracks. - - tlist->IncDenyDestroy(); - fTrackLists.Add(tlist); - - List_i i = tlist->BeginChildren(); - while (i != tlist->EndChildren()) - { - Track* t = dynamic_cast(*i); - if (t != 0) - { - if (goodTracks) - { - ++fGoodTracks; - } else { - t->SetLineStyle(fBadLineStyle); - } - ++fAllTracks; - } - ++i; - } -} - -//______________________________________________________________________________ -void TrackCounter::DoTrackAction(Track* track) -{ - // Slot called when track is ctrl-clicked. - // - // No check is done if track actually belongs to one of the - // registered track-lists. - // - // Probably it would be safer to copy good/bad tracks into special - // sub-containers. - // In this case one should also override RemoveElementLocal. - - switch (fClickAction) - { - - case CA_PrintTrackInfo: - { - printf("Track '%s'\n", track->GetObject()->GetName()); - Vector &v = track->fV, &p = track->fP; - printf(" Vx=%f, Vy=%f, Vz=%f; Pt=%f, Pz=%f, phi=%f)\n", - v.x, v.y, v.z, p.Perp(), p.z, TMath::RadToDeg()*p.Phi()); - printf(" \n"); - break; - } - - case CA_ToggleTrack: - { - if (track->GetLineStyle() == 1) - { - track->SetLineStyle(fBadLineStyle); - --fGoodTracks; - } else { - track->SetLineStyle(1); - ++fGoodTracks; - } - track->ElementChanged(); - gReve->Redraw3D(); - - printf("TrackCounter::CountTrack All=%d, Good=%d, Bad=%d\n", - fAllTracks, fGoodTracks, fAllTracks-fGoodTracks); - - if (gReve->GetEditor()->GetModel() == GetObject()) - gReve->EditRenderElement(this); - - break; - } - - } // end switch fClickAction -} - -/**************************************************************************/ - -//______________________________________________________________________________ -void TrackCounter::OutputEventTracks(FILE* out) -{ - // Print good-track summary into a plain-text file by iteration - // through all registered track-lists. - // State of each track is determined by its line-style, it is - // considered a good track if it's line style is solid. - - if (out == 0) - { - out = stdout; - fprintf(out, "TrackCounter::FinalizeEvent()\n"); - } - - fprintf(out, "Event = %d Ntracks = %d\n", fEventId, fGoodTracks); - - TIter tlists(&fTrackLists); - TrackList* tlist; - Int_t cnt = 0; - while ((tlist = (TrackList*) tlists()) != 0) - { - List_i i = tlist->BeginChildren(); - while (i != tlist->EndChildren()) - { - Track* t = dynamic_cast(*i); - if (t != 0 && t->GetLineStyle() == 1) - { - ++cnt; - fprintf(out, " %2d: chg=%+2d pt=%8.5f eta=%+8.5f\n", - cnt, t->fCharge, t->fP.Perp(), t->fP.Eta()); - } - ++i; - } - } -} diff --git a/EVE/Reve/Track.h b/EVE/Reve/Track.h deleted file mode 100644 index c3f76ef39d1..00000000000 --- a/EVE/Reve/Track.h +++ /dev/null @@ -1,311 +0,0 @@ -#ifndef REVE_Track_H -#define REVE_Track_H - -/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * - * See cxx source for full Copyright notice */ - -/* $Id$ */ - -#include - -#include -#include -#include - -#include -#include - -namespace Reve { - -class TrackRnrStyle; -class TrackList; - -class Track : public Line -{ - friend class TrackRnrStyle; - friend class TrackList; - friend class TrackCounter; - friend class TrackGL; - -public: - typedef std::vector vpPathMark_t; - typedef std::vector::iterator vpPathMark_i; - -protected: - Reve::Vector fV; // Starting vertex - Reve::Vector fP; // Starting momentum - Double_t fBeta; // Relativistic beta factor - Int_t fPdg; // PDG code - Int_t fCharge; // Charge in units of e0 - Int_t fLabel; // Simulation label - Int_t fIndex; // Reconstruction index - vpPathMark_t fPathMarks; // Vector of known points along the track - - TrackRnrStyle* fRnrStyle; // Pointer to shared render-style - -public: - Track(); - Track(TParticle* t, Int_t label, TrackRnrStyle* rs); - Track(Reve::MCTrack* t, TrackRnrStyle* rs); - Track(Reve::RecTrack* t, TrackRnrStyle* rs); - Track(const Track& t); - virtual ~Track(); - - virtual void SetStdTitle(); - - virtual void SetTrackParams(const Track& t); - virtual void SetPathMarks (const Track& t); - - virtual void MakeTrack(Bool_t recurse=kTRUE); - - TrackRnrStyle* GetRnrStyle() const { return fRnrStyle; } - void SetRnrStyle(TrackRnrStyle* rs); - void SetAttLineAttMarker(TrackList* tl); - - Int_t GetPdg() const { return fPdg; } - void SetPdg(Int_t pdg) { fPdg = pdg; } - Int_t GetCharge() const { return fCharge; } - void SetCharge(Int_t chg) { fCharge = chg; } - Int_t GetLabel() const { return fLabel; } - void SetLabel(Int_t lbl) { fLabel = lbl; } - Int_t GetIndex() const { return fIndex; } - void SetIndex(Int_t idx) { fIndex = idx; } - - void AddPathMark(Reve::PathMark* pm) { fPathMarks.push_back(pm); } - vpPathMark_t& GetPathMarksRef() { return fPathMarks; } - const vpPathMark_t& GetPathMarksRef() const { return fPathMarks; } - void SortPathMarksByTime(); - - //-------------------------------- - - void ImportHits(); // *MENU* - void ImportClusters(); // *MENU* - void ImportClustersFromIndex(); // *MENU* - void ImportKine(); // *MENU* - void ImportKineWithArgs(Bool_t importMother=kTRUE, Bool_t impDaugters=kTRUE, - Bool_t colorPdg =kTRUE, Bool_t recurse =kTRUE); // *MENU* - void PrintParticle(); // *MENU* - void PrintKineStack(); // *MENU* - void PrintPathMarks(); // *MENU* - - //-------------------------------- - - virtual void CtrlClicked(Reve::Track*); // *SIGNAL* - virtual void SetLineStyle(Style_t lstyle); - - virtual const TGPicture* GetListTreeIcon() { return fgListTreeIcons[4]; }; - - virtual TClass* ProjectedClass() const; - - ClassDef(Track, 1); // Visual representation of a track. -}; // endclass Track - - -/**************************************************************************/ -// TrackRnrStyle -/**************************************************************************/ - -class TrackRnrStyle : public TObject, - public ReferenceBackPtr -{ -private: - void RebuildTracks(); - -public: - Float_t fMagField; // Constant magnetic field along z. - - // Track limits - Float_t fMaxR; // Max radius for track extrapolation - Float_t fMaxZ; // Max z-coordinate for track extrapolation. - // Helix limits - Float_t fMaxOrbs; // Maximal angular path of tracks' orbits (1 ~ 2Pi). - Float_t fMinAng; // Minimal angular step between two helix points. - Float_t fDelta; // Maximal error at the mid-point of the line connecting to helix points. - - // Path-mark control - Bool_t fEditPathMarks; // Show widgets for path-mark control in GUI editor. - TMarker fPMAtt; // Marker attributes for rendering of path-marks. - - Bool_t fFitDaughters; // Pass through daughter creation points when extrapolating a track. - Bool_t fFitReferences; // Pass through given track-references when extrapolating a track. - Bool_t fFitDecay; // Pass through decay point when extrapolating a track. - - Bool_t fRnrDaughters; // Render daughter path-marks. - Bool_t fRnrReferences; // Render track-reference path-marks. - Bool_t fRnrDecay; // Render decay path-marks. - - // First vertex control - Bool_t fRnrFV; // Render first vertex. - TMarker fFVAtt; // Marker attributes for fits vertex. - - TrackRnrStyle(); - - // callbacks - void SetEditPathMarks(Bool_t x) { fEditPathMarks = x; } - void SetRnrDaughters(Bool_t x); - void SetRnrReferences(Bool_t x); - void SetRnrDecay(Bool_t x); - - void SetRnrFV(Bool_t x){ fRnrFV = x;} - - void SetFitDaughters(Bool_t x); - void SetFitReferences(Bool_t x); - void SetFitDecay(Bool_t x); - - void SetMaxR(Float_t x); - void SetMaxZ(Float_t x); - void SetMaxOrbs(Float_t x); - void SetMinAng(Float_t x); - void SetDelta(Float_t x); - - Float_t GetMagField() const { return fMagField; } - void SetMagField(Float_t mf) { fMagField = mf; } - - static Float_t fgDefMagField; // Default value for constant solenoid magnetic field. - static const Float_t fgkB2C; // Constant for conversion of momentum to curvature. - static TrackRnrStyle fgDefStyle; // Default track render-style. - - ClassDef(TrackRnrStyle, 1); // Rendering parameters for tracks. -}; // endclass TrackRnrStyle - - -/**************************************************************************/ -// TrackList -/**************************************************************************/ - -class TrackList : public RenderElementList, - public NLTProjectable, - public TAttMarker, - public TAttLine -{ - friend class TrackListEditor; - -private: - TrackList(const TrackList&); // Not implemented - TrackList& operator=(const TrackList&); // Not implemented - - Bool_t fRecurse; // Recurse when propagating marker/line attributes to tracks. - -protected: - TrackRnrStyle* fRnrStyle; // Basic track rendering parameters, not enforced to elements. - - Bool_t fRnrLine; // Render track as line. - Bool_t fRnrPoints; // Render track as points. - - Float_t fMinPt; // Minimum track pT for display selection. - Float_t fMaxPt; // Maximum track pT for display selection. - Float_t fLimPt; // Highest track pT in the container. - Float_t fMinP; // Minimum track p for display selection. - Float_t fMaxP; // Maximum track p for display selection. - Float_t fLimP; // Highest track p in the container. - - Float_t RoundMomentumLimit(Float_t x); - -public: - TrackList(TrackRnrStyle* rs=0); - TrackList(const Text_t* name, TrackRnrStyle* rs=0); - virtual ~TrackList(); - - void MakeTracks(Bool_t recurse=kTRUE); - void FindMomentumLimits(RenderElement* el, Bool_t recurse); - - void SetRnrStyle(TrackRnrStyle* rs); - TrackRnrStyle* GetRnrStyle(){return fRnrStyle;} - - //-------------------------------- - - virtual void SetMainColor(Color_t c); - virtual void SetLineColor(Color_t c){SetMainColor(c);} - virtual void SetLineColor(Color_t c, RenderElement* el); - virtual void SetLineWidth(Width_t w); - virtual void SetLineWidth(Width_t w, RenderElement* el); - virtual void SetLineStyle(Style_t s); - virtual void SetLineStyle(Style_t s, RenderElement* el); - - virtual void SetMarkerColor(Color_t c); - virtual void SetMarkerColor(Color_t c, RenderElement* el); - virtual void SetMarkerSize(Size_t s); - virtual void SetMarkerSize(Size_t s, RenderElement* el); - virtual void SetMarkerStyle(Style_t s); - virtual void SetMarkerStyle(Style_t s, RenderElement* el); - - void SetRnrLine(Bool_t rnr); - void SetRnrLine(Bool_t rnr, RenderElement* el); - Bool_t GetRnrLine(){return fRnrLine;} - - void SetRnrPoints(Bool_t r); - void SetRnrPoints(Bool_t r, RenderElement* el); - Bool_t GetRnrPoints(){return fRnrPoints;} - - void SelectByPt(Float_t min_pt, Float_t max_pt); - void SelectByPt(Float_t min_pt, Float_t max_pt, RenderElement* el); - void SelectByP (Float_t min_p, Float_t max_p); - void SelectByP (Float_t min_p, Float_t max_p, RenderElement* el); - - //-------------------------------- - - Track* FindTrackByLabel(Int_t label); // *MENU* - Track* FindTrackByIndex(Int_t index); // *MENU* - - void ImportHits(); // *MENU* - void ImportClusters(); // *MENU* - - virtual TClass* ProjectedClass() const; - - ClassDef(TrackList, 1); // A list of tracks. -}; - - -/**************************************************************************/ -// TrackCounter -/**************************************************************************/ - -class TrackCounter : public RenderElement, public TNamed -{ - friend class TrackCounterEditor; - -public: - enum ClickAction_e { CA_PrintTrackInfo, CA_ToggleTrack }; - -private: - TrackCounter(const TrackCounter&); // Not implemented - TrackCounter& operator=(const TrackCounter&); // Not implemented - -protected: - Int_t fBadLineStyle; // Line-style used for secondary/bad tracks. - Int_t fClickAction; // Action to take when a track is ctrl-clicked. - - Int_t fEventId; // Current event-id. - - Int_t fAllTracks; // Counter of all tracks. - Int_t fGoodTracks; // Counter of good tracks. - - TList fTrackLists; // List of TrackLists registered for management. - -public: - TrackCounter(const Text_t* name="TrackCounter", const Text_t* title=""); - virtual ~TrackCounter(); - - Int_t GetEventId() const { return fEventId; } - void SetEventId(Int_t id) { fEventId = id; } - - void Reset(); - - void RegisterTracks(TrackList* tlist, Bool_t goodTracks); - - void DoTrackAction(Track* track); - - Int_t GetClickAction() const { return fClickAction; } - void SetClickAction(Int_t a) { fClickAction = a; } - - void OutputEventTracks(FILE* out=0); - - static TrackCounter* fgInstance; - - ClassDef(TrackCounter, 1); -}; // endclass TrackCounter - - -} // namespace Reve - -#endif diff --git a/EVE/Reve/TrackEditors.cxx b/EVE/Reve/TrackEditors.cxx deleted file mode 100644 index e73bbc8747f..00000000000 --- a/EVE/Reve/TrackEditors.cxx +++ /dev/null @@ -1,478 +0,0 @@ -// $Header$ - -#include "TrackEditors.h" -#include -#include -#include - -#include - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include - -#include // File input/output for track-count status. - -using namespace Reve; - - -//______________________________________________________________________ -// TrackEditor -// - -ClassImp(TrackEditor) - -TrackEditor::TrackEditor(const TGWindow *p, Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - fM (0), - fRSEditor(0) -{ - MakeTitle("Track"); - - TGHorizontalFrame* f = new TGHorizontalFrame(this); - - fRSEditor = new TGTextButton(f, "Edit RnrStyle"); - fRSEditor->Connect("Clicked()", "Reve::TrackEditor", this, "DoEditRnrStyle()"); - f->AddFrame(fRSEditor, new TGLayoutHints(kLHintsLeft, 2, 1, 4, 4)); - - AddFrame(f, new TGLayoutHints(kLHintsTop, 0,0,2,1)); -} - -void TrackEditor::SetModel(TObject* obj) -{ - fM = dynamic_cast(obj); -} - -void TrackEditor::DoEditRnrStyle() -{ - fGedEditor->SetModel(fGedEditor->GetPad(), fM->GetRnrStyle(), kButton1Down); -} - - -//______________________________________________________________________ -// TrackListEditor -// - -ClassImp(TrackListEditor) - -TrackListEditor::TrackListEditor(const TGWindow *p, - Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - - fTC (0), - fPtRange (0), - fPRange (0), - fRSSubEditor(0) -{ - { - TGHorizontalFrame* f = new TGHorizontalFrame(this); - - fRnrPoints = new TGCheckButton(f, "Draw Marker"); - f->AddFrame(fRnrPoints, new TGLayoutHints(kLHintsLeft, 2,1,0,0)); - fRnrPoints->Connect("Toggled(Bool_t)"," Reve::TrackListEditor", this, "DoRnrPoints()"); - - fRnrLine = new TGCheckButton(f, "Draw Line"); - f->AddFrame(fRnrLine, new TGLayoutHints(kLHintsLeft, 1,2,0,0)); - fRnrLine->Connect("Toggled(Bool_t)", "Reve::TrackListEditor", this, "DoRnrLine()"); - - AddFrame(f, new TGLayoutHints(kLHintsTop, 0,0,2,1)); - } - { // --- Selectors - Int_t labelW = 51; - Int_t dbW = 210; - - fPtRange = new RGDoubleValuator(this,"Pt rng:", 40, 0); - fPtRange->SetNELength(6); - fPtRange->SetLabelWidth(labelW); - fPtRange->Build(); - fPtRange->GetSlider()->SetWidth(dbW); - fPtRange->SetLimits(0, 10, TGNumberFormat::kNESRealTwo); - fPtRange->Connect("ValueSet()", - "Reve::TrackListEditor", this, "DoPtRange()"); - AddFrame(fPtRange, new TGLayoutHints(kLHintsTop, 1, 1, 4, 1)); - - fPRange = new RGDoubleValuator(this,"P rng:", 40, 0); - fPRange->SetNELength(6); - fPRange->SetLabelWidth(labelW); - fPRange->Build(); - fPRange->GetSlider()->SetWidth(dbW); - fPRange->SetLimits(0, 100, TGNumberFormat::kNESRealTwo); - fPRange->Connect("ValueSet()", - "Reve::TrackListEditor", this, "DoPRange()"); - AddFrame(fPRange, new TGLayoutHints(kLHintsTop, 1, 1, 4, 1)); - } - - MakeTitle("RenderStyle"); - fRSSubEditor = new TrackRnrStyleSubEditor(this); - fRSSubEditor->Connect("Changed()", "Reve::TrackListEditor", this, "Update()"); - AddFrame(fRSSubEditor, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 2, 0,0,0)); - CreateRefsTab(); -} - -TrackListEditor::~TrackListEditor() -{} - -/**************************************************************************/ - -void TrackListEditor::CreateRefsTab() -{ - fRefs = CreateEditorTabSubFrame("Refs"); - - TGCompositeFrame *title1 = new TGCompositeFrame(fRefs, 145, 10, - kHorizontalFrame | - kLHintsExpandX | - kFixedWidth | - kOwnBackground); - title1->AddFrame(new TGLabel(title1, "PathMarks"), - new TGLayoutHints(kLHintsLeft, 1, 1, 0, 0)); - title1->AddFrame(new TGHorizontal3DLine(title1), - new TGLayoutHints(kLHintsExpandX, 5, 5, 7, 7)); - fRefs->AddFrame(title1, new TGLayoutHints(kLHintsTop, 0, 0, 2, 0)); - - // path marks - fRSSubEditor->CreateRefsContainer(fRefs); - fRSSubEditor->fPMAtt->SetGedEditor((TGedEditor*)gReve->GetEditor()); - fRSSubEditor->fFVAtt->SetGedEditor((TGedEditor*)gReve->GetEditor()); -} - -/**************************************************************************/ - -void TrackListEditor::SetModel(TObject* obj) -{ - fTC = dynamic_cast(obj); - fRnrLine ->SetState(fTC->GetRnrLine() ? kButtonDown : kButtonUp); - fRnrPoints->SetState(fTC->GetRnrPoints() ? kButtonDown : kButtonUp); - - Float_t llim; - fPtRange->SetValues(fTC->fMinPt, fTC->fMaxPt); - llim = TMath::Log10(fTC->fLimPt); - fPtRange->SetLimits(0, fTC->fLimPt, llim < 2 ? TGNumberFormat::kNESRealTwo : (llim < 3 ? TGNumberFormat::kNESRealOne : TGNumberFormat::kNESInteger)); - fPRange ->SetValues(fTC->fMinP, fTC->fMaxP); - llim = TMath::Log10(fTC->fLimP); - fPRange ->SetLimits(0, fTC->fLimP, llim < 2 ? TGNumberFormat::kNESRealTwo : (llim < 3 ? TGNumberFormat::kNESRealOne : TGNumberFormat::kNESInteger)); - - fRSSubEditor->SetModel(fTC->GetRnrStyle()); -} - -/**************************************************************************/ - -void TrackListEditor::DoRnrLine() -{ - fTC->SetRnrLine(fRnrLine->IsOn()); - Update(); -} - -void TrackListEditor::DoRnrPoints() -{ - fTC->SetRnrPoints(fRnrPoints->IsOn()); - Update(); -} - -/**************************************************************************/ - -void TrackListEditor::DoPtRange() -{ - fTC->SelectByPt(fPtRange->GetMin(), fPtRange->GetMax()); - Update(); -} - -void TrackListEditor::DoPRange() -{ - fTC->SelectByP(fPRange->GetMin(), fPRange->GetMax()); - Update(); -} - - -/**************************************************************************/ -/**************************************************************************/ -/**************************************************************************/ - -#include -#include -#include - -//______________________________________________________________________ -// TrackCounterEditor -// - -ClassImp(TrackCounterEditor) - -TrackCounterEditor::TrackCounterEditor(const TGWindow *p, Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - fM(0), - fClickAction (0), - fInfoLabel (0), - fEventId (0) -{ - MakeTitle("TrackCounter"); - - Int_t labelW = 42; - - { // ClickAction - TGHorizontalFrame* f = new TGHorizontalFrame(this); - TGLabel* lab = new TGLabel(f, "Click:"); - f->AddFrame(lab, new TGLayoutHints(kLHintsLeft|kLHintsBottom, 1, 10, 1, 2)); - fClickAction = new TGComboBox(f); - fClickAction->AddEntry("Print", 0); - fClickAction->AddEntry("Toggle", 1); - TGListBox* lb = fClickAction->GetListBox(); - lb->Resize(lb->GetWidth(), 2*16); - fClickAction->Resize(70, 20); - fClickAction->Connect("Selected(Int_t)", "Reve::TrackCounterEditor", this, - "DoClickAction(Int_t)"); - f->AddFrame(fClickAction, new TGLayoutHints(kLHintsLeft, 1, 2, 1, 1)); - - AddFrame(f); - } - - { // Status - TGHorizontalFrame* f = new TGHorizontalFrame(this); - TGLabel* lab = new TGLabel(f, "Status:"); - f->AddFrame(lab, new TGLayoutHints(kLHintsLeft, 1, 5, 1, 2)); - - fInfoLabel = new TGLabel(f); - f->AddFrame(fInfoLabel, new TGLayoutHints(kLHintsLeft|kLHintsExpandX, 1, 9, 1, 2)); - - AddFrame(f); - } - - { - TGHorizontalFrame* f = new TGHorizontalFrame(this, 210, 20, kFixedWidth); - - TGHorizontalFrame* g = new TGHorizontalFrame(f, labelW, 0, kFixedWidth); - TGLabel* l = new TGLabel(g, "View:"); - g->AddFrame(l, new TGLayoutHints(kLHintsLeft, 0,0,4,0)); - f->AddFrame(g); - - TGTextButton* b; - - b = new TGTextButton(f, "Orto XY"); - f->AddFrame(b, new TGLayoutHints(kLHintsLeft|kLHintsExpandX, 1, 1, 0, 0)); - b->Connect("Clicked()", "Reve::TrackCounterEditor", this, "DoOrtoXY()"); - - b = new TGTextButton(f, "Orto ZY"); - f->AddFrame(b, new TGLayoutHints(kLHintsLeft|kLHintsExpandX, 1, 1, 0, 0)); - b->Connect("Clicked()", "Reve::TrackCounterEditor", this, "DoOrtoZY()"); - - b = new TGTextButton(f, "Persp"); - f->AddFrame(b, new TGLayoutHints(kLHintsLeft|kLHintsExpandX, 1, 1, 0, 0)); - b->Connect("Clicked()", "Reve::TrackCounterEditor", this, "DoPersp()"); - - AddFrame(f); - } - - { - TGHorizontalFrame* f = new TGHorizontalFrame(this, 210, 20, kFixedWidth); - - TGHorizontalFrame* g = new TGHorizontalFrame(f, labelW, 0, kFixedWidth); - TGLabel* l = new TGLabel(g, "Event:"); - g->AddFrame(l, new TGLayoutHints(kLHintsLeft, 0,0,4,0)); - f->AddFrame(g); - - TGTextButton* b; - - b = new TGTextButton(f, "Prev"); - f->AddFrame(b, new TGLayoutHints(kLHintsLeft|kLHintsExpandX, 1, 1, 0, 0)); - b->Connect("Clicked()", "Reve::TrackCounterEditor", this, "DoPrev()"); - - fEventId = new TGNumberEntry(f, 0, 3, -1,TGNumberFormat::kNESInteger, TGNumberFormat::kNEANonNegative, - TGNumberFormat::kNELLimitMinMax, 0, 1000); - f->AddFrame(fEventId, new TGLayoutHints(kLHintsLeft|kLHintsExpandX, 1, 1, 0, 0)); - fEventId->Connect("ValueSet(Long_t)", "Reve::TrackCounterEditor", this, "DoSetEvent()"); - - b = new TGTextButton(f, "Next"); - f->AddFrame(b, new TGLayoutHints(kLHintsLeft|kLHintsExpandX, 1, 1, 0, 0)); - b->Connect("Clicked()", "Reve::TrackCounterEditor", this, "DoNext()"); - - AddFrame(f); - } - - { - TGHorizontalFrame* f = new TGHorizontalFrame(this, 210, 20, kFixedWidth); - - TGHorizontalFrame* g = new TGHorizontalFrame(f, labelW, 0, kFixedWidth); - TGLabel* l = new TGLabel(g, "Report:"); - g->AddFrame(l, new TGLayoutHints(kLHintsLeft, 0,0,4,0)); - f->AddFrame(g); - - TGTextButton* b; - - b = new TGTextButton(f, "Print"); - f->AddFrame(b, new TGLayoutHints(kLHintsLeft|kLHintsExpandX, 1, 1, 0, 0)); - b->Connect("Clicked()", "Reve::TrackCounterEditor", this, "DoPrintReport()"); - - b = new TGTextButton(f, "File"); - f->AddFrame(b, new TGLayoutHints(kLHintsLeft|kLHintsExpandX, 1, 1, 0, 0)); - b->Connect("Clicked()", "Reve::TrackCounterEditor", this, "DoFileReport()"); - - AddFrame(f, new TGLayoutHints(kLHintsLeft, 0, 0, 4, 0)); - } - { - TGHorizontalFrame* f = new TGHorizontalFrame(this, 210, 20, kFixedWidth); - - TGHorizontalFrame* g = new TGHorizontalFrame(f, labelW, 0, kFixedWidth); - TGLabel* l = new TGLabel(g, "Histos:"); - g->AddFrame(l, new TGLayoutHints(kLHintsLeft, 0,0,4,0)); - f->AddFrame(g); - - TGTextButton* b; - - b = new TGTextButton(f, "Show"); - f->AddFrame(b, new TGLayoutHints(kLHintsLeft|kLHintsExpandX, 1, 1, 0, 0)); - b->Connect("Clicked()", "Reve::TrackCounterEditor", this, "DoShowHistos()"); - - AddFrame(f, new TGLayoutHints(kLHintsLeft, 0, 0, 0, 0)); - } - -} - -TrackCounterEditor::~TrackCounterEditor() -{} - -/**************************************************************************/ - -void TrackCounterEditor::SetModel(TObject* obj) -{ - fM = dynamic_cast(obj); - - fClickAction->Select(fM->fClickAction, kFALSE); - fInfoLabel->SetText(Form("All: %3d; Primaries: %3d", fM->fAllTracks, fM->fGoodTracks)); - fEventId->SetNumber(fM->GetEventId()); -} - -/**************************************************************************/ - -void TrackCounterEditor::DoOrtoXY() -{ - gReve->GetGLViewer()->SetCurrentCamera(TGLViewer::kCameraOrthoXOY) ; -} - -void TrackCounterEditor::DoOrtoZY() -{ - gReve->GetGLViewer()->SetCurrentCamera(TGLViewer::kCameraOrthoZOY) ; -} - -void TrackCounterEditor::DoPersp() -{ - gReve->GetGLViewer()->SetCurrentCamera(TGLViewer::kCameraPerspXOZ) ; -} - -/**************************************************************************/ - -void TrackCounterEditor::DoPrev() -{ - Reve::Macro("event_prev.C"); - gReve->EditRenderElement(fM); -} - -void TrackCounterEditor::DoNext() -{ - Reve::Macro("event_next.C"); - gReve->EditRenderElement(fM); -} - -void TrackCounterEditor::DoSetEvent() -{ - Reve::LoadMacro("event_goto.C"); - gROOT->ProcessLine(Form("event_goto(%d);", (Int_t) fEventId->GetNumber())); - gReve->EditRenderElement(fM); -} - -/**************************************************************************/ - -void TrackCounterEditor::DoPrintReport() -{ - fM->OutputEventTracks(); -} - -void TrackCounterEditor::DoFileReport() -{ - TString file(Form("ev-report-%03d.txt", fM->GetEventId())); - if (gSystem->AccessPathName(file) == kFALSE) - { - Int_t ret; - new TGMsgBox(fClient->GetRoot(), GetMainFrame(), - "File Exist", - Form("Event record for event %d already exist.\n Replace?", fM->GetEventId()), - kMBIconQuestion, kMBYes | kMBNo, &ret); - if (ret == kMBNo) - return; - } - FILE* out = fopen(file, "w"); - fM->OutputEventTracks(out); - fclose(out); -} - -void TrackCounterEditor::DoShowHistos() -{ - TH1F* hcnt = new TH1F("cnt", "Primeries per event", 41, -0.5, 40.5); - TH1F* hchg = new TH1F("chg", "Primary charge", 3, -1.5, 1.5); - TH1F* hpt = new TH1F("pt", "pT distribution", 40, 0.0, 8.0); - TH1F* heta = new TH1F("eta", "eta distribution", 40, -1.0, 1.0); - - Int_t nn; // fscanf return value - - for (Int_t i=0; i<1000; ++i) - { - TString file(Form("ev-report-%03d.txt", i)); - if (gSystem->AccessPathName(file) == kFALSE) - { - Int_t ev, ntr; - FILE* f = fopen(file, "read"); - nn = fscanf(f, "Event = %d Ntracks = %d", &ev, &ntr); - if (nn != 2) { printf("SAFR1 %d\n", nn); fclose(f); return; } - hcnt->Fill(ntr); - for (Int_t t=0; tFill(chg); - hpt ->Fill(pt); - heta->Fill(eta); - } - fclose(f); - } - } - - TCanvas* c; - if (gPad == 0 || gPad->GetCanvas()->IsEditable() == kFALSE) { - c = new TCanvas("Scanwas", "Scanning Results", 800, 600); - } else { - c = gPad->GetCanvas(); - c->Clear(); - } - c->Divide(2, 2); - - c->cd(1); hcnt->Draw(); - c->cd(2); hchg->Draw(); - c->cd(3); hpt ->Draw(); - c->cd(4); heta->Draw(); - - c->Modified(); - c->Update(); -} - - -/**************************************************************************/ - -void TrackCounterEditor::DoClickAction(Int_t mode) -{ - fM->SetClickAction(mode); -} diff --git a/EVE/Reve/TrackEditors.h b/EVE/Reve/TrackEditors.h deleted file mode 100644 index 0c8cea14f22..00000000000 --- a/EVE/Reve/TrackEditors.h +++ /dev/null @@ -1,134 +0,0 @@ -// $Header$ - -#ifndef REVE_TrackEditors_H -#define REVE_TrackEditors_H - -#include - -class TGButton; -class TGCheckButton; -class TGNumberEntry; -class TGColorSelect; -class TGComboBox; - -namespace Reve { - -class RGValuator; -class RGDoubleValuator; -class TrackRnrStyleSubEditor; -class Track; -class TrackList; - -/**************************************************************************/ -// TrackEditor -/**************************************************************************/ -class TrackEditor : public TGedFrame -{ -private: - TrackEditor(const TrackEditor&); // Not implemented - TrackEditor& operator=(const TrackEditor&); // Not implemented - -protected: - Track *fM; - TGTextButton *fRSEditor; -public: - TrackEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, - UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - ~TrackEditor(){} - - virtual void SetModel(TObject* obj); - void DoEditRnrStyle(); - - ClassDef(TrackEditor, 1); // Editor for Track -}; // endclass TrackEditor - -/**************************************************************************/ -// TrackListEditor -/**************************************************************************/ - -class TrackListEditor : public TGedFrame -{ -private: - TrackListEditor(const TrackListEditor&); // Not implemented - TrackListEditor& operator=(const TrackListEditor&); // Not implemented - - void CreateRefTab(); -protected: - TGVerticalFrame *fRefs; - - TrackList *fTC; // fModel dynamic-casted to TrackListEditor - - TGCheckButton *fRnrLine; - TGCheckButton *fRnrPoints; - - RGDoubleValuator *fPtRange; - RGDoubleValuator *fPRange; - - TrackRnrStyleSubEditor *fRSSubEditor; - -public: - TrackListEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, - UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - ~TrackListEditor(); - - void CreateRefsTab(); - virtual void SetModel(TObject* obj); - - void DoRnrLine(); - void DoRnrPoints(); - - void DoPtRange(); - void DoPRange(); - - ClassDef(TrackListEditor, 1); // Editor for TrackList -}; // endclass TrackListEditor - - - -/**************************************************************************/ -// -/**************************************************************************/ - -class TrackCounter; - -class TrackCounterEditor : public TGedFrame -{ -private: - TrackCounterEditor(const TrackCounterEditor&); // Not implemented - TrackCounterEditor& operator=(const TrackCounterEditor&); // Not implemented - -protected: - TrackCounter* fM; // fModel dynamic-casted to TrackCounter - - // Declare widgets - TGComboBox* fClickAction; - TGLabel* fInfoLabel; - TGNumberEntry* fEventId; - -public: - TrackCounterEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, - UInt_t options = kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - virtual ~TrackCounterEditor(); - - virtual void SetModel(TObject* obj); - - void DoOrtoXY(); - void DoOrtoZY(); - void DoPersp(); - - void DoPrev(); - void DoNext(); - void DoSetEvent(); - - void DoPrintReport(); - void DoFileReport(); - void DoShowHistos(); - - void DoClickAction(Int_t); - - ClassDef(TrackCounterEditor, 1); // Editor for TrackCounter -}; // endclass TrackCounterEditor - -} - -#endif diff --git a/EVE/Reve/TrackGL.cxx b/EVE/Reve/TrackGL.cxx deleted file mode 100644 index c7607d9aaba..00000000000 --- a/EVE/Reve/TrackGL.cxx +++ /dev/null @@ -1,101 +0,0 @@ -// $Header$ - -#include "TrackGL.h" -#include -#include - -#include - -#include - -using namespace Reve; - -//______________________________________________________________________ -// TrackGL -// - -ClassImp(TrackGL) - -TrackGL::TrackGL() : LineGL() -{ - // fDLCache = false; // Disable display list. -} - -TrackGL::~TrackGL() -{} - -/**************************************************************************/ - -Bool_t TrackGL::SetModel(TObject* obj, const Option_t* /*opt*/) -{ - if(LineGL::SetModel(obj) == kFALSE) return kFALSE; - if(SetModelCheckClass(obj, Track::Class())) { - fTrack = dynamic_cast(obj); - return kTRUE; - } - return kFALSE; -} -/**************************************************************************/ - -void TrackGL::ProcessSelection(TGLRnrCtx & /*rnrCtx*/, TGLSelectRecord & rec) -{ - // Processes secondary selection from TGLViewer. - // Calls TPointSet3D::PointSelected(Int_t) with index of selected - // point as an argument. - - printf("TrackGL::ProcessSelection %d names on the stack (z1=%g, z2=%g).\n", - rec.GetN(), rec.GetMinZ(), rec.GetMaxZ()); - printf(" Names: "); - for (Int_t j=0; jCtrlClicked((Track*)fM); -} - -/**************************************************************************/ -void TrackGL::DirectDraw(TGLRnrCtx & rnrCtx) const -{ - LineGL::DirectDraw(rnrCtx); - - // path-marks - std::vector& pm = fTrack->fPathMarks; - TrackRnrStyle& RS = *fTrack->GetRnrStyle(); - if(pm.size()) - { - Float_t* pnts = new Float_t[3*pm.size()]; // maximum - Int_t N = 0; - Bool_t accept; - for(std::vector::iterator i=pm.begin(); i!=pm.end(); ++i) - { - accept = kFALSE; - switch((*i)->type) - { - case(PathMark::Daughter): - if(RS.fRnrDaughters) accept = kTRUE; - break; - case(PathMark::Reference): - if(RS.fRnrReferences) accept = kTRUE; - break; - case(PathMark::Decay): - if(RS.fRnrDecay) accept = kTRUE; - break; - } - if(accept) - { - if((TMath::Abs((*i)->V.z) < RS.fMaxZ) && ((*i)->V.Perp() < RS.fMaxR)) - { - pnts[3*N ] =(*i)->V.x; - pnts[3*N+1] =(*i)->V.y; - pnts[3*N+2] =(*i)->V.z; - N++; - } - } - } - GLUtilNS::RenderPolyMarkers(RS.fPMAtt, pnts, N); - delete [] pnts; - } - - // fist vertex - if(RS.fRnrFV && fTrack->GetLastPoint()) - GLUtilNS::RenderPolyMarkers(RS.fFVAtt, fTrack->GetP(), 1); -} diff --git a/EVE/Reve/TrackGL.h b/EVE/Reve/TrackGL.h deleted file mode 100644 index 84d84d879b4..00000000000 --- a/EVE/Reve/TrackGL.h +++ /dev/null @@ -1,41 +0,0 @@ -// $Header$ - -#ifndef REVE_TrackGL_H -#define REVE_TrackGL_H - -#include - -class TGLViewer; -class TGLScene; - -namespace Reve { - -class Track; - -class TrackGL : public LineGL -{ -private: - TrackGL(const TrackGL&); // Not implemented - TrackGL& operator=(const TrackGL&); // Not implemented - -protected: - Track* fTrack; // fModel dynamic-casted to LineGL - - virtual void DirectDraw(TGLRnrCtx & rnrCtx) const; - -public: - TrackGL(); - virtual ~TrackGL(); - - virtual Bool_t SetModel(TObject* obj, const Option_t* opt=0); - - // To support two-level selection - virtual Bool_t SupportsSecondarySelect() const { return kTRUE; } - virtual void ProcessSelection(TGLRnrCtx & rnrCtx, TGLSelectRecord & rec); - - ClassDef(TrackGL, 0); -}; // endclass TrackGL - -} - -#endif diff --git a/EVE/Reve/TrackRnrStyleEditor.cxx b/EVE/Reve/TrackRnrStyleEditor.cxx deleted file mode 100644 index 8e96af02586..00000000000 --- a/EVE/Reve/TrackRnrStyleEditor.cxx +++ /dev/null @@ -1,381 +0,0 @@ -// $Header$ - -#include "TrackRnrStyleEditor.h" -#include - -#include -#include - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// TrackRnrStyleSubEditor -// -// - -ClassImp(TrackRnrStyleSubEditor) - -TrackRnrStyleSubEditor::TrackRnrStyleSubEditor(const TGWindow *p): - TGVerticalFrame(p), - fM (0), - - fMaxR(0), - fMaxZ(0), - fMaxOrbits(0), - fMinAng(0), - fDelta(0), - - fRnrFV(0), - - fPMFrame(0), - fFitDaughters(0), - fFitReferences(0), - fFitDecay(0), - fRnrDaughters(0), - fRnrReferences(0), - fRnrDecay(0), - - fRefsCont(0), - fPMAtt(0), - fFVAtt(0) -{ - Int_t labelW = 51; - - // --- Limits - fMaxR = new RGValuator(this, "Max R:", 90, 0); - fMaxR->SetLabelWidth(labelW); - fMaxR->SetNELength(6); - fMaxR->Build(); - fMaxR->SetLimits(0.1, 1000, 101, TGNumberFormat::kNESRealOne); - fMaxR->SetToolTip("Maximum radius to which the tracks will be drawn."); - fMaxR->Connect("ValueSet(Double_t)", "Reve::TrackRnrStyleSubEditor", this, "DoMaxR()"); - AddFrame(fMaxR, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - - fMaxZ = new RGValuator(this, "Max Z:", 90, 0); - fMaxZ->SetLabelWidth(labelW); - fMaxZ->SetNELength(6); - fMaxZ->Build(); - fMaxZ->SetLimits(0.1, 2000, 101, TGNumberFormat::kNESRealOne); - fMaxZ->SetToolTip("Maximum z-coordinate to which the tracks will be drawn."); - fMaxZ->Connect("ValueSet(Double_t)", "Reve::TrackRnrStyleSubEditor", this, "DoMaxZ()"); - AddFrame(fMaxZ, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - - fMaxOrbits = new RGValuator(this, "Orbits:", 90, 0); - fMaxOrbits->SetLabelWidth(labelW); - fMaxOrbits->SetNELength(6); - fMaxOrbits->Build(); - fMaxOrbits->SetLimits(0.1, 10, 101, TGNumberFormat::kNESRealOne); - fMaxOrbits->SetToolTip("Maximal angular path of tracks' orbits (1 ~ 2Pi)."); - fMaxOrbits->Connect("ValueSet(Double_t)", "Reve::TrackRnrStyleSubEditor", this, "DoMaxOrbits()"); - AddFrame(fMaxOrbits, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - - fMinAng = new RGValuator(this, "Angle:", 90, 0); - fMinAng->SetLabelWidth(labelW); - fMinAng->SetNELength(6); - fMinAng->Build(); - fMinAng->SetLimits(1, 160, 81, TGNumberFormat::kNESRealOne); - fMinAng->SetToolTip("Minimal angular step between two helix points."); - fMinAng->Connect("ValueSet(Double_t)", "Reve::TrackRnrStyleSubEditor", this, "DoMinAng()"); - AddFrame(fMinAng, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - - fDelta = new RGValuator(this, "Delta:", 90, 0); - fDelta->SetLabelWidth(labelW); - fDelta->SetNELength(6); - fDelta->Build(); - fDelta->SetLimits(0.001, 10, 101, TGNumberFormat::kNESRealThree); - fDelta->SetToolTip("Maximal error at the mid-point of the line connecting to helix points."); - fDelta->Connect("ValueSet(Double_t)", "Reve::TrackRnrStyleSubEditor", this, "DoDelta()"); - AddFrame(fDelta, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); -} - -//______________________________________________________________________________ -void TrackRnrStyleSubEditor::CreateRefsContainer(TGVerticalFrame* p) -{ - // Create a frame containing track-reference controls under parent - // frame p. - - fRefsCont = new TGCompositeFrame(p, 80, 20, kVerticalFrame); - fPMFrame = new TGVerticalFrame(fRefsCont); - // Rendering control. - { - TGGroupFrame* fitPM = new TGGroupFrame(fPMFrame, "PathMarks:", kLHintsTop | kLHintsCenterX); - fitPM->SetTitlePos(TGGroupFrame::kLeft); - fPMFrame->AddFrame( fitPM, new TGLayoutHints(kLHintsTop | kLHintsCenterX | kLHintsExpandX, 3, 3, 3, 3)); - - TGMatrixLayout *ml = new TGMatrixLayout(fitPM, 0,1,6); - fitPM->SetLayoutManager(ml); - - fFitDaughters = new TGCheckButton(fitPM, "Fit Daughters", PathMark::Daughter); - fFitReferences = new TGCheckButton(fitPM, "Fit Refs", PathMark::Reference); - fFitDecay = new TGCheckButton(fitPM, "Fit Decay", PathMark::Decay); - - fitPM->AddFrame(fFitDaughters); - fitPM->AddFrame(fFitReferences); - fitPM->AddFrame(fFitDecay); - - fFitDecay->Connect("Clicked()","Reve::TrackRnrStyleSubEditor", this, "DoFitPM()"); - fFitReferences->Connect("Clicked()","Reve::TrackRnrStyleSubEditor", this, "DoFitPM()"); - fFitDaughters->Connect("Clicked()","Reve::TrackRnrStyleSubEditor", this, "DoFitPM()"); - } - // Kinematics fitting. - { - TGGroupFrame* rnrPM = new TGGroupFrame(fPMFrame, "PathMarks:", kLHintsTop | kLHintsCenterX); - rnrPM->SetTitlePos(TGGroupFrame::kLeft); - fPMFrame->AddFrame( rnrPM, new TGLayoutHints(kLHintsTop | kLHintsCenterX | kLHintsExpandX, 3, 3, 3, 3)); - - TGMatrixLayout *ml = new TGMatrixLayout(rnrPM, 0,1,6); - rnrPM->SetLayoutManager(ml); - - fRnrDaughters = new TGCheckButton(rnrPM, "Rnr Daughters", PathMark::Daughter); - fRnrReferences = new TGCheckButton(rnrPM, "Rnr Refs", PathMark::Reference); - fRnrDecay = new TGCheckButton(rnrPM, "Rnr Decay", PathMark::Decay); - - rnrPM->AddFrame(fRnrDaughters); - rnrPM->AddFrame(fRnrReferences); - rnrPM->AddFrame(fRnrDecay); - - fRnrDecay->Connect("Clicked()","Reve::TrackRnrStyleSubEditor", this, "DoRnrPM()"); - fRnrReferences->Connect("Clicked()","Reve::TrackRnrStyleSubEditor", this, "DoRnrPM()"); - fRnrDaughters->Connect("Clicked()","Reve::TrackRnrStyleSubEditor", this, "DoRnrPM()"); - - fRefsCont->AddFrame(fPMFrame, new TGLayoutHints(kLHintsTop, 1, 1, 1, 1)); - } - // Marker attributes. - { - fPMAtt = new TAttMarkerEditor(fRefsCont); - TGFrameElement *el = (TGFrameElement*) fPMAtt->GetList()->First(); - TGFrame *f = el->fFrame; fPMAtt->RemoveFrame(f); - f->DestroyWindow(); delete f; - fRefsCont->AddFrame(fPMAtt, new TGLayoutHints(kLHintsTop, 1, 1, 3, 1)); - } - - // First vertex. - TGCompositeFrame *title1 = new TGCompositeFrame(fRefsCont, 145, 10, - kHorizontalFrame | - kLHintsExpandX | - kFixedWidth | - kOwnBackground); - title1->AddFrame(new TGLabel(title1, "FirstVertex"), - new TGLayoutHints(kLHintsLeft, 1, 1, 0, 0)); - title1->AddFrame(new TGHorizontal3DLine(title1), - new TGLayoutHints(kLHintsExpandX, 5, 5, 7, 5)); - fRefsCont->AddFrame(title1, new TGLayoutHints(kLHintsTop, 0, 0, 2, 0)); - - fRnrFV = new TGCheckButton(fRefsCont, "Rnr"); - fRnrFV->Connect("Clicked()","Reve::TrackRnrStyleSubEditor", this, "DoRnrFV()"); - fRefsCont->AddFrame(fRnrFV, new TGLayoutHints(kLHintsTop, 5, 1, 2, 0)); - { - fFVAtt = new TAttMarkerEditor(fRefsCont); - TGFrameElement *el = (TGFrameElement*) fFVAtt->GetList()->First(); - TGFrame *f = el->fFrame; fFVAtt->RemoveFrame(f); - f->DestroyWindow(); delete f; - fRefsCont->AddFrame(fFVAtt, new TGLayoutHints(kLHintsTop, 1, 1, 3, 1)); - } - p->AddFrame(fRefsCont,new TGLayoutHints(kLHintsTop| kLHintsExpandX)); -} - -//______________________________________________________________________________ -void TrackRnrStyleSubEditor::SetModel(TrackRnrStyle* m) -{ - // Set model object. - - fM = m; - - fMaxR->SetValue(fM->fMaxR); - fMaxZ->SetValue(fM->fMaxZ); - fMaxOrbits->SetValue(fM->fMaxOrbs); - fMinAng->SetValue(fM->fMinAng); - fDelta->SetValue(fM->fDelta); - - if(fM->fEditPathMarks) - { - ShowFrame(fPMFrame); - fRnrDaughters->SetState(fM->fRnrDaughters ? kButtonDown : kButtonUp); - fRnrReferences->SetState(fM->fRnrReferences ? kButtonDown : kButtonUp); - fRnrDecay->SetState(fM->fRnrDecay ? kButtonDown : kButtonUp); - - fFitDaughters->SetState(fM->fFitDaughters ? kButtonDown : kButtonUp); - fFitReferences->SetState(fM->fFitReferences ? kButtonDown : kButtonUp); - fFitDecay->SetState(fM->fFitDecay ? kButtonDown : kButtonUp); - - fPMAtt->SetModel(&fM->fPMAtt); - } - else - { - fRefsCont->HideFrame(fPMFrame); - } - - fRnrFV->SetState(fM->fRnrFV ? kButtonDown : kButtonUp); - fFVAtt->SetModel(&fM->fFVAtt); -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void TrackRnrStyleSubEditor::Changed() -{ - // Update registered tracks and emit "Changed()" signal. - - fM->UpdateBackPtrItems(); - Emit("Changed()"); -} - -/******************************************************************************/ - -void TrackRnrStyleSubEditor::DoMaxR() -{ - fM->SetMaxR(fMaxR->GetValue()); - Changed(); -} - -void TrackRnrStyleSubEditor::DoMaxZ() -{ - fM->SetMaxZ(fMaxZ->GetValue()); - Changed(); -} - -void TrackRnrStyleSubEditor::DoMaxOrbits() -{ - fM->SetMaxOrbs(fMaxOrbits->GetValue()); - Changed(); -} - -void TrackRnrStyleSubEditor::DoMinAng() -{ - fM->SetMinAng(fMinAng->GetValue()); - Changed(); -} - -void TrackRnrStyleSubEditor::DoDelta() -{ - fM->SetDelta(fDelta->GetValue()); - Changed(); -} - -/******************************************************************************/ - -void TrackRnrStyleSubEditor::DoFitPM() -{ - TGButton* b = (TGButton *) gTQSender; - PathMark::Type_e type = PathMark::Type_e(b->WidgetId()); - Bool_t on = b->IsOn(); - - switch(type) - { - case PathMark::Daughter: - fM->SetFitDaughters(on); - break; - case PathMark::Reference: - fM->SetFitReferences(on); - break; - case PathMark::Decay: - fM->SetFitDecay(on); - break; - default: - break; - } - Changed(); -} - -void TrackRnrStyleSubEditor::DoRnrPM() -{ - TGButton * b = (TGButton *) gTQSender; - PathMark::Type_e type = PathMark::Type_e(b->WidgetId()); - Bool_t on = b->IsOn(); - switch(type){ - case PathMark::Daughter: - fM->SetRnrDaughters(on); - break; - case PathMark::Reference: - fM->SetRnrReferences(on); - break; - case PathMark::Decay: - fM->SetRnrDecay(on); - break; - - default: - break; - } - Changed(); -} - -void TrackRnrStyleSubEditor::DoRnrFV() -{ - fM->SetRnrFV(fRnrFV->IsOn()); - Changed(); -} - - -//______________________________________________________________________________ -// TrackRnrStyleEditor -// -// GUI editor for TrackRnrStyle. -// It's only a wrapper around a TrackRnrStyleSubEditor that holds actual -// widgets. - -ClassImp(TrackRnrStyleEditor) - -//______________________________________________________________________________ -TrackRnrStyleEditor::TrackRnrStyleEditor(const TGWindow *p, - Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - fM(0), - fRSSubEditor(0) -{ - // Constructor. - - MakeTitle("RenderStyle"); - - fRSSubEditor = new TrackRnrStyleSubEditor(this); - fRSSubEditor->Connect("Changed()", "Reve::TrackRnrStyleEditor", this, "Update()"); - AddFrame(fRSSubEditor, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 2, 0,0,0)); - - TGVerticalFrame* refsFrame = CreateEditorTabSubFrame("Refs"); - TGCompositeFrame *title1 = new TGCompositeFrame(refsFrame, 145, 10, - kHorizontalFrame | - kLHintsExpandX | - kFixedWidth | - kOwnBackground); - title1->AddFrame(new TGLabel(title1, "PathMarks"), - new TGLayoutHints(kLHintsLeft, 1, 1, 0, 0)); - title1->AddFrame(new TGHorizontal3DLine(title1), - new TGLayoutHints(kLHintsExpandX, 5, 5, 7, 7)); - refsFrame->AddFrame(title1, new TGLayoutHints(kLHintsTop, 0, 0, 2, 0)); - - // path marks - fRSSubEditor->CreateRefsContainer(refsFrame); - fRSSubEditor->fPMAtt->SetGedEditor((TGedEditor*)gReve->GetEditor()); - fRSSubEditor->fFVAtt->SetGedEditor((TGedEditor*)gReve->GetEditor()); - - fRSSubEditor->Connect("Changed()", "Reve::TrackRnrStyleEditor", this, "Update()"); -} - -//______________________________________________________________________________ -TrackRnrStyleEditor::~TrackRnrStyleEditor() -{ - // Destructor. Noop. -} - -/******************************************************************************/ - -//______________________________________________________________________________ -void TrackRnrStyleEditor::SetModel(TObject* obj) -{ - // Set model object. - - fM = dynamic_cast(obj); - fRSSubEditor->SetModel(fM); -} diff --git a/EVE/Reve/TrackRnrStyleEditor.h b/EVE/Reve/TrackRnrStyleEditor.h deleted file mode 100644 index 7396fc7ea29..00000000000 --- a/EVE/Reve/TrackRnrStyleEditor.h +++ /dev/null @@ -1,110 +0,0 @@ -// $Header$ - -#ifndef REVE_TrackRnrStyleEditor_H -#define REVE_TrackRnrStyleEditor_H - -#include - -class TGButton; -class TGCheckButton; -class TGNumberEntry; -class TGColorSelect; -class TGComboBox; -class TGLineWidthComboBox; -class TGLineStyleComboBox; - -class TAttMarkerEditor; - -namespace Reve { - -class TrackRnrStyle; - -class RGValuator; -class RGDoubleValuator; -class TrackRnrStyleSubEditor; - -class TrackRnrStyleSubEditor : public TGVerticalFrame -{ - friend class TrackRnrStyleEditor; - friend class TrackListEditor; - -private: - TrackRnrStyleSubEditor(const TrackRnrStyleSubEditor&); // Not implemented - TrackRnrStyleSubEditor& operator=(const TrackRnrStyleSubEditor&); // Not implemented - -protected: - TrackRnrStyle *fM; - - Reve::RGValuator *fMaxR; - Reve::RGValuator *fMaxZ; - Reve::RGValuator *fMaxOrbits; - Reve::RGValuator *fMinAng; - Reve::RGValuator *fDelta; - - TGCheckButton *fRnrFV; - - TGCompositeFrame *fPMFrame; - TGButton *fFitDaughters; - TGButton *fFitReferences; - TGButton *fFitDecay; - TGButton *fRnrDaughters; - TGButton *fRnrReferences; - TGButton *fRnrDecay; - - TGCompositeFrame *fRefsCont; - - TAttMarkerEditor *fPMAtt; - TAttMarkerEditor *fFVAtt; - -public: - TrackRnrStyleSubEditor(const TGWindow* p); - virtual ~TrackRnrStyleSubEditor() {} - - void SetModel(TrackRnrStyle* m); - - void Changed(); //*SIGNAL* - - void DoMaxR(); - void DoMaxZ(); - void DoMaxOrbits(); - void DoMinAng(); - void DoDelta(); - - void DoFitPM(); - void DoRnrPM(); - - void DoRnrFV(); - - void CreateRefsContainer(TGVerticalFrame* p); - - ClassDef(TrackRnrStyleSubEditor, 0) // Sub-editor for TrackRnrStyle. -}; - -/**************************************************************************/ -// TrackRnrStyleEditor -/**************************************************************************/ - -class TrackRnrStyleEditor : public TGedFrame -{ -private: - TrackRnrStyleEditor(const TrackRnrStyleEditor&); // Not implemented - TrackRnrStyleEditor& operator=(const TrackRnrStyleEditor&); // Not implemented - - void CreateRefTab(); -protected: - TrackRnrStyle *fM; // Model object. - TrackRnrStyleSubEditor *fRSSubEditor; // Render-style sub-editor. - -public: - TrackRnrStyleEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, - UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - ~TrackRnrStyleEditor(); - - virtual void SetModel(TObject* obj); - - ClassDef(TrackRnrStyleEditor, 1); // Editor for TrackRnrStyle. -}; // endclass TrackRnrStyleEditor - -} - -#endif diff --git a/EVE/Reve/TriangleSet.cxx b/EVE/Reve/TriangleSet.cxx deleted file mode 100644 index a0e63d57a69..00000000000 --- a/EVE/Reve/TriangleSet.cxx +++ /dev/null @@ -1,199 +0,0 @@ -/************************************************************************** - * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * - * * - * Author: The ALICE Off-line Project. * - * Contributors are mentioned in the code where appropriate. * - * * - * Permission to use, copy, modify and distribute this software and its * - * documentation strictly for non-commercial purposes is hereby granted * - * without fee, provided that the above copyright notice appears in all * - * copies and that both the copyright notice and this permission notice * - * appear in the supporting documentation. The authors make no claims * - * about the suitability of this software for any purpose. It is * - * provided "as is" without express or implied warranty. * - **************************************************************************/ - -/* $Id$ */ - - -#include "TriangleSet.h" -#include "RGBAPalette.h" -#include "ReveManager.h" - -#include -#include -#include -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// TriangleSet -// -// Made from a list of vertices and a list of triangles (triplets of -// vertex indices). -// -// If input is composed from triangles with direct vertex coordinates -// one should consider finding all occurences of the same vertex -// and specifying it only once. -// - -ClassImp(TriangleSet) - -TriangleSet::TriangleSet(Int_t nv, Int_t nt, Bool_t norms, Bool_t cols) : - RenderElement(fColor), - TNamed("TriangleSet", 0), - fNVerts (nv), fVerts(0), - fNTrings (nt), fTrings(0), fTringNorms(0), fTringCols(0), - fColor (2), fTransp(0), - fHMTrans () -{ - // Constructor. - - fVerts = new Float_t[3*fNVerts]; - fTrings = new Int_t [3*fNTrings]; - fTringNorms = (norms) ? new Float_t[3*fNTrings] : 0; - fTringCols = (cols) ? new UChar_t[3*fNTrings] : 0; -} - -TriangleSet::~TriangleSet() -{ - // Destructor. - - delete [] fVerts; - delete [] fTrings; - delete [] fTringNorms; - delete [] fTringCols; -} - -/**************************************************************************/ - -void TriangleSet::GenerateTriangleNormals() -{ - // Generate triangle normals via cross product of triangle edges. - - if (fTringNorms == 0) fTringNorms = new Float_t[3*fNTrings]; - - TVector3 e1, e2, n; - Float_t *N = fTringNorms; - Int_t *T = fTrings; - for(Int_t t=0; tRedraw3D(); -} - -/**************************************************************************/ - -void TriangleSet::ComputeBBox() -{ - if (fNVerts <= 0) { - BBoxZero(); - return; - } - - BBoxInit(); - Float_t* v = fVerts; - for (Int_t i=0; iGetViewer3D()->AddObject(buffer); - if (reqSections == TBuffer3D::kNone) { - return; - } - - Error("TriangleSet::Paint", "only direct OpenGL rendering supported."); -} - -/**************************************************************************/ - -#include - -TriangleSet* TriangleSet::ReadTrivialFile(const char* file) -{ - FILE* f = fopen(file, "r"); - if (f == 0) { - ::Error("TriangleSet::ReadTrivialFile", Form("file '%s' not found.", file)); - return 0; - } - - Int_t nv, nt; - fscanf(f, "%d %d", &nv, &nt); - - TriangleSet* ts = new TriangleSet(nv, nt); - - Float_t *V = ts->Vertex(0); - for (Int_t i=0; iTriangle(0); - for (Int_t i=0; i -#include -#include - -#include "ZTrans.h" - -class TGeoMatrix; - -namespace Reve { - -class TriangleSet : public RenderElement, - public TNamed, - public TAttBBox, - public TAtt3D -{ - friend class TriangleSetEditor; - friend class TriangleSetGL; - - TriangleSet(const TriangleSet&); // Not implemented - TriangleSet& operator=(const TriangleSet&); // Not implemented - -protected: - - // Vertex data - Int_t fNVerts; - Float_t* fVerts; //[3*fNVerts] - - // Triangle data - Int_t fNTrings; - Int_t* fTrings; //[3*fNTrings] - Float_t* fTringNorms; //[3*fNTrings] - UChar_t* fTringCols; //[3*fNTrings] - - // -------------------------------------------------------------- - - Color_t fColor; - UShort_t fTransp; - ZTrans fHMTrans; - -public: - - TriangleSet(Int_t nv, Int_t nt, Bool_t norms=false, Bool_t cols=false); - ~TriangleSet(); - - virtual Bool_t CanEditMainColor() { return kTRUE; } - - Float_t* Vertex(Int_t i) { return &(fVerts[3*i]); } - Int_t* Triangle(Int_t i) { return &(fTrings[3*i]); } - Float_t* TriangleNormal(Int_t i) { return &(fTringNorms[3*i]); } - UChar_t* TriangleColor(Int_t i) { return &(fTringCols[3*i]); } - - void SetVertex(Int_t i, Float_t x, Float_t y, Float_t z) - { Float_t* v = Vertex(i); v[0] = x; v[1] = y; v[2] = z; } - void SetTriangle(Int_t i, Int_t v0, Int_t v1, Int_t v2) - { Int_t* t = Triangle(i); t[0] = v0; t[1] = v1; t[2] = v2; } - void SetTriangleColor(Int_t i, UChar_t r, UChar_t g, UChar_t b, UChar_t a=255) - { UChar_t* c = TriangleColor(i); c[0] = r; c[1] = g; c[2] = b; c[3] = a; } - - void GenerateTriangleNormals(); - void GenerateRandomColors(); - void GenerateZNormalColors(Float_t fac=20, Int_t min=-20, Int_t max=20, - Bool_t interp=kFALSE, Bool_t wrap=kFALSE); - - virtual void ComputeBBox(); - virtual void Paint(Option_t* = ""); - - Color_t GetColor() const { return fColor; } - void SetColor(Color_t c) { fColor = c; } - - UShort_t GetTransparency() const { return fTransp; } - void SetTransparency(UShort_t tr) { fTransp = tr; } // *MENU* - - ZTrans& RefHMTrans() { return fHMTrans; } - void SetTransMatrix(Double_t* carr) { fHMTrans.SetFrom(carr); } - void SetTransMatrix(const TGeoMatrix& mat) { fHMTrans.SetFrom(mat); } - - static TriangleSet* ReadTrivialFile(const char* file); - - ClassDef(TriangleSet, 0); // Generic triangle mesh or soup. -}; // endclass TriangleSet - -} - -#endif diff --git a/EVE/Reve/TriangleSetEditor.cxx b/EVE/Reve/TriangleSetEditor.cxx deleted file mode 100644 index 2c8999a2231..00000000000 --- a/EVE/Reve/TriangleSetEditor.cxx +++ /dev/null @@ -1,50 +0,0 @@ -// $Header$ - -#include "TriangleSetEditor.h" -#include -#include - -#include -#include - -#include -#include -#include -#include -#include - -using namespace Reve; - -//______________________________________________________________________ -// TriangleSetEditor -// - -ClassImp(TriangleSetEditor) - -TriangleSetEditor::TriangleSetEditor(const TGWindow *p, Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - fM(0), - fHMTrans(0) -{ - MakeTitle("TriangleSet"); - - fHMTrans = new ZTransSubEditor(this); - fHMTrans->Connect("UseTrans()", "Reve::TriangleSetEditor", this, "Update()"); - fHMTrans->Connect("TransChanged()", "Reve::TriangleSetEditor", this, "Update()"); - AddFrame(fHMTrans, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 2, 0, 0, 0)); -} - -TriangleSetEditor::~TriangleSetEditor() -{ - delete fHMTrans; -} - -/**************************************************************************/ - -void TriangleSetEditor::SetModel(TObject* obj) -{ - fM = dynamic_cast(obj); - - fHMTrans->SetDataFromTrans(&fM->fHMTrans); -} diff --git a/EVE/Reve/TriangleSetEditor.h b/EVE/Reve/TriangleSetEditor.h deleted file mode 100644 index 00358bd87b4..00000000000 --- a/EVE/Reve/TriangleSetEditor.h +++ /dev/null @@ -1,39 +0,0 @@ -// $Header$ - -#ifndef REVE_TriangleSetEditor_H -#define REVE_TriangleSetEditor_H - -#include - -class TGCheckButton; -class TGNumberEntry; -class TGColorSelect; - -namespace Reve { - -class ZTransSubEditor; -class TriangleSet; - -class TriangleSetEditor : public TGedFrame -{ -private: - TriangleSetEditor(const TriangleSetEditor&); // Not implemented - TriangleSetEditor& operator=(const TriangleSetEditor&); // Not implemented - -protected: - TriangleSet *fM; // Model object. - - ZTransSubEditor *fHMTrans; // Sub-editor of transforamtion matrix. - -public: - TriangleSetEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, UInt_t options = kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - virtual ~TriangleSetEditor(); - - virtual void SetModel(TObject* obj); - - ClassDef(TriangleSetEditor, 1); // Editor for TriangleSet class. -}; // endclass TriangleSetEditor - -} - -#endif diff --git a/EVE/Reve/TriangleSetGL.cxx b/EVE/Reve/TriangleSetGL.cxx deleted file mode 100644 index eec0242c014..00000000000 --- a/EVE/Reve/TriangleSetGL.cxx +++ /dev/null @@ -1,111 +0,0 @@ -// $Header$ - -#include "TriangleSetGL.h" -#include "TriangleSet.h" -#include - -#include - -//______________________________________________________________________ -// TriangleSetGL -// -// GL-renderer for TriangleSet class. -// -// See also: TGLObject, TGLLogicalShape. - -using namespace Reve; - -ClassImp(TriangleSetGL) - -TriangleSetGL::TriangleSetGL() : TGLObject(), fM(0) -{ - // Constructor. - - // fDLCache = false; // Disable display list. -} - -TriangleSetGL::~TriangleSetGL() -{ - // Destructor. -} - -/**************************************************************************/ - -Bool_t TriangleSetGL::SetModel(TObject* obj, const Option_t* /*opt*/) -{ - // Set model object. - - if(SetModelCheckClass(obj, TriangleSet::Class())) { - fM = dynamic_cast(obj); - return kTRUE; - } - return kFALSE; -} - -void TriangleSetGL::SetBBox() -{ - // Set bounding-box from the model. - - // !! This ok if master sub-classed from TAttBBox - SetAxisAlignedBBox(((TriangleSet*)fExternalObj)->AssertBBox()); -} - -/**************************************************************************/ - -void TriangleSetGL::DirectDraw(TGLRnrCtx & /*rnrCtx*/) const -{ - // Low-level GL rendering. - - TriangleSet& TS = *fM; - Bool_t isScaled = TS.fHMTrans.IsScale(); - - GLint ex_shade_model; - glGetIntegerv(GL_SHADE_MODEL, &ex_shade_model); - glShadeModel(GL_FLAT); - - glPushAttrib(GL_ENABLE_BIT | GL_POLYGON_BIT); - - glColorMaterial(GL_FRONT_AND_BACK, GL_DIFFUSE); - glEnable(GL_COLOR_MATERIAL); - glPolygonMode(GL_FRONT, GL_FILL); - glPolygonMode(GL_BACK, GL_LINE); - glDisable(GL_CULL_FACE); - if (isScaled) glEnable(GL_NORMALIZE); - glPushClientAttrib(GL_CLIENT_VERTEX_ARRAY_BIT); - glVertexPointer(3, GL_FLOAT, 0, TS.fVerts); - glEnableClientState(GL_VERTEX_ARRAY); - - Int_t* T = TS.fTrings; - Float_t* N = TS.fTringNorms; - UChar_t* C = TS.fTringCols; - - TVector3 e1, e2, n; - - glBegin(GL_TRIANGLES); - for(Int_t t=0; t - -class TGLRnrCtx; - -namespace Reve { - -class TriangleSet; - -class TriangleSetGL : public TGLObject -{ -private: - TriangleSetGL(const TriangleSetGL&); // Not implemented - TriangleSetGL& operator=(const TriangleSetGL&); // Not implemented - -protected: - TriangleSet* fM; // Model object. - - virtual void DirectDraw(TGLRnrCtx & rnrCtx) const; - -public: - TriangleSetGL(); - virtual ~TriangleSetGL(); - - virtual Bool_t SetModel(TObject* obj, const Option_t* opt=0); - virtual void SetBBox(); - - // To support two-level selection - // virtual Bool_t SupportsSecondarySelect() const { return kTRUE; } - // virtual void ProcessSelection(UInt_t* ptr, TGLViewer*, TGLScene*); - - ClassDef(TriangleSetGL, 0); // GL-renderer for TriangleSet class. -}; // endclass TriangleSetGL - -} - -#endif diff --git a/EVE/Reve/VSD.cxx b/EVE/Reve/VSD.cxx deleted file mode 100644 index 0a8e3d63b9a..00000000000 --- a/EVE/Reve/VSD.cxx +++ /dev/null @@ -1,206 +0,0 @@ -// $Header$ - -#include "VSD.h" -#include - -using namespace Reve; - -//______________________________________________________________________ -// VSD -// - -ClassImp(VSD) - -VSD::VSD(const Text_t* , const Text_t* ) : - TObject(), - - fBuffSize (128*1024), - - mFile (0), - mDirectory (0), - - - mTreeK (0), - //mTreeTR (0), - mTreeH (0), - mTreeC (0), - mTreeR (0), - mTreeKK (0), - mTreeV0 (0), - mTreeGI (0), - - mK(), mpK (&mK), - mH(), mpH (&mH), - mC(), mpC (&mC), - mR(), mpR (&mR), - mKK(), mpKK(&mKK), - mV0(), mpV0(&mV0), - mGI(), mpGI(&mGI) -{} - -/**************************************************************************/ -/**************************************************************************/ - -void VSD::SetDirectory(TDirectory* dir) -{ - mDirectory = dir; -} - -/**************************************************************************/ -/**************************************************************************/ - -void VSD::CreateTrees() -{ - mDirectory->cd(); - // TR missing ... - mTreeK = new TTree("Kinematics", "Simulated tracks."); - mTreeH = new TTree("Hits", "Combined detector hits."); - mTreeC = new TTree("Clusters", "Reconstructed clusters."); - mTreeR = new TTree("RecTracks", "Reconstructed tracks."); - mTreeKK = new TTree("RecKinks", "Reconstructed kinks."); - mTreeV0 = new TTree("RecV0s", "Reconstructed V0s."); - mTreeGI = new TTree("GenInfo", "Objects prepared for cross query."); -} - -void VSD::DeleteTrees() -{ - delete mTreeK; mTreeK = 0; - // delete mTreeTR; mTreeTR = 0; - delete mTreeH; mTreeH = 0; - delete mTreeC; mTreeC = 0; - delete mTreeR; mTreeR = 0; - delete mTreeV0; mTreeV0 = 0; - delete mTreeKK; mTreeKK = 0; - delete mTreeGI; mTreeGI = 0; -} - -void VSD::CreateBranches() -{ - // TR missing ... - if(mTreeK) - mTreeK ->Branch("K", "Reve::MCTrack", &mpK, fBuffSize); - if(mTreeH) - mTreeH ->Branch("H", "Reve::Hit", &mpH, fBuffSize); - if(mTreeC) - mTreeC ->Branch("C", "Reve::Cluster", &mpC, fBuffSize); - if(mTreeR) - mTreeR ->Branch("R", "Reve::RecTrack", &mpR, fBuffSize); - if(mTreeKK) - mTreeKK->Branch("KK", "Reve::RecKink", &mpKK, fBuffSize); - if(mTreeV0) - mTreeV0->Branch("V0", "Reve::RecV0", &mpV0, fBuffSize); - - if(mTreeGI) { - mTreeGI->Branch("GI", "Reve::GenInfo", &mpGI, fBuffSize); - mTreeGI->Branch("K.", "Reve::MCTrack", &mpK); - mTreeGI->Branch("R.", "Reve::RecTrack", &mpR); - } -} - -void VSD::SetBranchAddresses() -{ - // TR missing ... - if(mTreeK) - mTreeK ->SetBranchAddress("K", &mpK); - if(mTreeH) - mTreeH ->SetBranchAddress("H", &mpH); - if(mTreeC) - mTreeC ->SetBranchAddress("C", &mpC); - if(mTreeR) - mTreeR ->SetBranchAddress("R", &mpR); - if(mTreeKK) - mTreeKK->SetBranchAddress("KK", &mpKK); - if(mTreeV0) - mTreeV0->SetBranchAddress("V0", &mpV0); - - if(mTreeGI) { - mTreeGI->SetBranchAddress("GI", &mpGI); - mTreeGI->SetBranchAddress("K.", &mpK); - mTreeGI->SetBranchAddress("R.", &mpR); - } -} - -void VSD::WriteTrees() -{ - // Does nothing here ... -} - -/**************************************************************************/ -/**************************************************************************/ - -void VSD::LoadTrees() -{ - static const Exc_t eH("VSD::LoadTrees "); - - if(mDirectory == 0) - throw(eH + "directory not set."); - - printf("Reading kinematics.\n"); - mTreeK = (TTree*) mDirectory->Get("Kinematics"); - if(mTreeK == 0) { - printf("%s Kinematics not available in mDirectory %s.\n", - eH.Data(), mDirectory->GetName()); - } - - printf("Reading hits.\n"); - mTreeH = (TTree*) mDirectory->Get("Hits"); - if(mTreeH == 0) { - printf("%s Hits not available in mDirectory %s.\n", - eH.Data(), mDirectory->GetName()); - } - - printf("Reading clusters.\n"); - mTreeC = (TTree*) mDirectory->Get("Clusters"); - if(mTreeC == 0) { - printf("%s Clusters not available in mDirectory %s.\n", - eH.Data(), mDirectory->GetName()); - } - - printf("Reading reconstructed tracks.\n"); - mTreeR = (TTree*) mDirectory->Get("RecTracks"); - if(mTreeR == 0) { - printf("%s RecTracks not available in mDirectory %s.\n", - eH.Data(), mDirectory->GetName()); - } - - printf("Reading reconstructed kinks. \n"); - mTreeKK = (TTree*) mDirectory->Get("RecKinks"); - if(mTreeKK == 0) { - printf("%s Kinks not available in mDirectory %s.\n", - eH.Data(), mDirectory->GetName()); - } - - printf("Reading Reconstructed V0s.\n"); - mTreeV0 = (TTree*) mDirectory->Get("RecV0s"); - if(mTreeV0 == 0) { - printf("%s V0 not available in mDirectory %s.\n", - eH.Data(), mDirectory->GetName()); - } - - printf("Reading GenInfo.\n"); - mTreeGI = (TTree*)mDirectory->Get("GenInfo"); - if(mTreeGI == 0) { - printf("%s GenInfo not available in mDirectory %s.\n", - eH.Data(), mDirectory->GetName()); - } - -} - -void VSD::LoadVSD(const Text_t* vsd_file_name, const Text_t* dir_name) -{ - static const Exc_t eH("VSD::LoadVSD "); - - mFile = TFile::Open(vsd_file_name); - if(mFile == 0) - throw(eH + "can not open VSD file '" + vsd_file_name + "'."); - - mDirectory = (TDirectory*) mFile->Get(dir_name); - if(mDirectory == 0) - throw(eH + "directory '" + dir_name + "' not found in VSD file '" + vsd_file_name + "'."); - printf("%p\n", (void*)mDirectory); - LoadTrees(); - SetBranchAddresses(); -} - -/**************************************************************************/ -/**************************************************************************/ diff --git a/EVE/Reve/VSD.h b/EVE/Reve/VSD.h deleted file mode 100644 index 700b3bdec06..00000000000 --- a/EVE/Reve/VSD.h +++ /dev/null @@ -1,70 +0,0 @@ -// $Header$ - -#ifndef REVE_VSD_H -#define REVE_VSD_H - -#include "Reve.h" -#include "PODs.h" -#include - -namespace Reve { - -class VSDTree : public TTree -{ -public: - ClassDef(VSDTree, 1); -}; - -class VSD : public TObject -{ - VSD(const VSD&); // Not implemented - VSD& operator=(const VSD&); // Not implemented - -protected: - Int_t fBuffSize; - - TFile* mFile; //! - TDirectory* mDirectory; //! - -public: - TTree* mTreeK; //! X{g} - //TTree* mTreeTR; //! X{g} - TTree* mTreeH; //! X{g} - TTree* mTreeC; //! X{g} - TTree* mTreeR; //! X{g} - TTree* mTreeKK; //! X{g} - TTree* mTreeV0; //! X{g} - TTree* mTreeGI; //! X{g} - - MCTrack mK, *mpK; //! - //MCTrackRef mTR, *mpTR; //! - Hit mH, *mpH; //! - Cluster mC, *mpC; //! - RecTrack mR, *mpR; //! - RecKink mKK, *mpKK; //! - RecV0 mV0, *mpV0; //! - GenInfo mGI, *mpGI; //! - -public: - VSD(const Text_t* name="VSD", const Text_t* title=""); - - virtual void SetDirectory(TDirectory* dir); - - virtual void CreateTrees(); - virtual void DeleteTrees(); - - virtual void CreateBranches(); - virtual void SetBranchAddresses(); - - virtual void WriteTrees(); - virtual void LoadTrees(); - - virtual void LoadVSD(const Text_t* vsd_file_name, - const Text_t* dir_name="Event0"); - - ClassDef(VSD, 1); -}; // endclass VSD - -} - -#endif diff --git a/EVE/Reve/VSDEvent.cxx b/EVE/Reve/VSDEvent.cxx deleted file mode 100644 index 92bb775e504..00000000000 --- a/EVE/Reve/VSDEvent.cxx +++ /dev/null @@ -1,104 +0,0 @@ -// $Header$ - -#include "VSDEvent.h" - -#include - -using namespace Reve; - -//______________________________________________________________________ -// VSDEvent -// - -ClassImp(VSDEvent) - -/**************************************************************************/ - -const TString VSDEvent::sVSDHeaderName("VSDheader"); - -VSDEvent::VSDEvent() : - EventBase("VSDEvent"), - fRun(0), fEvent(0), fUrl(), - fTags(), - fDirectory(0), fCreator(0), fSelector(0) -{} - -VSDEvent::VSDEvent(Int_t run, Int_t evt, const TString& url) : - EventBase("VSDEvent"), - fRun(run), fEvent(evt), fUrl(url), - fTags(), - fDirectory(0), fCreator(0), fSelector(0) -{} - -VSDEvent::VSDEvent(const TString& url) : - EventBase("VSDEvent"), - fRun(0), fEvent(0), fUrl(url), - fTags(), - fDirectory(0), fCreator(0), fSelector(0) -{} - -/**************************************************************************/ - -VSDEvent* VSDEvent::OpenDirectory(const TString& dir_name) -{ - static const Exc_t eH("VSDEvent::OpenDirectory "); - - TDirectory* dir = dynamic_cast(gDirectory->Get(dir_name)); - if (!dir) - throw(eH + "direcotry '" + dir_name + "' not found."); - return OpenDirectory(dir); -} - -VSDEvent* VSDEvent::OpenDirectory(TDirectory* dir) -{ - static const Exc_t eH("VSDEvent::OpenDirectory "); - - VSDEvent* evt = dynamic_cast(dir->Get(sVSDHeaderName)); - if (!evt) - throw(eH + "VSD header '" + sVSDHeaderName + "' not found."); - evt->fDirectory = dir; - return evt; -} - -/**************************************************************************/ -/**************************************************************************/ - -void VSDEvent::SetDirectory(TDirectory* dir) -{ - if(fDirectory) - fDirectory->RecursiveRemove(this); - fDirectory = dir; - if(fDirectory) - fDirectory->Append(this); -} - -TDirectory* VSDEvent::MakeDirectory(const Text_t* name, const Text_t* title) -{ - TDirectory* dir = new TDirectory(name, title); - SetDirectory(dir); - return fDirectory; -} - -/**************************************************************************/ - -void VSDEvent::Print(Option_t* ) const -{ - printf("%s: '%s', '%s'\n", IsA()->GetName(), GetName(), GetTitle()); - printf(" run=%d, event=%d, url='%s'\n", fRun, fEvent, fUrl.Data()); - if(fDirectory) - printf(" directory: '%s', '%s'\n", fDirectory->GetName(), fDirectory->GetTitle()); -} - -/**************************************************************************/ -/**************************************************************************/ -/**************************************************************************/ -/**************************************************************************/ - -#include - -void EvTree::Browse(TBrowser* b) -{ - // fFolder.Browse(b); // This adds all elements to top-level. - b->Add(&fFolder); - TTree::Browse(b); -} diff --git a/EVE/Reve/VSDEvent.h b/EVE/Reve/VSDEvent.h deleted file mode 100644 index 054e4c78047..00000000000 --- a/EVE/Reve/VSDEvent.h +++ /dev/null @@ -1,74 +0,0 @@ -// $Header$ - -#ifndef REVE_Event_H -#define REVE_Event_H - -#include - -#include -#include - -#include -#include -class TBrowser; - -namespace Reve { - -class VSD; - -class EvTree : public TTree -{ -public: - TFolder fFolder; - - EvTree() : TTree(), fFolder() {} - EvTree(const char* name, const char* title, Int_t splitlevel = 99) : - TTree(name, title, splitlevel), fFolder("Folder", "Additional event data") {} - virtual ~EvTree() {} - - virtual void Browse(TBrowser* b); - - ClassDef(EvTree, 1); -}; - -class VSDEvent : public EventBase -{ - VSDEvent(const VSDEvent&); // Not implemented - VSDEvent& operator=(const VSDEvent&); // Not implemented - -protected: - Int_t fRun; - Int_t fEvent; - TString fUrl; - - std::map fTags; - - TDirectory* fDirectory; //! - - VSD* fCreator; //! - VSD* fSelector; //! - -public: - VSDEvent(); - VSDEvent(Int_t run, Int_t evt, const TString& url="."); - VSDEvent(const TString& url); - // Static ctors - static VSDEvent* OpenDirectory(const TString& dir_name); - static VSDEvent* OpenDirectory(TDirectory* dir); - - TDirectory* GetDirectory() { return fDirectory; } - void SetDirectory(TDirectory* dir); - TDirectory* MakeDirectory(const Text_t* name, const Text_t* title=""); - - TObject* Get(const Text_t* obj_name) { return fDirectory->Get(obj_name); } - - virtual void Print(Option_t* opt="") const; - - static const TString sVSDHeaderName; - - ClassDef(VSDEvent, 1); -}; // endclass VSDEvent - -} - -#endif diff --git a/EVE/Reve/VSDSelector.cxx b/EVE/Reve/VSDSelector.cxx deleted file mode 100644 index cea5f1c5c85..00000000000 --- a/EVE/Reve/VSDSelector.cxx +++ /dev/null @@ -1,374 +0,0 @@ - -#include "VSDSelector.h" -#include "VSDEvent.h" -#include "ReveManager.h" - -#include -#include - -#include -#include - -#include -#include -#include -#include - -using namespace Reve; - -using Reve::Exc_t; - -VSDSelector::VSDSelector(TGCompositeFrame *tFrame) : - VSD(), - - mParticleSelection(0), - fRecursiveSelect(0), - - mHitSelection(0), - mClusterSelection(0), - mRecSelection(0) -{ - //create gui - TGGroupFrame *gframe = new TGGroupFrame(tFrame, "Options", kVerticalFrame); - TGLayoutHints* lh0 = new TGLayoutHints(kLHintsTop | kLHintsLeft | kLHintsExpandX | kLHintsExpandY , 5, 5, 5, 5); - gframe->SetTitlePos(TGGroupFrame::kRight); // right aligned - tFrame->AddFrame(gframe, lh0); - - TGXYLayout* xyl = new TGXYLayout(gframe); - gframe->SetLayoutManager(xyl); - xyl->Layout(); - - TGXYLayoutHints* lh; - - UInt_t wH = 2; - UInt_t labelw = 15; - UInt_t entryw = 39; - UInt_t butw = 10; - - Float_t x = 2, y = 2; - - { - // particles - TGLabel* label = new TGLabel(gframe, "ParticleSelection"); - label->Resize(labelw, wH); - label->SetTextJustify(kTextLeft | kTextCenterY); - lh = new TGXYLayoutHints(x, y, labelw, wH,0); lh->SetPadLeft(2); lh->SetPadRight(2); - gframe->AddFrame(label,lh); - x += labelw ; - - mParticleSelection = new TGTextEntry(gframe, "fMother[0] == -1 && Pt() > 1"); - mParticleSelection->Resize(entryw, wH); - lh = new TGXYLayoutHints(x, y, entryw, wH,0); lh->SetPadLeft(2); lh->SetPadRight(2); - gframe->AddFrame(mParticleSelection,lh); - x += entryw+1; - - TGTextButton* but = new TGTextButton(gframe, "Select"); - but->Resize(butw, wH); - but->SetTextJustify(kTextCenterX | kTextCenterY); - lh = new TGXYLayoutHints(x, y, butw, wH,0); lh->SetPadLeft(4); lh->SetPadRight(2); - gframe->AddFrame(but,lh); - but->Connect("Pressed()", "Reve::VSDSelector", this, "SelectParticles()"); - - UInt_t rbw = 11; - x = x + butw + 0.5; - fRecursiveSelect = new TGCheckButton(gframe, "Recursive"); - fRecursiveSelect->Resize(rbw, wH); - lh = new TGXYLayoutHints(x, y, rbw, wH,0); lh->SetPadLeft(4); lh->SetPadRight(2); - gframe->AddFrame(fRecursiveSelect,lh); - } - x = 2.; - y+= wH; y+= 1.; - - - { // hits - TGLabel* label = new TGLabel(gframe, "HitSelection"); - label->Resize(labelw, wH); - label->SetTextJustify(kTextLeft | kTextCenterY); - lh = new TGXYLayoutHints(x, y, labelw, wH,0); lh->SetPadLeft(2); lh->SetPadRight(2); - gframe->AddFrame(label,lh); - x += labelw; - - mHitSelection = new TGTextEntry(gframe, "det_id == 0"); - mHitSelection->Resize(entryw, wH); - lh = new TGXYLayoutHints(x, y, entryw, wH,0); lh->SetPadLeft(2); lh->SetPadRight(2); - gframe->AddFrame(mHitSelection,lh); - x += entryw +1; - - TGTextButton* but = new TGTextButton(gframe, "Select"); - but->Resize(butw, wH); - but->SetTextJustify(kTextCenterX | kTextCenterY); - lh = new TGXYLayoutHints(x, y, butw, wH,0); lh->SetPadLeft(4); lh->SetPadRight(2); - gframe->AddFrame(but,lh); - but->Connect("Pressed()", "Reve::VSDSelector", this, "SelectHits()"); - - } - - x = 2.; - y+= wH; y+= 1.; - - { // particle selection - TGLabel* label = new TGLabel(gframe, "ClusterSelection"); - label->Resize(labelw, wH); - label->SetTextJustify(kTextLeft | kTextCenterY); - lh = new TGXYLayoutHints(x, y, labelw, wH,0); lh->SetPadLeft(2); lh->SetPadRight(2); - gframe->AddFrame(label,lh); - x += labelw; - - mClusterSelection = new TGTextEntry(gframe, "C.V.R() > 70"); - mClusterSelection->Resize(entryw, wH); - lh = new TGXYLayoutHints(x, y, entryw, wH,0); lh->SetPadLeft(2); lh->SetPadRight(2); - gframe->AddFrame(mClusterSelection,lh); - x += entryw +1; - - TGTextButton* but = new TGTextButton(gframe, "Select"); - but->Resize(butw, wH); - but->SetTextJustify(kTextCenterX | kTextCenterY); - lh = new TGXYLayoutHints(x, y, butw, wH,0); lh->SetPadLeft(4); lh->SetPadRight(2); - gframe->AddFrame(but,lh); - but->Connect("Pressed()", "Reve::VSDSelector", this, "SelectClusters()"); - } - - x = 2.; - y+= wH; y+= 1.; - - { // reconstructed tracks selection - TGLabel* label = new TGLabel(gframe, "RecSelection"); - label->Resize(labelw, wH); - label->SetTextJustify(kTextLeft | kTextCenterY); - lh = new TGXYLayoutHints(x, y, labelw, wH,0); lh->SetPadLeft(2); lh->SetPadRight(2); - gframe->AddFrame(label,lh); - x += labelw; - - mRecSelection = new TGTextEntry(gframe, "Pt() > 1"); - mRecSelection->Resize(entryw, wH); - lh = new TGXYLayoutHints(x, y, entryw, wH,0); lh->SetPadLeft(2); lh->SetPadRight(2); - gframe->AddFrame(mRecSelection,lh); - x += entryw +1; - - TGTextButton* but = new TGTextButton(gframe, "Select"); - but->Resize(butw, wH); - but->SetTextJustify(kTextCenterX | kTextCenterY); - lh = new TGXYLayoutHints(x, y, butw, wH,0); lh->SetPadLeft(4); lh->SetPadRight(2); - gframe->AddFrame(but,lh); - but->Connect("Pressed()", "Reve::VSDSelector", this, "SelectRecTracks()"); - } - - gframe->Resize(60, 30); // resize to default size - gframe->MapSubwindows(); - gframe->MapWindow(); - tFrame->MapSubwindows(); - -} - -/**************************************************************************/ - -void VSDSelector::LoadVSD(const Text_t* vsd_file_name, - const Text_t* dir_name) -{ - VSD::LoadVSD(vsd_file_name, dir_name); - // !!!! Should create VSDEvent ... but it is not done yet. - EventBase* ev = new EventBase(vsd_file_name, dir_name); - gReve->AddEvent(ev); -} - -/**************************************************************************/ -// selection methods -/**************************************************************************/ - -void VSDSelector::SelectParticles(const Text_t* selection) -{ - static const Exc_t eH("VSDSelector::SelectParticles "); - - if(mTreeK == 0) - throw (eH + "kinematics not available."); - - if(selection == 0) - selection = mParticleSelection->GetText(); - - TTreeQuery evl; - Int_t n = evl.Select(mTreeK, selection); - // printf("%d entries in selection '%s'.\n", n, selection); - - if(n == 0) - throw (eH + "no entries found for selection in kinematics."); - - TrackList* cont = new TrackList(); - cont->SetMainColor(4); - - gReve->AddRenderElement(cont); - - if(n > 0) { - for(Int_t i=0; iGetEntry(label); - Track* track = new Track(mpK, cont->GetRnrStyle()); - track->SetName(Form("%s daughters:%d", mK.GetName(), mK.GetNDaughters())); - gReve->AddRenderElement(track, cont); - - // printf("select daugters %s selection %s\n",mpK->GetName(),Form("fMother[0] == %d", track->GetLabel())); - if(fRecursiveSelect->IsOn()) { - if(mK.GetNDaughters()) - ImportDaughtersRec(track, cont, mK.GetFirstDaughter(), mK.GetLastDaughter()); - // add decay point to path marks - if(mK.decayed) { - Reve::PathMark* pm = new Reve::PathMark(Reve::PathMark::Decay); - pm->V.x = mK.V_decay.x; - pm->V.y = mK.V_decay.y; - pm->V.z = mK.V_decay.z; - track->AddPathMark(pm); - } - } - track->MakeTrack(); - } - } -} - -void VSDSelector::ImportDaughtersRec(RenderElement* parent, TrackList* cont, - Int_t first, Int_t last) -{ - Track* mother = dynamic_cast(parent); - - for(Int_t i=first; i<=last; i++) { - mTreeK->GetEntry(i); - Track* track = new Track(mpK, cont->GetRnrStyle()); - track->SetName(Form("%s daughters:%d", mK.GetName(), mK.GetNDaughters())); - gReve->AddRenderElement(track, parent); - cont->AddElement(track); // ?? is this ok ?? - if(mK.GetNDaughters()) - ImportDaughtersRec(track, cont, mK.GetFirstDaughter(), mK.GetLastDaughter()); - - // add daughter mark to mother - Reve::PathMark* dam = new Reve::PathMark(Reve::PathMark::Daughter); - dam->V.x = mK.Vx(); - dam->V.y = mK.Vy(); - dam->V.z = mK.Vz(); - mother->AddPathMark(dam); - - if(mK.decayed) { - Reve::PathMark* decm = new Reve::PathMark(Reve::PathMark::Decay); - decm->V.x = mK.V_decay.x; - decm->V.y = mK.V_decay.y; - decm->V.z = mK.V_decay.z; - track->AddPathMark(decm); - - } - track->MakeTrack(); - } -} - -/**************************************************************************/ -/**************************************************************************/ - -void VSDSelector::SelectHits() -{ - static const Exc_t eH("VSDSelector::SelectHits "); - - if(mTreeH == 0) - throw (eH + "hits not available."); - - const Text_t* selection; - if(mHitSelection) - selection = mHitSelection->GetText(); - else - selection ="1"; - - TTreeQuery evl; - Int_t n = evl.Select(mTreeH, selection); - // printf("ImportHitsWithSelection %d entries for selection %s\n", n, selection); - - if(n==0) - throw(eH + "no hits matching selection."); - - PointSet* container = new PointSet - (Form("Hits %s", selection), n); - for(Int_t i=0; iGetEntry(entry); - container->SetPoint(i, mH.V.x, mH.V.y, mH.V.z); - } - - container->SetTitle(Form("N=%d", container->GetN())); - container->SetMarkerColor(2); - container->SetMarkerStyle(20); - container->SetMarkerSize(0.5); - gReve->AddRenderElement(container); - gReve->Redraw3D(); -} - -/**************************************************************************/ - -void VSDSelector::SelectClusters() -{ - static const Exc_t eH("VSDSelector::SelectClusters "); - - if(mTreeC == 0) - throw (eH + "clusters not available."); - - const Text_t* selection; - if (mClusterSelection) - selection = mClusterSelection->GetText(); - else - selection ="1"; - - TTreeQuery evl; - Int_t n = evl.Select(mTreeC, selection); - printf(" cluster Selection %d entries for selection %s\n", n, selection); - - if(n==0) - throw(eH + "no clusters matching selection."); - - PointSet* container = new PointSet - (Form("Clusters %s", selection), n); - for(Int_t i=0; iGetEntry(entry); - container->SetPoint(i, mC.V.x, mC.V.y, mC.V.z); - } - - container->SetTitle(Form("N=%d", container->GetN())); - container->SetMarkerColor(9); - container->SetMarkerStyle(20); - container->SetMarkerSize(0.5); - gReve->AddRenderElement(container); - gReve->Redraw3D(); -} - -/**************************************************************************/ - -void VSDSelector::SelectRecTracks() -{ - static const Exc_t eH("VSDSelector::SelectRecTracks "); - - if(mTreeR == 0) - throw (eH + "reconstructed tracks not available."); - - const Text_t* selection; - if(mRecSelection) - selection = mRecSelection->GetText(); - else - selection = "Pt() > 1"; - - TTreeQuery evl; - Int_t n = evl.Select(mTreeR, selection); - // printf("%d entries in selection %s \n", n, selection); - - if (n == 0) - throw (eH + "No entries found in ESD data."); - - if(n > 0) { - TrackList* cont = new TrackList(Form("RecTracks %s [%d]",selection, n)); - cont->SetMainColor(6); - - gReve->AddRenderElement(cont); - - for (Int_t i=0; iGetEntry(label); - Track* track = new Track(mpR, cont->GetRnrStyle()); - track->MakeTrack(); - - gReve->AddRenderElement(track, cont); - } - gReve->Redraw3D(); - } -} diff --git a/EVE/Reve/VSDSelector.h b/EVE/Reve/VSDSelector.h deleted file mode 100644 index 36762e93339..00000000000 --- a/EVE/Reve/VSDSelector.h +++ /dev/null @@ -1,52 +0,0 @@ -#ifndef REVE_VSDSelector_H -#define REVE_VSDSelector_H - -#include "RGBrowser.h" -#include - -#include -#include - -namespace Reve { - -class RenderElement; -class TrackRnrStyle; -class TrackList; - -class VSDSelector : public VSD -{ - VSDSelector(const VSDSelector&); // Not implemented - VSDSelector& operator=(const VSDSelector&); // Not implemented - -protected: - TGTextEntry* mParticleSelection; - TGCheckButton* fRecursiveSelect; - - TGTextEntry* mHitSelection; - TGTextEntry* mClusterSelection; - TGTextEntry* mRecSelection; - -public: - - VSDSelector(TGCompositeFrame *tFrame); - - virtual void LoadVSD(const Text_t* vsd_file_name, - const Text_t* dir_name="Event0"); - - void SelectParticles (const Text_t* selection=0); - void ImportDaughtersRec(RenderElement* parent, TrackList* cont, - Int_t first, Int_t last); - - void SelectHits(); - void SelectClusters(); - void SelectRecTracks(); - - void SetRecursiveSelection(Bool_t rec){fRecursiveSelect->SetOn(rec,1);} - // printf("SetRecursiveSelection is %d on %d \n", rec?1:0,fRecursiveSelect->IsOn()?1:0);} - Bool_t GetRecursiveSelection(){return fRecursiveSelect->IsOn();} - ClassDef(VSDSelector, 1); -}; - -} - -#endif diff --git a/EVE/Reve/Viewer.cxx b/EVE/Reve/Viewer.cxx deleted file mode 100644 index e72273795b8..00000000000 --- a/EVE/Reve/Viewer.cxx +++ /dev/null @@ -1,177 +0,0 @@ -// $Header$ - -#include "Viewer.h" -#include "Scene.h" -#include "SceneInfo.h" - -#include - -#include -#include - -#include // For fixing defaults in root 5.17.4 - -using namespace Reve; - -//______________________________________________________________________ -// Reve::Viewer -// - -ClassImp(Viewer) - -Viewer::Viewer(const Text_t* n, const Text_t* t) : - RenderElementList(n, t), - fGLViewer (0) -{ - SetChildClass(SceneInfo::Class()); -} - -Viewer::~Viewer() -{} - -/**************************************************************************/ - -void Viewer::SetGLViewer(TGLViewer* s) -{ - delete fGLViewer; - fGLViewer = s; - - fGLViewer->SetSmartRefresh(kTRUE); - // fGLViewer->SetResetCamerasOnUpdate(kFALSE); - fGLViewer->SetResetCameraOnDoubleClick(kFALSE); - - // Temporary fix for wrong defaults in root 5.17.04 - fGLViewer->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - ((TGLOrthoCamera&)(fGLViewer->CurrentCamera())).SetEnableRotate(kTRUE); - fGLViewer->SetCurrentCamera(TGLViewer::kCameraOrthoXOZ); - ((TGLOrthoCamera&)(fGLViewer->CurrentCamera())).SetEnableRotate(kTRUE); - fGLViewer->SetCurrentCamera(TGLViewer::kCameraOrthoZOY); - ((TGLOrthoCamera&)(fGLViewer->CurrentCamera())).SetEnableRotate(kTRUE); - fGLViewer->SetCurrentCamera(TGLViewer::kCameraPerspXOZ); -} - -void Viewer::SpawnGLViewer(const TGWindow* parent, TGedEditor* ged) -{ - TGLSAViewer* v = new TGLSAViewer(parent, 0, ged); - v->ToggleEditObject(); - SetGLViewer(v); -} - -/**************************************************************************/ - -void Viewer::AddScene(Scene* scene) -{ - static const Exc_t eH("Viewer::AddScene "); - - TGLSceneInfo* glsi = fGLViewer->AddScene(scene->GetGLScene()); - if (glsi != 0) { - SceneInfo* si = new SceneInfo(this, scene, glsi); - gReve->AddRenderElement(si, this); - } else { - throw(eH + "scene already in the viewer."); - } -} - -void Viewer::RemoveElementLocal(RenderElement* el) -{ - fGLViewer->RemoveScene(((SceneInfo*)el)->GetGLScene()); -} - -void Viewer::RemoveElementsLocal() -{ - fGLViewer->RemoveAllScenes(); -} - -TObject* Viewer::GetEditorObject() const -{ - return fGLViewer; -} - -Bool_t Viewer::HandleElementPaste(RenderElement* el) -{ - static const Exc_t eH("Viewer::HandleElementPaste "); - - Scene* scene = dynamic_cast(el); - if (scene != 0) { - AddScene(scene); - return kTRUE; - } else { - Warning(eH.Data(), "class Viewer only accepts Scene paste argument."); - return kFALSE; - } -} - -/**************************************************************************/ -/**************************************************************************/ -/**************************************************************************/ - -//______________________________________________________________________ -// Reve::ViewerList -// - -ClassImp(ViewerList) - -ViewerList::ViewerList(const Text_t* n, const Text_t* t) : - RenderElementList(n, t) -{ - SetChildClass(Viewer::Class()); -} - -ViewerList::~ViewerList() -{} - -/**************************************************************************/ - -void ViewerList::RepaintChangedViewers(Bool_t resetCameras, Bool_t dropLogicals) -{ - for (List_i i=fChildren.begin(); i!=fChildren.end(); ++i) - { - TGLViewer* glv = ((Viewer*)*i)->GetGLViewer(); - if (glv->IsChanged()) - { - // printf(" Viewer '%s' changed ... reqesting draw.\n", (*i)->GetObject()->GetName()); - - if (resetCameras) glv->PostSceneBuildSetup(kTRUE); - if (dropLogicals) glv->SetSmartRefresh(kFALSE); - - glv->RequestDraw(TGLRnrCtx::kLODHigh); - - if (dropLogicals) glv->SetSmartRefresh(kTRUE); - } - } -} - -void ViewerList::RepaintAllViewers(Bool_t resetCameras, Bool_t dropLogicals) -{ - for (List_i i=fChildren.begin(); i!=fChildren.end(); ++i) - { - TGLViewer* glv = ((Viewer*)*i)->GetGLViewer(); - - // printf(" Viewer '%s' sending redraw reqest.\n", (*i)->GetObject()->GetName()); - - if (resetCameras) glv->PostSceneBuildSetup(kTRUE); - if (dropLogicals) glv->SetSmartRefresh(kFALSE); - - glv->RequestDraw(TGLRnrCtx::kLODHigh); - - if (dropLogicals) glv->SetSmartRefresh(kTRUE); - } -} - -/**************************************************************************/ - -void ViewerList::SceneDestructing(Scene* scene) -{ - for (List_i i=fChildren.begin(); i!=fChildren.end(); ++i) - { - Viewer* viewer = (Viewer*) *i; - List_i j = viewer->BeginChildren(); - while (j != viewer->EndChildren()) - { - SceneInfo* sinfo = (SceneInfo*) *j; - ++j; - if (sinfo->GetScene() == scene) - gReve->RemoveRenderElement(sinfo, viewer); - } - } -} diff --git a/EVE/Reve/Viewer.h b/EVE/Reve/Viewer.h deleted file mode 100644 index 4c5905c8668..00000000000 --- a/EVE/Reve/Viewer.h +++ /dev/null @@ -1,78 +0,0 @@ -// $Header$ - -#ifndef REVE_Viewer_H -#define REVE_Viewer_H - -#include - -class TGWindow; -class TGedEditor; -class TGLViewer; - -namespace Reve { - -class Scene; - -/**************************************************************************/ -// Viewer -/**************************************************************************/ - -class Viewer : public RenderElementList -{ -private: - Viewer(const Viewer&); // Not implemented - Viewer& operator=(const Viewer&); // Not implemented - -protected: - TGLViewer *fGLViewer; - -public: - Viewer(const Text_t* n="Viewer", const Text_t* t=""); - virtual ~Viewer(); - - TGLViewer* GetGLViewer() const { return fGLViewer; } - void SetGLViewer(TGLViewer* s); - void SpawnGLViewer(const TGWindow* parent, TGedEditor* ged); - - virtual void AddScene(Scene* scene); - - virtual void RemoveElementLocal(RenderElement* el); - virtual void RemoveElementsLocal(); - - virtual TObject* GetEditorObject() const; - - virtual Bool_t HandleElementPaste(RenderElement* el); - - virtual const TGPicture* GetListTreeIcon() { return RenderElement::fgListTreeIcons[1]; } - - ClassDef(Viewer, 0); // Reve representation of TGLViewer. -}; // endclass Viewer - - -/**************************************************************************/ -// ViewerList -/**************************************************************************/ - -class ViewerList : public RenderElementList -{ -private: - ViewerList(const ViewerList&); // Not implemented - ViewerList& operator=(const ViewerList&); // Not implemented - -protected: - -public: - ViewerList(const Text_t* n="ViewerList", const Text_t* t=""); - virtual ~ViewerList(); - - void RepaintChangedViewers(Bool_t resetCameras, Bool_t dropLogicals); - void RepaintAllViewers(Bool_t resetCameras, Bool_t dropLogicals); - - void SceneDestructing(Scene* scene); - - ClassDef(ViewerList, 0); // List of Viewers. -}; // endclass ViewerList - -} - -#endif diff --git a/EVE/Reve/ZTrans.cxx b/EVE/Reve/ZTrans.cxx deleted file mode 100644 index 2f51bd59bf0..00000000000 --- a/EVE/Reve/ZTrans.cxx +++ /dev/null @@ -1,777 +0,0 @@ -// $Header$ - -// Copyright (C) 1999-2005, Matevz Tadel. All rights reserved. -// This file is part of GLED, released under GNU General Public License version 2. -// For the licensing terms see $GLEDSYS/LICENSE or http://www.gnu.org/. - -//______________________________________________________________________ -// ZTrans -// -// ZTrans is a 4x4 transformation matrix for homogeneous coordinates -// stored internaly in a column-major order to allow direct usage by -// GL. The element type is Double32_t as statically the floats would -// be precise enough but continuous operations on the matrix must -// retain precision of column vectors. -// -// Cartan angles in mA[1-3] (+z, -y, +x) are stored for backward -// compatibility and will probably be removed soon. -// -// Direct element access (first two should be used with care): -// operator[i] direct access to elements, i:0->15 -// CM(i,j) element 4*j + i; i,j:0->3 { CM ~ c-matrix } -// operator(i,j) element 4*(j-1) + i - 1 i,j:1->4 -// -// Column-vector access: -// USet Get/SetBaseVec(), Get/SetPos() and Arr[XYZT]() methods. -// -// For all methods taking the matrix indices: -// 1->X, 2->Y, 3->Z; 4->Position (if applicable). 0 reserved for time. -// -// Shorthands in method-names: -// LF ~ LocalFrame; PF ~ ParentFrame; IP ~ InPlace - -#include "ZTrans.h" -#include "Reve.h" -#include -#include - -#include - -#define F00 0 -#define F01 4 -#define F02 8 -#define F03 12 - -#define F10 1 -#define F11 5 -#define F12 9 -#define F13 13 - -#define F20 2 -#define F21 6 -#define F22 10 -#define F23 14 - -#define F30 3 -#define F31 7 -#define F32 11 -#define F33 15 - -using namespace Reve; - -ClassImp(ZTrans) - -/**************************************************************************/ - -ZTrans::ZTrans() : - TObject(), - mA1(0), mA2(0), mA3(0), bAsOK(kFALSE), - fUseTrans (kTRUE), - fEditTrans(kFALSE) -{ - UnitTrans(); -} - -ZTrans::ZTrans(const ZTrans& t) : - TObject(), - mA1(t.mA1), mA2(t.mA2), mA3(t.mA3), bAsOK(t.bAsOK), - fUseTrans (t.fUseTrans), - fEditTrans(t.fEditTrans) -{ - SetTrans(t, kFALSE); -} - -ZTrans::ZTrans(const Double_t arr[16]) : - TObject(), - mA1(0), mA2(0), mA3(0), bAsOK(kFALSE), - fUseTrans (kTRUE), - fEditTrans(kFALSE) -{ - SetFromArray(arr); -} - -ZTrans::ZTrans(const Float_t arr[16]) : - TObject(), - mA1(0), mA2(0), mA3(0), bAsOK(kFALSE), - fUseTrans (kTRUE), - fEditTrans(kFALSE) -{ - SetFromArray(arr); -} - -/**************************************************************************/ - -void ZTrans::UnitTrans() -{ - // Reset matrix to unity. - - memset(M, 0, 16*sizeof(Double_t)); - M[F00] = M[F11] = M[F22] = M[F33] = 1; - mA1 = mA2 = mA3 = 0; - bAsOK = kTRUE; -} - -void ZTrans::UnitRot() -{ - // Reset rotation part of the matrix to unity. - - memset(M, 0, 12*sizeof(Double_t)); - M[F00] = M[F11] = M[F22] = 1; - mA1 = mA2 = mA3 = 0; - bAsOK = kTRUE; -} - -void ZTrans::SetTrans(const ZTrans& t, Bool_t copyAngles) -{ - memcpy(M, t.M, sizeof(M)); - if (copyAngles && t.bAsOK) { - bAsOK = kTRUE; - mA1 = t.mA1; mA2 = t.mA2; mA3 = t.mA3; - } else { - bAsOK = kFALSE; - } -} - -void ZTrans::SetFromArray(const Double_t arr[16]) -{ - for(Int_t i=0; i<16; ++i) M[i] = arr[i]; - bAsOK = false; -} - -void ZTrans::SetFromArray(const Float_t arr[16]) -{ - for(Int_t i=0; i<16; ++i) M[i] = arr[i]; - bAsOK = false; -} - -void ZTrans::SetupRotation(Int_t i, Int_t j, Double_t f) -{ - // Setup the matrix as an elementary rotation. - // Optimized versions of left/right multiplication with an elementary - // rotation matrix are implemented in RotatePF/RotateLF. - // Expects identity matrix. - - if(i == j) return; - ZTrans& M = *this; - M(i,i) = M(j,j) = TMath::Cos(f); - Double_t s = TMath::Sin(f); - M(i,j) = -s; M(j,i) = s; - bAsOK = kFALSE; -} - -/**************************************************************************/ - -// OrtoNorm3 and Invert are near the bottom. - -/**************************************************************************/ - -void ZTrans::MultLeft(const ZTrans& t) -{ - Double_t B[4]; - Double_t* C = M; - for(int c=0; c<4; ++c, C+=4) { - const Double_t* T = t.M; - for(int r=0; r<4; ++r, ++T) - B[r] = T[0]*C[0] + T[4]*C[1] + T[8]*C[2] + T[12]*C[3]; - C[0] = B[0]; C[1] = B[1]; C[2] = B[2]; C[3] = B[3]; - } - bAsOK = kFALSE; -} - -void ZTrans::MultRight(const ZTrans& t) -{ - Double_t B[4]; - Double_t* C = M; - for(int r=0; r<4; ++r, ++C) { - const Double_t* T = t.M; - for(int c=0; c<4; ++c, T+=4) - B[c] = C[0]*T[0] + C[4]*T[1] + C[8]*T[2] + C[12]*T[3]; - C[0] = B[0]; C[4] = B[1]; C[8] = B[2]; C[12] = B[3]; - } - bAsOK = kFALSE; -} - -ZTrans ZTrans::operator*(const ZTrans& t) -{ - ZTrans b(*this); - b.MultRight(t); - return b; -} - -/**************************************************************************/ - -void ZTrans::TransposeRotationPart() -{ - Double_t x; - x = M[F01]; M[F01] = M[F10]; M[F10] = x; - x = M[F02]; M[F02] = M[F20]; M[F20] = x; - x = M[F12]; M[F12] = M[F21]; M[F21] = x; - bAsOK = false; -} - -/**************************************************************************/ -// Move & Rotate -/**************************************************************************/ - -void ZTrans::MoveLF(Int_t ai, Double_t amount) -{ - const Double_t *C = M + 4*--ai; - M[F03] += amount*C[0]; M[F13] += amount*C[1]; M[F23] += amount*C[2]; -} - -void ZTrans::Move3LF(Double_t x, Double_t y, Double_t z) -{ - M[F03] += x*M[0] + y*M[4] + z*M[8]; - M[F13] += x*M[1] + y*M[5] + z*M[9]; - M[F23] += x*M[2] + y*M[6] + z*M[10]; -} - -void ZTrans::RotateLF(Int_t i1, Int_t i2, Double_t amount) -{ - // Rotate in local frame. Does optimised version of MultRight. - - if(i1 == i2) return; - // Algorithm: ZTrans a; a.SetupRotation(i1, i2, amount); MultRight(a); - // Optimized version: - const Double_t cos = TMath::Cos(amount), sin = TMath::Sin(amount); - Double_t b1, b2; - Double_t* C = M; - --i1 <<= 2; --i2 <<= 2; // column major - for(int r=0; r<4; ++r, ++C) { - b1 = cos*C[i1] + sin*C[i2]; - b2 = cos*C[i2] - sin*C[i1]; - C[i1] = b1; C[i2] = b2; - } - bAsOK = kFALSE; -} - -/**************************************************************************/ - -void ZTrans::MovePF(Int_t ai, Double_t amount) -{ - M[F03 + --ai] += amount; -} - -void ZTrans::Move3PF(Double_t x, Double_t y, Double_t z) -{ - M[F03] += x; - M[F13] += y; - M[F23] += z; -} - -void ZTrans::RotatePF(Int_t i1, Int_t i2, Double_t amount) -{ - // Rotate in parent frame. Does optimised version of MultLeft. - - if(i1 == i2) return; - // Algorithm: ZTrans a; a.SetupRotation(i1, i2, amount); MultLeft(a); - - // Optimized version: - const Double_t cos = TMath::Cos(amount), sin = TMath::Sin(amount); - Double_t b1, b2; - Double_t* C = M; - --i1; --i2; - for(int c=0; c<4; ++c, C+=4) { - b1 = cos*C[i1] - sin*C[i2]; - b2 = cos*C[i2] + sin*C[i1]; - C[i1] = b1; C[i2] = b2; - } - bAsOK = kFALSE; -} - -/**************************************************************************/ - -void ZTrans::Move(const ZTrans& a, Int_t ai, Double_t amount) -{ - const Double_t* A = a.M + 4*--ai; - M[F03] += amount*A[0]; - M[F13] += amount*A[1]; - M[F23] += amount*A[2]; -} - -void ZTrans::Move3(const ZTrans& a, Double_t x, Double_t y, Double_t z) -{ - const Double_t* A = a.M; - M[F03] += x*A[F00] + y*A[F01] + z*A[F02]; - M[F13] += x*A[F10] + y*A[F11] + z*A[F12]; - M[F23] += x*A[F20] + y*A[F21] + z*A[F22]; -} - -void ZTrans::Rotate(const ZTrans& a, Int_t i1, Int_t i2, Double_t amount) -{ - if(i1 == i2) return; - ZTrans X(a); - X.Invert(); - MultLeft(X); - RotatePF(i1, i2, amount); - MultLeft(a); - bAsOK = kFALSE; -} - -/**************************************************************************/ -// Base-vector interface -/**************************************************************************/ - -void ZTrans::SetBaseVec(Int_t b, Double_t x, Double_t y, Double_t z) -{ - Double_t* C = M + 4*--b; - C[0] = x; C[1] = y; C[2] = z; - bAsOK = kFALSE; -} - -void ZTrans::SetBaseVec(Int_t b, const TVector3& v) -{ - Double_t* C = M + 4*--b; - v.GetXYZ(C); - bAsOK = kFALSE; -} - -TVector3 ZTrans::GetBaseVec(Int_t b) const -{ return TVector3(&M[4*--b]); } - -void ZTrans::GetBaseVec(Int_t b, TVector3& v) const -{ - const Double_t* C = M + 4*--b; - v.SetXYZ(C[0], C[1], C[2]); -} - -/**************************************************************************/ -// Position interface -/**************************************************************************/ - -void ZTrans::SetPos(Double_t x, Double_t y, Double_t z) -{ M[F03] = x; M[F13] = y; M[F23] = z; } - -void ZTrans::SetPos(Double_t* x) -{ M[F03] = x[0]; M[F13] = x[1]; M[F23] = x[2]; } - -void ZTrans::SetPos(Float_t* x) -{ M[F03] = x[0]; M[F13] = x[1]; M[F23] = x[2]; } - -void ZTrans::SetPos(const ZTrans& t) -{ - const Double_t* T = t.M; - M[F03] = T[F03]; M[F13] = T[F13]; M[F23] = T[F23]; -} - -void ZTrans::GetPos(Double_t& x, Double_t& y, Double_t& z) const -{ x = M[F03]; y = M[F13]; z = M[F23]; } - -void ZTrans::GetPos(Double_t* x) const -{ x[0] = M[F03]; x[1] = M[F13]; x[2] = M[F23]; } - -void ZTrans::GetPos(Float_t* x) const -{ x[0] = M[F03]; x[1] = M[F13]; x[2] = M[F23]; } - -void ZTrans::GetPos(TVector3& v) const -{ v.SetXYZ(M[F03], M[F13], M[F23]); } - -TVector3 ZTrans::GetPos() const -{ return TVector3(M[F03], M[F13], M[F23]); } - -/**************************************************************************/ -// Cardan angle interface -/**************************************************************************/ - -namespace { - inline void clamp_angle(Float_t& a) { - while(a < -TMath::TwoPi()) a += TMath::TwoPi(); - while(a > TMath::TwoPi()) a -= TMath::TwoPi(); - } -} - -void ZTrans::SetRotByAngles(Float_t a1, Float_t a2, Float_t a3) -{ - // Sets Rotation part as given by angles: - // a1 around z, -a2 around y, a3 around x - clamp_angle(a1); clamp_angle(a2); clamp_angle(a3); - - Double_t A, B, C, D, E, F; - A = TMath::Cos(a3); B = TMath::Sin(a3); - C = TMath::Cos(a2); D = TMath::Sin(a2); // should be -sin(a2) for positive direction - E = TMath::Cos(a1); F = TMath::Sin(a1); - Double_t AD = A*D, BD = B*D; - - M[F00] = C*E; M[F01] = -BD*E - A*F; M[F02] = -AD*E + B*F; - M[F10] = C*F; M[F11] = -BD*F + A*E; M[F12] = -AD*F - B*E; - M[F20] = D; M[F21] = B*C; M[F22] = A*C; - - mA1 = a1; mA2 = a2; mA3 = a3; - bAsOK = true; -} - -void ZTrans::SetRotByAnyAngles(Float_t a1, Float_t a2, Float_t a3, - const Text_t* pat) -{ - // Sets Rotation part as given by angles a1, a1, a3 and pattern pat. - // Pattern consists of "XxYyZz" characters. - // eg: x means rotate about x axis, X means rotate in negative direction - // xYz -> R_x(a3) * R_y(-a2) * R_z(a1); (standard Gled representation) - // Note that angles and pattern elements have inversed order! - // - // Implements Eulerian/Cardanian angles in a uniform way. - - int n = strspn(pat, "XxYyZz"); if(n > 3) n = 3; - // Build Trans ... assign ... - Float_t a[] = { a3, a2, a1 }; - UnitRot(); - for(int i=0; i1) d=1; else if(d<-1) d=-1; // Fix numerical errors - mA2 = TMath::ASin(d); - Double_t C = TMath::Cos(mA2); - if(TMath::Abs(C) > 8.7e-6) { - mA1 = TMath::ATan2(M[F10], M[F00]); - mA3 = TMath::ATan2(M[F21]/sy, M[F22]/sz); - } else { - mA1 = TMath::ATan2(M[F10]/sx, M[F11]/sy); - mA3 = 0; - } - bAsOK = true; - } - x[0] = mA1; x[1] = mA2; x[2] = mA3; -} - -/**************************************************************************/ -// Scaling -/**************************************************************************/ - -void ZTrans::Scale(Double_t sx, Double_t sy, Double_t sz) -{ - M[F00] *= sx; M[F10] *= sx; M[F20] *= sx; - M[F01] *= sy; M[F11] *= sy; M[F21] *= sy; - M[F02] *= sz; M[F12] *= sz; M[F22] *= sz; -} - -void ZTrans::GetScale(Double_t& sx, Double_t& sy, Double_t& sz) const -{ - sx = TMath::Sqrt( M[F00]*M[F00] + M[F10]*M[F10] + M[F20]*M[F20] ); - sy = TMath::Sqrt( M[F01]*M[F01] + M[F11]*M[F11] + M[F21]*M[F21] ); - sz = TMath::Sqrt( M[F02]*M[F02] + M[F12]*M[F12] + M[F22]*M[F22] ); -} - -void ZTrans::Unscale(Double_t& sx, Double_t& sy, Double_t& sz) -{ - GetScale(sx, sy, sz); - M[F00] /= sx; M[F10] /= sx; M[F20] /= sx; - M[F01] /= sy; M[F11] /= sy; M[F21] /= sy; - M[F02] /= sz; M[F12] /= sz; M[F22] /= sz; -} - -Double_t ZTrans::Unscale() -{ - Double_t sx, sy, sz; - Unscale(sx, sy, sz); - return (sx + sy + sz)/3; -} - -/**************************************************************************/ -// Operations on vectors -/**************************************************************************/ - -void ZTrans::MultiplyIP(TVector3& v, Double_t w) const -{ - v.SetXYZ(M[F00]*v.x() + M[F01]*v.y() + M[F02]*v.z() + M[F03]*w, - M[F10]*v.x() + M[F11]*v.y() + M[F12]*v.z() + M[F13]*w, - M[F20]*v.x() + M[F21]*v.y() + M[F22]*v.z() + M[F23]*w); -} - -void ZTrans::MultiplyIP(Double_t* v, Double_t w) const -{ - Double_t r[3] = { v[0], v[1], v[2] }; - v[0] = M[F00]*r[0] + M[F01]*r[1] + M[F02]*r[2] + M[F03]*w; - v[1] = M[F10]*r[0] + M[F11]*r[1] + M[F12]*r[2] + M[F13]*w; - v[2] = M[F20]*r[0] + M[F21]*r[1] + M[F22]*r[2] + M[F23]*w; -} - -void ZTrans::MultiplyIP(Float_t* v, Double_t w) const -{ - Double_t r[3] = { v[0], v[1], v[2] }; - v[0] = M[F00]*r[0] + M[F01]*r[1] + M[F02]*r[2] + M[F03]*w; - v[1] = M[F10]*r[0] + M[F11]*r[1] + M[F12]*r[2] + M[F13]*w; - v[2] = M[F20]*r[0] + M[F21]*r[1] + M[F22]*r[2] + M[F23]*w; -} - -TVector3 ZTrans::Multiply(const TVector3& v, Double_t w) const -{ - return TVector3(M[F00]*v.x() + M[F01]*v.y() + M[F02]*v.z() + M[F03]*w, - M[F10]*v.x() + M[F11]*v.y() + M[F12]*v.z() + M[F13]*w, - M[F20]*v.x() + M[F21]*v.y() + M[F22]*v.z() + M[F23]*w); -} - -void ZTrans::Multiply(const Double_t *vin, Double_t* vout, Double_t w) const -{ - vout[0] = M[F00]*vin[0] + M[F01]*vin[1] + M[F02]*vin[2] + M[F03]*w; - vout[1] = M[F10]*vin[0] + M[F11]*vin[1] + M[F12]*vin[1] + M[F13]*w; - vout[2] = M[F20]*vin[0] + M[F21]*vin[1] + M[F22]*vin[1] + M[F23]*w; -} - -void ZTrans::RotateIP(TVector3& v) const -{ - v.SetXYZ(M[F00]*v.x() + M[F01]*v.y() + M[F02]*v.z(), - M[F10]*v.x() + M[F11]*v.y() + M[F12]*v.z(), - M[F20]*v.x() + M[F21]*v.y() + M[F22]*v.z()); -} - -TVector3 ZTrans::Rotate(const TVector3& v) const -{ - return TVector3(M[F00]*v.x() + M[F01]*v.y() + M[F02]*v.z(), - M[F10]*v.x() + M[F11]*v.y() + M[F12]*v.z(), - M[F20]*v.x() + M[F21]*v.y() + M[F22]*v.z()); -} - -/**************************************************************************/ -// Normalization, ortogonalization -/**************************************************************************/ - -Double_t ZTrans::norm3_column(Int_t col) -{ - Double_t* C = M + 4*--col; - const Double_t l = TMath::Sqrt(C[0]*C[0] + C[1]*C[1] + C[2]*C[2]); - C[0] /= l; C[1] /= l; C[2] /= l; - return l; -} - -Double_t ZTrans::orto3_column(Int_t col, Int_t ref) -{ - Double_t* C = M + 4*--col; - Double_t* R = M + 4*--ref; - const Double_t dp = C[0]*R[0] + C[1]*R[1] + C[2]*R[2]; - C[0] -= R[0]*dp; C[1] -= R[1]*dp; C[2] -= R[2]*dp; - return dp; -} - -void ZTrans::OrtoNorm3() -{ - norm3_column(1); - orto3_column(2,1); norm3_column(2); - M[F02] = M[F10]*M[F21] - M[F11]*M[F20]; - M[F12] = M[F20]*M[F01] - M[F21]*M[F00]; - M[F22] = M[F00]*M[F11] - M[F01]*M[F10]; - // cross-product faster. - // orto3_column(3,1); orto3_column(3,2); norm3_column(3); -} - -/**************************************************************************/ -// Inversion -/**************************************************************************/ - -Double_t ZTrans::Invert() -{ - // Copied from ROOT's TMatrixFCramerInv. - - static const Exc_t _eh("ZTrans::Invert "); - - // Find all NECESSARY 2x2 dets: (18 of them) - const Double_t det2_12_01 = M[F10]*M[F21] - M[F11]*M[F20]; - const Double_t det2_12_02 = M[F10]*M[F22] - M[F12]*M[F20]; - const Double_t det2_12_03 = M[F10]*M[F23] - M[F13]*M[F20]; - const Double_t det2_12_13 = M[F11]*M[F23] - M[F13]*M[F21]; - const Double_t det2_12_23 = M[F12]*M[F23] - M[F13]*M[F22]; - const Double_t det2_12_12 = M[F11]*M[F22] - M[F12]*M[F21]; - const Double_t det2_13_01 = M[F10]*M[F31] - M[F11]*M[F30]; - const Double_t det2_13_02 = M[F10]*M[F32] - M[F12]*M[F30]; - const Double_t det2_13_03 = M[F10]*M[F33] - M[F13]*M[F30]; - const Double_t det2_13_12 = M[F11]*M[F32] - M[F12]*M[F31]; - const Double_t det2_13_13 = M[F11]*M[F33] - M[F13]*M[F31]; - const Double_t det2_13_23 = M[F12]*M[F33] - M[F13]*M[F32]; - const Double_t det2_23_01 = M[F20]*M[F31] - M[F21]*M[F30]; - const Double_t det2_23_02 = M[F20]*M[F32] - M[F22]*M[F30]; - const Double_t det2_23_03 = M[F20]*M[F33] - M[F23]*M[F30]; - const Double_t det2_23_12 = M[F21]*M[F32] - M[F22]*M[F31]; - const Double_t det2_23_13 = M[F21]*M[F33] - M[F23]*M[F31]; - const Double_t det2_23_23 = M[F22]*M[F33] - M[F23]*M[F32]; - - // Find all NECESSARY 3x3 dets: (16 of them) - const Double_t det3_012_012 = M[F00]*det2_12_12 - M[F01]*det2_12_02 + M[F02]*det2_12_01; - const Double_t det3_012_013 = M[F00]*det2_12_13 - M[F01]*det2_12_03 + M[F03]*det2_12_01; - const Double_t det3_012_023 = M[F00]*det2_12_23 - M[F02]*det2_12_03 + M[F03]*det2_12_02; - const Double_t det3_012_123 = M[F01]*det2_12_23 - M[F02]*det2_12_13 + M[F03]*det2_12_12; - const Double_t det3_013_012 = M[F00]*det2_13_12 - M[F01]*det2_13_02 + M[F02]*det2_13_01; - const Double_t det3_013_013 = M[F00]*det2_13_13 - M[F01]*det2_13_03 + M[F03]*det2_13_01; - const Double_t det3_013_023 = M[F00]*det2_13_23 - M[F02]*det2_13_03 + M[F03]*det2_13_02; - const Double_t det3_013_123 = M[F01]*det2_13_23 - M[F02]*det2_13_13 + M[F03]*det2_13_12; - const Double_t det3_023_012 = M[F00]*det2_23_12 - M[F01]*det2_23_02 + M[F02]*det2_23_01; - const Double_t det3_023_013 = M[F00]*det2_23_13 - M[F01]*det2_23_03 + M[F03]*det2_23_01; - const Double_t det3_023_023 = M[F00]*det2_23_23 - M[F02]*det2_23_03 + M[F03]*det2_23_02; - const Double_t det3_023_123 = M[F01]*det2_23_23 - M[F02]*det2_23_13 + M[F03]*det2_23_12; - const Double_t det3_123_012 = M[F10]*det2_23_12 - M[F11]*det2_23_02 + M[F12]*det2_23_01; - const Double_t det3_123_013 = M[F10]*det2_23_13 - M[F11]*det2_23_03 + M[F13]*det2_23_01; - const Double_t det3_123_023 = M[F10]*det2_23_23 - M[F12]*det2_23_03 + M[F13]*det2_23_02; - const Double_t det3_123_123 = M[F11]*det2_23_23 - M[F12]*det2_23_13 + M[F13]*det2_23_12; - - // Find the 4x4 det: - const Double_t det = M[F00]*det3_123_123 - M[F01]*det3_123_023 + - M[F02]*det3_123_013 - M[F03]*det3_123_012; - - if(det == 0) { - throw(_eh + "matrix is singular."); - } - - const Double_t oneOverDet = 1.0/det; - const Double_t mn1OverDet = - oneOverDet; - - M[F00] = det3_123_123 * oneOverDet; - M[F01] = det3_023_123 * mn1OverDet; - M[F02] = det3_013_123 * oneOverDet; - M[F03] = det3_012_123 * mn1OverDet; - - M[F10] = det3_123_023 * mn1OverDet; - M[F11] = det3_023_023 * oneOverDet; - M[F12] = det3_013_023 * mn1OverDet; - M[F13] = det3_012_023 * oneOverDet; - - M[F20] = det3_123_013 * oneOverDet; - M[F21] = det3_023_013 * mn1OverDet; - M[F22] = det3_013_013 * oneOverDet; - M[F23] = det3_012_013 * mn1OverDet; - - M[F30] = det3_123_012 * mn1OverDet; - M[F31] = det3_023_012 * oneOverDet; - M[F32] = det3_013_012 * mn1OverDet; - M[F33] = det3_012_012 * oneOverDet; - - bAsOK = kFALSE; - return det; -} - -/**************************************************************************/ - -void ZTrans::Streamer(TBuffer &R__b) -{ - // Stream an object of class ZTrans. - - if (R__b.IsReading()) { - ZTrans::Class()->ReadBuffer(R__b, this); - bAsOK = kFALSE; - } else { - ZTrans::Class()->WriteBuffer(R__b, this); - } -} - -/**************************************************************************/ -/**************************************************************************/ - -void ZTrans::Print(Option_t* /*option*/) const -{ - const Double_t* C = M; - for(Int_t i=0; i<4; ++i, ++C) - printf("%8.3f %8.3f %8.3f | %8.3f\n", C[0], C[4], C[8], C[12]); -} - -#include - -ostream& Reve::operator<<(ostream& s, const ZTrans& t) { - s.setf(std::ios::fixed, std::ios::floatfield); - s.precision(3); - for(Int_t i=1; i<=4; i++) - for(Int_t j=1; j<=4; j++) - s << t(i,j) << ((j==4) ? "\n" : "\t"); - return s; -} - -/**************************************************************************/ -// Reve stuff -/**************************************************************************/ - -#include -#include - -void ZTrans::SetFrom(Double_t* carr) -{ - fUseTrans = kTRUE; - memcpy(M, carr, 16*sizeof(Double_t)); - bAsOK = kFALSE; -} - -void ZTrans::SetFrom(const TGeoMatrix& mat) -{ - fUseTrans = kTRUE; - const Double_t *r = mat.GetRotationMatrix(); - const Double_t *t = mat.GetTranslation(); - const Double_t *s = mat.GetScale(); - Double_t *m = M; - m[0] = r[0]*s[0]; m[1] = r[3]*s[0]; m[2] = r[6]*s[0]; m[3] = 0; m += 4; - m[0] = r[1]*s[1]; m[1] = r[4]*s[1]; m[2] = r[7]*s[1]; m[3] = 0; m += 4; - m[0] = r[2]*s[2]; m[1] = r[5]*s[2]; m[2] = r[8]*s[2]; m[3] = 0; m += 4; - m[0] = t[0]; m[1] = t[1]; m[2] = t[2]; m[3] = 1; - bAsOK = kFALSE; -} - -void ZTrans::SetGeoHMatrix(TGeoHMatrix& mat) -{ - Double_t *r = mat.GetRotationMatrix(); - Double_t *t = mat.GetTranslation(); - Double_t *s = mat.GetScale(); - if (fUseTrans) - { - mat.SetBit(TGeoMatrix::kGeoGenTrans); - Double_t *m = M; - GetScale(s[0], s[1], s[2]); - r[0] = m[0]/s[0]; r[3] = m[1]/s[0]; r[6] = m[2]/s[0]; m += 4; - r[1] = m[0]/s[1]; r[4] = m[1]/s[1]; r[7] = m[2]/s[1]; m += 4; - r[2] = m[0]/s[2]; r[5] = m[1]/s[2]; r[8] = m[2]/s[2]; m += 4; - t[0] = m[0]; t[1] = m[1]; t[2] = m[2]; - } else { - mat.ResetBit(TGeoMatrix::kGeoGenTrans); - r[0] = 1; r[3] = 0; r[6] = 0; - r[1] = 0; r[4] = 1; r[7] = 0; - r[2] = 0; r[5] = 0; r[8] = 1; - s[0] = s[1] = s[2] = 1; - t[0] = t[1] = t[2] = 0; - } -} - -void ZTrans::SetBuffer3D(TBuffer3D& buff) -{ - buff.fLocalFrame = fUseTrans; - if (fUseTrans) { - // In phys-shape ctor the rotation part is transposed, due to - // TGeo's convention for rotation matrix. So we have to transpose - // it here, also. - Double_t *B = buff.fLocalMaster; - B[0] = M[0]; B[1] = M[4]; B[2] = M[8]; B[3] = M[3]; - B[4] = M[1]; B[5] = M[5]; B[6] = M[9]; B[7] = M[7]; - B[8] = M[2]; B[9] = M[6]; B[10] = M[10]; B[11] = M[11]; - B[12] = M[12]; B[13] = M[13]; B[14] = M[14]; B[15] = M[15]; - // Otherwise this would do: - // memcpy(buff.fLocalMaster, M, 16*sizeof(Double_t)); - } -} - -Bool_t ZTrans::IsScale(Double_t low, Double_t high) const -{ - // Test if the transformation is a scale. - // To be used by ROOT TGLObject descendants that potentially need to - // use GL_NORMALIZE. - // The low/high limits are expected to be squares of acutal limits. - // - // Ideally this should be done by the TGLViewer [but is not]. - - if (!fUseTrans) return kFALSE; - Double_t s; - s = M[F00]*M[F00] + M[F10]*M[F10] + M[F20]*M[F20]; - if (s < low || s > high) return kTRUE; - s = M[F01]*M[F01] + M[F11]*M[F11] + M[F21]*M[F21]; - if (s < low || s > high) return kTRUE; - s = M[F02]*M[F02] + M[F12]*M[F12] + M[F22]*M[F22]; - if (s < low || s > high) return kTRUE; - return kFALSE; -} diff --git a/EVE/Reve/ZTrans.h b/EVE/Reve/ZTrans.h deleted file mode 100644 index 7142e1a4ac7..00000000000 --- a/EVE/Reve/ZTrans.h +++ /dev/null @@ -1,178 +0,0 @@ -// $Header$ - -// Copyright (C) 1999-2005, Matevz Tadel. All rights reserved. -// This file is part of GLED, released under GNU General Public License version 2. -// For the licensing terms see $GLEDSYS/LICENSE or http://www.gnu.org/. -// -// Taken from Gled, main changes: -// 1. Put into namespace Reve. -// 2. Remove references to ZNode. -// 3. Added bool-members fApplyTrans, fEditTrans -// 4. Added set-from-TGeoMatrix -// 5. Added method SetupBuffer3D() - -#ifndef REVE_ZTrans_H -#define REVE_ZTrans_H - -#include - -class TGeoMatrix; -class TGeoHMatrix; -class TBuffer3D; - -namespace Reve { - -/**************************************************************************/ -// ZTrans -- 3D transformation in generalised coordinates -/**************************************************************************/ - -class ZTrans : public TObject -{ - friend class ZTransSubEditor; - friend class ZTransEditor; - -protected: - Double32_t M[16]; - - mutable Float_t mA1; //! - mutable Float_t mA2; //! - mutable Float_t mA3; //! - mutable Bool_t bAsOK; //! - - // Reve - Bool_t fUseTrans; - Bool_t fEditTrans; - - Double_t norm3_column(Int_t col); - Double_t orto3_column(Int_t col, Int_t ref); - -public: - ZTrans(); - ZTrans(const ZTrans& t); - ZTrans(const Double_t arr[16]); - ZTrans(const Float_t arr[16]); - virtual ~ZTrans() {} - - // General operations - - void UnitTrans(); - void UnitRot(); - void SetTrans(const ZTrans& t, Bool_t copyAngles=kTRUE); - void SetFromArray(const Double_t arr[16]); - void SetFromArray(const Float_t arr[16]); - ZTrans& operator=(const ZTrans& t) { SetTrans(t); return *this; } - void SetupRotation(Int_t i, Int_t j, Double_t f); - - void OrtoNorm3(); - Double_t Invert(); - - void MultLeft(const ZTrans& t); - void MultRight(const ZTrans& t); - void operator*=(const ZTrans& t) { MultRight(t); } - - void TransposeRotationPart(); - - ZTrans operator*(const ZTrans& t); - - // Move & Rotate - - void MoveLF(Int_t ai, Double_t amount); - void Move3LF(Double_t x, Double_t y, Double_t z); - void RotateLF(Int_t i1, Int_t i2, Double_t amount); - - void MovePF(Int_t ai, Double_t amount); - void Move3PF(Double_t x, Double_t y, Double_t z); - void RotatePF(Int_t i1, Int_t i2, Double_t amount); - - void Move(const ZTrans& a, Int_t ai, Double_t amount); - void Move3(const ZTrans& a, Double_t x, Double_t y, Double_t z); - void Rotate(const ZTrans& a, Int_t i1, Int_t i2, Double_t amount); - - // Element access - - Double_t* Array() { return M; } const Double_t* Array() const { return M; } - Double_t* ArrX() { return M; } const Double_t* ArrX() const { return M; } - Double_t* ArrY() { return M + 4; } const Double_t* ArrY() const { return M + 4; } - Double_t* ArrZ() { return M + 8; } const Double_t* ArrZ() const { return M + 8; } - Double_t* ArrT() { return M + 12; } const Double_t* ArrT() const { return M + 12; } - - Double_t operator[](Int_t i) const { return M[i]; } - Double_t& operator[](Int_t i) { return M[i]; } - - Double_t CM(Int_t i, Int_t j) const { return M[4*j + i]; } - Double_t& CM(Int_t i, Int_t j) { return M[4*j + i]; } - - Double_t operator()(Int_t i, Int_t j) const { return M[4*j + i - 5]; } - Double_t& operator()(Int_t i, Int_t j) { return M[4*j + i - 5]; } - - // Base-vector interface - - void SetBaseVec(Int_t b, Double_t x, Double_t y, Double_t z); - void SetBaseVec(Int_t b, const TVector3& v); - - TVector3 GetBaseVec(Int_t b) const; - void GetBaseVec(Int_t b, TVector3& v) const; - - // Position interface - - void SetPos(Double_t x, Double_t y, Double_t z); - void SetPos(Double_t* x); - void SetPos(Float_t * x); - void SetPos(const ZTrans& t); - - void GetPos(Double_t& x, Double_t& y, Double_t& z) const; - void GetPos(Double_t* x) const; - void GetPos(Float_t * x) const; - void GetPos(TVector3& v) const; - TVector3 GetPos() const; - - // Cardan angle interface - - void SetRotByAngles(Float_t a1, Float_t a2, Float_t a3); - void SetRotByAnyAngles(Float_t a1, Float_t a2, Float_t a3, const Text_t* pat); - void GetRotAngles(Float_t* x) const; - - // Scaling - - void Scale(Double_t sx, Double_t sy, Double_t sz); - void GetScale(Double_t& sx, Double_t& sy, Double_t& sz) const; - void Unscale(Double_t& sx, Double_t& sy, Double_t& sz); - Double_t Unscale(); - - - // Operations on vectors - - void MultiplyIP(TVector3& v, Double_t w=1) const; - void MultiplyIP(Double_t* v, Double_t w=1) const; - void MultiplyIP(Float_t* v, Double_t w=1) const; - TVector3 Multiply(const TVector3& v, Double_t w=1) const; - void Multiply(const Double_t *vin, Double_t* vout, Double_t w=1) const; - void RotateIP(TVector3& v) const; - TVector3 Rotate(const TVector3& v) const; - - - virtual void Print(Option_t* option = "") const; - - - // Reve stuff - - void SetFrom(Double_t* carr); - void SetFrom(const TGeoMatrix& mat); - void SetGeoHMatrix(TGeoHMatrix& mat); - void SetBuffer3D(TBuffer3D& buff); - - Bool_t GetUseTrans() const { return fUseTrans; } - void SetUseTrans(Bool_t v) { fUseTrans = v; } - Bool_t GetEditTrans() const { return fEditTrans; } - void SetEditTrans(Bool_t v) { fEditTrans = v; } - - Bool_t IsScale(Double_t low=0.9, Double_t high=1.1) const; - - ClassDef(ZTrans, 1) // Column-major 4x4 matrix for homogeneous coordinates. -}; - -ostream& operator<<(ostream& s, const ZTrans& t); - -} - -#endif diff --git a/EVE/Reve/ZTransEditor.cxx b/EVE/Reve/ZTransEditor.cxx deleted file mode 100644 index 3b33c03e4d6..00000000000 --- a/EVE/Reve/ZTransEditor.cxx +++ /dev/null @@ -1,232 +0,0 @@ -/************************************************************************** - * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * - * * - * Author: The ALICE Off-line Project. * - * Contributors are mentioned in the code where appropriate. * - * * - * Permission to use, copy, modify and distribute this software and its * - * documentation strictly for non-commercial purposes is hereby granted * - * without fee, provided that the above copyright notice appears in all * - * copies and that both the copyright notice and this permission notice * - * appear in the supporting documentation. The authors make no claims * - * about the suitability of this software for any purpose. It is * - * provided "as is" without express or implied warranty. * - **************************************************************************/ - -/* $Id$ */ - -#include "ZTransEditor.h" -#include -#include - -#include -#include - -#include - - -using namespace Reve; - -//______________________________________________________________________ -// ZTransSubEditor -// - -ClassImp(ZTransSubEditor) - -ZTransSubEditor::ZTransSubEditor(TGWindow* p) : - TGVerticalFrame(p), - fTrans (0), - - fTopHorFrame(0), - - fUseTrans(0), - fEditTrans(0), - - fEditTransFrame(0), - - fPos(0), - fRot(0), - fScale(0), - - fAutoUpdate(0), - fUpdate(0) -{ - // --- Top controls - - fTopHorFrame = new TGHorizontalFrame(this); - - fUseTrans = new TGCheckButton(fTopHorFrame, "UseTrans"); - fTopHorFrame->AddFrame(fUseTrans, new TGLayoutHints(kLHintsLeft, 1,2,0,0)); - fUseTrans->Connect("Toggled(Bool_t)", "Reve::ZTransSubEditor", this, "DoUseTrans()"); - fEditTrans = new TGCheckButton(fTopHorFrame, "EditTrans"); - fTopHorFrame->AddFrame(fEditTrans, new TGLayoutHints(kLHintsLeft, 2,1,0,0)); - fEditTrans->Connect("Toggled(Bool_t)"," Reve::ZTransSubEditor", this, "DoEditTrans()"); - - AddFrame(fTopHorFrame, new TGLayoutHints(kLHintsTop, 0,0,2,1)); - - - // --- Trans edit part - - fEditTransFrame = new TGVerticalFrame(this); - - fPos = new RGTriVecValuator(fEditTransFrame, "Pos", 160, 20); - fPos->SetLabelWidth(17); - fPos->SetNELength(6); - fPos->Build(kFALSE, "x", "y", "z"); - fPos->SetLimits(-1e5, 1e5, TGNumberFormat::kNESRealThree); - fEditTransFrame->AddFrame(fPos, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 0,0,0,0)); - - fRot = new RGTriVecValuator(fEditTransFrame, "Rot", 160, 20); - fRot->SetLabelWidth(17); - fRot->SetNELength(6); - fRot->Build(kFALSE, "Rz", "RY", "Rx"); - fRot->SetLimits(-360, 360, TGNumberFormat::kNESRealOne); - fEditTransFrame->AddFrame(fRot, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 0,0,0,0)); - - fScale = new RGTriVecValuator(fEditTransFrame, "Scale", 160, 20); - fScale->SetLabelWidth(17); - fScale->SetNELength(6); - fScale->Build(kFALSE, "Sx", "Sy", "Sz"); - fScale->SetLimits(1e-2, 1e2, TGNumberFormat::kNESRealTwo); - fEditTransFrame->AddFrame(fScale, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 0,0,0,0)); - - fPos ->Connect("ValueSet()", "Reve::ZTransSubEditor", this, "DoTransChanged()"); - fRot ->Connect("ValueSet()", "Reve::ZTransSubEditor", this, "DoTransChanged()"); - fScale->Connect("ValueSet()", "Reve::ZTransSubEditor", this, "DoTransChanged()"); - - { - TGHorizontalFrame* hframe = new TGHorizontalFrame(fEditTransFrame); - - fAutoUpdate = new TGCheckButton(hframe, "AutoUpdate"); - hframe->AddFrame(fAutoUpdate, new TGLayoutHints(kLHintsLeft, 1,10,1,1)); - fUpdate = new TGTextButton(hframe, "Update"); - hframe->AddFrame(fUpdate, new TGLayoutHints(kLHintsLeft | kLHintsExpandX, 5,5,1,1)); - fUpdate->Connect("Clicked()", "Reve::ZTransSubEditor", this, "TransChanged()"); - - fEditTransFrame->AddFrame(hframe, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 0,0,4,0)); - } - - AddFrame(fEditTransFrame, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 0,0,1,2)); -} - -/**************************************************************************/ - -void ZTransSubEditor::SetDataFromTrans(ZTrans* t) -{ - fTrans = t; - - fUseTrans ->SetState(fTrans->fUseTrans ? kButtonDown : kButtonUp); - fEditTrans->SetState(fTrans->fEditTrans ? kButtonDown : kButtonUp); - if (fTrans->fEditTrans) - fEditTransFrame->MapWindow(); - else - fEditTransFrame->UnmapWindow(); - ((TGMainFrame*)fEditTransFrame->GetMainFrame())->Layout(); - - fPos->SetValues(fTrans->ArrT()); - Float_t a[3]; - fTrans->GetRotAngles(a); - a[0] *= TMath::RadToDeg(); - a[1] *= TMath::RadToDeg(); - a[2] *= TMath::RadToDeg(); - fRot->SetValues(a); - Double_t x, y, z; - fTrans->GetScale(x, y, z); - fScale->SetValues(x, y, z); -} - -void ZTransSubEditor::SetTransFromData() -{ - Double_t v[3]; - fTrans->UnitTrans(); - fRot->GetValues(v); - fTrans->SetRotByAngles(v[0]*TMath::DegToRad(), v[1]*TMath::DegToRad(), v[2]*TMath::DegToRad()); - fPos->GetValues(v); - fTrans->SetPos(v); - fScale->GetValues(v); - fTrans->Scale(v[0], v[1], v[2]); -} - -/**************************************************************************/ - -void ZTransSubEditor::UseTrans() -{ - Emit("UseTrans()"); -} - -void ZTransSubEditor::TransChanged() -{ - SetTransFromData(); - Emit("TransChanged()"); -} - -/**************************************************************************/ - -void ZTransSubEditor::DoUseTrans() -{ - fTrans->SetUseTrans(fUseTrans->IsOn()); - UseTrans(); -} - -void ZTransSubEditor::DoEditTrans() -{ - fTrans->SetEditTrans(fEditTrans->IsOn()); - if (fEditTrans->IsOn()) - fEditTransFrame->MapWindow(); - else - fEditTransFrame->UnmapWindow(); - ((TGMainFrame*)fEditTransFrame->GetMainFrame())->Layout(); -} - -void ZTransSubEditor::DoTransChanged() -{ - if (fAutoUpdate->IsOn()) - TransChanged(); -} - -/**************************************************************************/ -/**************************************************************************/ -/**************************************************************************/ - -//______________________________________________________________________ -// ZTransEditor -// - -ClassImp(ZTransEditor) - -ZTransEditor::ZTransEditor(const TGWindow *p, Int_t width, Int_t height, - UInt_t options, Pixel_t back) : - TGedFrame(p, width, height, options | kVerticalFrame, back), - fM(0) - // Initialize widget pointers to 0 -{ - MakeTitle("ZTrans"); - - // Create widgets - // fXYZZ = new TGSomeWidget(this, ...); - // AddFrame(fXYZZ, new TGLayoutHints(...)); - // fXYZZ->Connect("SignalName()", "Reve::ZTransEditor", this, "DoXYZZ()"); -} - -ZTransEditor::~ZTransEditor() -{} - -/**************************************************************************/ - -void ZTransEditor::SetModel(TObject* obj) -{ - fM = dynamic_cast(obj); - - // Set values of widgets - // fXYZZ->SetValue(fM->GetXYZZ()); -} - -/**************************************************************************/ - -// Implements callback/slot methods - -// void ZTransEditor::DoXYZZ() -// { -// fM->SetXYZZ(fXYZZ->GetValue()); -// Update(); -// } diff --git a/EVE/Reve/ZTransEditor.h b/EVE/Reve/ZTransEditor.h deleted file mode 100644 index 5e1b04fbf8a..00000000000 --- a/EVE/Reve/ZTransEditor.h +++ /dev/null @@ -1,75 +0,0 @@ -// $Header$ - -#ifndef REVE_ZTransEditor_H -#define REVE_ZTransEditor_H - -#include - -class TGCheckButton; -class TGTextButton; - -namespace Reve { - -class ZTrans; -class RGTriVecValuator; - -class ZTransSubEditor : public TGVerticalFrame -{ - ZTransSubEditor(const ZTransSubEditor&); // Not implemented - ZTransSubEditor& operator=(const ZTransSubEditor&); // Not implemented - -protected: - ZTrans *fTrans; - - TGHorizontalFrame *fTopHorFrame; - - TGCheckButton *fUseTrans; - TGCheckButton *fEditTrans; - - TGVerticalFrame *fEditTransFrame; - - RGTriVecValuator *fPos; - RGTriVecValuator *fRot; - RGTriVecValuator *fScale; - - TGCheckButton *fAutoUpdate; - TGTextButton *fUpdate; - -public: - ZTransSubEditor(TGWindow* p); - virtual ~ZTransSubEditor() {} - - void SetDataFromTrans(ZTrans* t); - void SetTransFromData(); - - void UseTrans(); //*SIGNAL* - void TransChanged(); //*SIGNAL* - - void DoUseTrans(); - void DoEditTrans(); - void DoTransChanged(); - - ClassDef(ZTransSubEditor, 0); // Sub-editor for ZTrans class. -}; - -class ZTransEditor : public TGedFrame -{ -private: - ZTransEditor(const ZTransEditor&); // Not implemented - ZTransEditor& operator=(const ZTransEditor&); // Not implemented - -protected: - ZTrans* fM; // Model object. - -public: - ZTransEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, UInt_t options = kChildFrame, Pixel_t back=GetDefaultFrameBackground()); - virtual ~ZTransEditor(); - - virtual void SetModel(TObject* obj); - - ClassDef(ZTransEditor, 1); // Editor for ZTrans class. -}; // endclass ZTransEditor - -} - -#endif diff --git a/EVE/Reve/reve_main/reve_main.cxx b/EVE/Reve/reve_main/reve_main.cxx deleted file mode 100644 index 4ba1fd2def0..00000000000 --- a/EVE/Reve/reve_main/reve_main.cxx +++ /dev/null @@ -1,13 +0,0 @@ -#include -#include - -#include - -int main(int argc, char **argv) -{ - Reve::SetupEnvironment(); - - int r = Reve::ReveManager::SpawnGuiAndRun(argc, argv); - Getlinem(kCleanUp, 0); - return r; -} diff --git a/EVE/alice-data/gentle_geo.root b/EVE/alice-data/gentle_geo.root index 78de4f828c694f291069b73c3ac61a8d1b0a53f6..65c5fdab14ee671e21b27e8d72e3ae2a8b3d6cc3 100644 GIT binary patch literal 9645 zcmbVybxfUK5G9l%#a)XQcPLh*P~81t4|jKWcPsApaCdiicPZ`;<>9dWy8mplo9t%4 zWWIYdH#29FNp9|$9D5rZM+k_KX9x%gLkI|piVw5@*zl zWTRxNXKN(l>S(WL;0Po3uNDXmX*hLc2sIH1SI7;Zm#y*wR+kMYF={9!DZEOcT8V!S zdJ^gvyG;oa@|nPXa^W&v^kGqbC<%@)f#TUcYseh;$MxbJW1LA^BM9+5;(p|bj{H;ZC@cU)nMdAU zV5Dif>dTMr+2n14pCawEX7{Ef$90H>6Qbkj*ep}lyGqlY=_-%z9?iK`Y0JTtSb0Rm zATOQ7YA;pEUO#y>S_hDJk-T-j*OX+Yfj$kYaeV{(t%=|$l`^U;k~#n+~)G9z=M|vse`C3ex2l!bm~a5Um7=kNVoDVJxBy6 z)D5d_D7NH)p`mU`>}L$!Po3z|B9oG>xjM&B6OHp)ZFf(cvPXyfFL2i-1t4s$wPlmA zX=)V=R{q|&(r?D}$VT4ySRuy1?WHyt796;$X4a*xslbFPc_??Fe{pIl@F2X3mWdv1 zzAgxSF+{lFZ=|n`kR+3#aF@l!a>nQRaQ_sSP5AN^BpHFGw{Q!RMgCew4bpHHPWgnI z1a|d}p(Wj?n=hw`{eut7uH-aU?kX-$892HyD}@p4LaYY9vu`w3h3A=S^x$_9Iv@Rl zb8Sw>1)FqNOzP>r2ql{xZQ;G>J5M{tR1Xilol__)JSlu}fDS$b5bthrsJpF;RuG>I zdR(+3-U%@6^$vf+g zBim0DmB+O;_w*YRwR;Q`ZP$PvwAb1qumk^v$hSFL%8Z_q^#p&7axv#DhIenK zWxrlzg}$qe%5s4fwP19FU~+4Rb8o*sa4jGq7h`i99DP2*&6?Xyoou-87DLEW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>`J9MAFEM5-Lv;+*39-oReRfm3Ce8hXH;Z-c3wtIc zjrYZO|EN#|rhr%UclZ6Y$`;rWwPP}HzkZU9<5D@AEYd_+BhtnwlaE{PCl0^Y$;FqE)Gi5xjXlTGeleFQ=h=#Wv1~FgZU5-n?s>nj z4-@+74Yx~~er*bvu4)|ncs*YTm`(4a@UhyAz4j&TmsQuzTSlLVm7eG?NPC}Y{lC{v z%@m$)p5ZOrFdD`F3=DGb&Eq}2R7$HbQn-iASUAvH{Vw^rkR_42)*Z zW(jaz^ef@@qbGlIbloiqU$A}D>XFQDk=%FhwdeQM=1W*s_y`O5%vP$3z$IHmmU7jE zgUqbNEsH#i32tR=%QV&L2d9E}*<~EGT0U*VeBpvCpN03lVa@dSQh0NeU2mmHYk0|A z&d8dvGfVY>s#~_UOWI=5o`4#fXRdWg zs$`;{9ttXDdhaWhqY zPSz~#cir@?zeZ)3F1IeJA$n+y&}#}b`JSZQ+FrCJJ{L5G`L~K|WDw?{Ji^pK|JBJ~k}Zs1NjdobOlKTnFLnDq+9m zGyVnj9csVc&~m8<0xO@>&Dhfik4BZ{zRC#xD!8Cx*3*YS^mvEAsCTPpb68ob#0D1! z6#QJcO42|~Udo{m*ths~$7l+@Jsm`K{&!%KB2r~z_hs&*+iMs*6d@T$jP>&pmfQ{@f4W7GI9p_rYu%w$O+0Hf* z*KtvpPWd3|UWk$0$3Wgm^@C~r?>UZm&unrAgRlOd1jh=?{sCHmIZ<%oW4By|;v`N2 zt&&kZqNWc&TRId(!FjA)nrKD@Yv%czM#_7F1o6)wlIBCsdBR0SetPalette(1, 0); - gReve->DisableRedraw(); + gEve->DisableRedraw(); - Reve::RenderElementList* l = new Reve::RenderElementList("MUONChambers"); + TEveElementList* l = new TEveElementList("MUONChambers"); l->SetTitle("MUON chambers"); l->SetMainColor(Color_t(2)); - gReve->AddRenderElement(l); + gEve->AddElement(l); for (Int_t ic = 0; ic < 14; ic++) { @@ -97,7 +97,7 @@ void MUON_display(Bool_t fromRaw = kFALSE, Bool_t showTracks = kTRUE) mucha->SetDataSource(g_muon_data); - gReve->AddRenderElement(mucha, l); + gEve->AddElement(mucha, l); } @@ -109,14 +109,14 @@ void MUON_display(Bool_t fromRaw = kFALSE, Bool_t showTracks = kTRUE) MUON_MC_tracks(); } - gReve->EnableRedraw(); - gReve->Redraw3D(kTRUE); + gEve->EnableRedraw(); + gEve->Redraw3D(kTRUE); /* - TGLViewer* view = dynamic_cast(gReve->GetGLCanvas()->GetViewer3D()); + TGLViewer* view = dynamic_cast(gEve->GetGLCanvas()->GetViewer3D()); view->ResetCamerasAfterNextUpdate(); - gReve->GetGLCanvas()->Modified(); - gReve->GetGLCanvas()->Update(); + gEve->GetGLCanvas()->Modified(); + gEve->GetGLCanvas()->Update(); */ } @@ -134,11 +134,11 @@ void MUON_tracks() { Int_t ntracks = tracks->GetEntriesFast(); //printf("Found %d tracks. \n",ntracks); - Reve::TrackList* lt = new Reve::TrackList("M-Tracks"); + TEveTrackList* lt = new TEveTrackList("M-Tracks"); lt->SetMainColor(Color_t(6)); //lt->SetMUON(); - gReve->AddRenderElement(lt); + gEve->AddElement(lt); TMatrixD smatrix(2,2); TMatrixD sums(2,1); @@ -151,7 +151,7 @@ void MUON_tracks() { Float_t zg[4] = { -1603.5, -1620.5, -1703.5, -1720.5 }; AliMUONTrack *mt; - Reve::RecTrack rt; + TEveRecTrack rt; Int_t count; for (Int_t n = 0; n < ntracks; n++) { @@ -161,11 +161,11 @@ void MUON_tracks() { rt.label = n; - Alieve::MUONTrack* track = new Alieve::MUONTrack(&rt, lt->GetRnrStyle()); + Alieve::MUONTrack* track = new Alieve::MUONTrack(&rt, lt->GetPropagator()); track->MakeMUONTrack(mt); - gReve->AddRenderElement(track, lt); + gEve->AddElement(track, lt); } @@ -187,11 +187,11 @@ void MUON_trigger_tracks() { Int_t ntracks = tracks->GetEntriesFast(); //printf("Found %d tracks. \n",ntracks); - Reve::TrackList* lt = new Reve::TrackList("MT-Tracks"); + TEveTrackList* lt = new TEveTrackList("MT-Tracks"); lt->SetMainColor(Color_t(4)); //lt->SetMUON(); - gReve->AddRenderElement(lt); + gEve->AddElement(lt); TMatrixD smatrix(2,2); TMatrixD sums(2,1); @@ -204,7 +204,7 @@ void MUON_trigger_tracks() { Float_t zg[4] = { -1603.5, -1620.5, -1703.5, -1720.5 }; AliMUONTriggerTrack *mt; - Reve::RecTrack rt; + TEveRecTrack rt; Int_t count; for (Int_t n = 0; n < ntracks; n++) { @@ -214,11 +214,11 @@ void MUON_trigger_tracks() { rt.label = n; - Alieve::MUONTrack* track = new Alieve::MUONTrack(&rt, lt->GetRnrStyle()); + Alieve::MUONTrack* track = new Alieve::MUONTrack(&rt, lt->GetPropagator()); track->MakeMUONTriggerTrack(mt); - gReve->AddRenderElement(track, lt); + gEve->AddElement(track, lt); } @@ -231,14 +231,14 @@ void MUON_ESD_tracks() { AliESDEvent* esd = Alieve::Event::AssertESD(); - Reve::TrackList* lt = new Reve::TrackList("ESD-Tracks"); + TEveTrackList* lt = new TEveTrackList("ESD-Tracks"); lt->SetMainColor(Color_t(6)); //lt->SetMUON(); - gReve->AddRenderElement(lt); + gEve->AddElement(lt); AliESDMuonTrack *mt; - Reve::RecTrack rt; + TEveRecTrack rt; Int_t nMuonTracks = esd->GetNumberOfMuonTracks(); for (Int_t n = 0; n < nMuonTracks; n++) { @@ -246,11 +246,11 @@ void MUON_ESD_tracks() { rt.label = n; - Alieve::MUONTrack* track = new Alieve::MUONTrack(&rt, lt->GetRnrStyle()); + Alieve::MUONTrack* track = new Alieve::MUONTrack(&rt, lt->GetPropagator()); track->MakeESDTrack(mt); - gReve->AddRenderElement(track, lt); + gEve->AddElement(track, lt); } @@ -267,22 +267,22 @@ void MUON_Ref_tracks() { TIter next(trackRefStore->CreateIterator()); AliMUONTrack* trackRef; - Reve::TrackList* lt = new Reve::TrackList("Ref-Tracks"); + TEveTrackList* lt = new TEveTrackList("Ref-Tracks"); lt->SetMainColor(Color_t(6)); - gReve->AddRenderElement(lt); + gEve->AddElement(lt); - Reve::RecTrack rt; + TEveRecTrack rt; Int_t i = 0; while ( ( trackRef = static_cast(next()) ) ) { rt.label = i++; - Alieve::MUONTrack* track = new Alieve::MUONTrack(&rt, lt->GetRnrStyle()); + Alieve::MUONTrack* track = new Alieve::MUONTrack(&rt, lt->GetPropagator()); track->MakeRefTrack(trackRef); - gReve->AddRenderElement(track, lt); + gEve->AddElement(track, lt); } @@ -300,15 +300,15 @@ void MUON_MC_tracks() { Int_t nPrimary = stack->GetNprimary(); Int_t nTracks = stack->GetNtrack(); - Reve::TrackList* lt = new Reve::TrackList("MC-Tracks"); + TEveTrackList* lt = new TEveTrackList("MC-Tracks"); lt->SetMainColor(Color_t(6)); //lt->SetMUON(); - gReve->AddRenderElement(lt); + gEve->AddElement(lt); Int_t pdgCode; TParticle *part; - Reve::RecTrack rt; + TEveRecTrack rt; Int_t nHitTracks = g_muon_data->GetNTrackList(); Int_t index; @@ -316,7 +316,7 @@ void MUON_MC_tracks() { index = g_muon_data->GetTrack(i); if (index >= nTracks) { - cout << "Hit track index larger than number in stack!" << endl; + cout << "TEveHit track index larger than number in stack!" << endl; continue; } @@ -324,11 +324,11 @@ void MUON_MC_tracks() { if (part->P() < 0.001) continue; // skip momenta < 1.0 MeV/c rt.label = i; - Alieve::MUONTrack* track = new Alieve::MUONTrack(&rt, lt->GetRnrStyle()); + Alieve::MUONTrack* track = new Alieve::MUONTrack(&rt, lt->GetPropagator()); track->MakeMCTrack(part); - gReve->AddRenderElement(track, lt); + gEve->AddElement(track, lt); } diff --git a/EVE/alice-macros/MUON_geom.C b/EVE/alice-macros/MUON_geom.C index edf37ccc0a1..628760244c7 100644 --- a/EVE/alice-macros/MUON_geom.C +++ b/EVE/alice-macros/MUON_geom.C @@ -2,28 +2,25 @@ void MUON_geom() { - using namespace std; - TString dataPath = TString(Alieve::gEvent->GetTitle()); dataPath.Append("/geometry.root"); - gGeoManager = gReve->GetGeometry(dataPath.Data()); + gGeoManager = gEve->GetGeometry(dataPath.Data()); TGeoNode *node1 = gGeoManager->GetTopVolume()->FindNode("DDIP_1"); TGeoNode *node2 = gGeoManager->GetTopVolume()->FindNode("YOUT1_1"); TGeoNode *node3 = gGeoManager->GetTopVolume()->FindNode("YOUT2_1"); - Reve::GeoTopNodeRnrEl* re1 = new Reve::GeoTopNodeRnrEl(gGeoManager,node1); + TEveGeoTopNode* re1 = new TEveGeoTopNode(gGeoManager,node1); re1->UseNodeTrans(); - gReve->AddGlobalRenderElement(re1); + gEve->AddGlobalElement(re1); - Reve::GeoTopNodeRnrEl* re2 = new Reve::GeoTopNodeRnrEl(gGeoManager,node2); + TEveGeoTopNode* re2 = new TEveGeoTopNode(gGeoManager,node2); re2->UseNodeTrans(); - gReve->AddGlobalRenderElement(re2); + gEve->AddGlobalElement(re2); - Reve::GeoTopNodeRnrEl* re3 = new Reve::GeoTopNodeRnrEl(gGeoManager,node3); + TEveGeoTopNode* re3 = new TEveGeoTopNode(gGeoManager,node3); re3->UseNodeTrans(); - gReve->AddGlobalRenderElement(re3); - - gReve->Redraw3D(kTRUE); + gEve->AddGlobalElement(re3); + gEve->Redraw3D(kTRUE); } diff --git a/EVE/alice-macros/MUON_geomAll.C b/EVE/alice-macros/MUON_geomAll.C index 29baf84c817..1f92d040628 100644 --- a/EVE/alice-macros/MUON_geomAll.C +++ b/EVE/alice-macros/MUON_geomAll.C @@ -7,13 +7,13 @@ void MUON_geomAll() TString dataPath = TString(Alieve::gEvent->GetTitle()); dataPath.Append("/geometry.root"); - gGeoManager = gReve->GetGeometry(dataPath.Data()); + gGeoManager = gEve->GetGeometry(dataPath.Data()); - Reve::GeoTopNodeRnrEl* topn_re = new Reve::GeoTopNodeRnrEl + TEveGeoTopNode* topn_re = new TEveGeoTopNode (gGeoManager, gGeoManager->GetTopNode()); - gReve->AddGlobalRenderElement(topn_re); + gEve->AddGlobalElement(topn_re); - gReve->Redraw3D(kTRUE); + gEve->Redraw3D(kTRUE); } diff --git a/EVE/alice-macros/MUON_trigger_info.C b/EVE/alice-macros/MUON_trigger_info.C index 055fff1bac1..a2979d15b5d 100644 --- a/EVE/alice-macros/MUON_trigger_info.C +++ b/EVE/alice-macros/MUON_trigger_info.C @@ -27,7 +27,7 @@ void MUON_trigger_info(Int_t label) { cout << endl; cout << ">>>>>#########################################################################################################################" << endl; cout << endl; - cout << " Track number " << label << endl; + cout << " TEveTrack number " << label << endl; cout << endl; AliMUONTrackParam *mtp = (AliMUONTrackParam*)mt->GetTrackParamAtVertex(); Float_t pt = TMath::Sqrt(mtp->Px()*mtp->Px()+mtp->Py()*mtp->Py()); diff --git a/EVE/alice-macros/NLT_test.C b/EVE/alice-macros/NLT_test.C index 2d42b6e1e0f..364740aff1e 100644 --- a/EVE/alice-macros/NLT_test.C +++ b/EVE/alice-macros/NLT_test.C @@ -1,27 +1,25 @@ -Reve::NLTProjector* NLT_test(Reve::RenderElement* top=0) +TEveProjectionManager* NLT_test(TEveElement* top=0) { - using namespace Reve; + TEveScene* s = gEve->SpawnNewScene("Projected Event"); + gEve->GetDefViewer()->AddScene(s); - Scene* s = gReve->SpawnNewScene("Projected Event"); - gReve->GetDefViewer()->AddScene(s); - - TGLViewer* v = (TGLViewer *)gReve->GetGLViewer(); + TGLViewer* v = (TGLViewer *)gEve->GetGLViewer(); v->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); TGLCameraMarkupStyle* mup = v->GetCameraMarkup(); if(mup) mup->SetShow(kFALSE); - NLTProjector* p = new NLTProjector; - p->SetProjection(NLTProjection::PT_RhoZ, 0.01); + TEveProjectionManager* p = new TEveProjectionManager; + p->SetProjection(TEveProjection::kPT_RhoZ, 0.01); - gReve->AddToListTree(p, kTRUE); - gReve->AddRenderElement(p, s); + gEve->AddToListTree(p, kTRUE); + gEve->AddElement(p, s); - top = gReve->GetCurrentEvent(); + top = gEve->GetCurrentEvent(); if (top) p->ImportElements(top); - gReve->Redraw3D(kTRUE); + gEve->Redraw3D(kTRUE); return p; } diff --git a/EVE/alice-macros/NLT_trackcount_init.C b/EVE/alice-macros/NLT_trackcount_init.C index 136d9bb1c83..a44263b199d 100644 --- a/EVE/alice-macros/NLT_trackcount_init.C +++ b/EVE/alice-macros/NLT_trackcount_init.C @@ -1,49 +1,49 @@ -namespace Reve +namespace TEveUtil { -class NLTProjector; -class GeoShapeRnrEl; +class TEveProjectionManager; +class TEveGeoShape; class RnrElement*; } -Reve::NLTProjector * proj = 0; -Reve::GeoShapeRnrEl * geom = 0; +TEveProjectionManager * proj = 0; +TEveGeoShape * geom = 0; void NLT_trackcount_init() { - Reve::LoadMacro("alieve_init.C"); + TEveUtil::LoadMacro("alieve_init.C"); alieve_init(".", -1); - Reve::LoadMacro("geom_gentle.C"); + TEveUtil::LoadMacro("geom_gentle.C"); - Reve::LoadMacro("primary_vertex.C"); - Reve::LoadMacro("esd_tracks.C"); - Reve::LoadMacro("its_clusters.C+"); - Reve::LoadMacro("tpc_clusters.C+"); + TEveUtil::LoadMacro("primary_vertex.C"); + TEveUtil::LoadMacro("esd_tracks.C"); + TEveUtil::LoadMacro("its_clusters.C+"); + TEveUtil::LoadMacro("tpc_clusters.C+"); - Reve::Viewer* nv = gReve->SpawnNewViewer("NLT Projected"); - Reve::Scene* ns = gReve->SpawnNewScene("NLT"); + TEveViewer* nv = gEve->SpawnNewViewer("NLT Projected"); + TEveScene* ns = gEve->SpawnNewScene("NLT"); nv->AddScene(ns); TGLViewer* v = nv->GetGLViewer(); v->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); TGLCameraMarkupStyle* mup = v->GetCameraMarkup(); if(mup) mup->SetShow(kFALSE); - Reve::TrackCounter* g_trkcnt = new Reve::TrackCounter("Primary Counter"); - gReve->AddToListTree(g_trkcnt, kFALSE); + TEveTrackCounter* g_trkcnt = new TEveTrackCounter("Primary Counter"); + gEve->AddToListTree(g_trkcnt, kFALSE); - Reve::NLTProjector* p = new Reve::NLTProjector; proj = p; - gReve->AddToListTree(p, kTRUE); - gReve->AddRenderElement(proj, ns); + TEveProjectionManager* p = new TEveProjectionManager; proj = p; + gEve->AddToListTree(p, kTRUE); + gEve->AddElement(proj, ns); // geometry - Reve::GeoShapeRnrEl* gg = geom_gentle(); + TEveGeoShape* gg = geom_gentle(); geom = gg; // event Alieve::gEvent->AddNewEventCommand("on_new_event();"); Alieve::gEvent->GotoEvent(0); - gReve->Redraw3D(kTRUE); + gEve->Redraw3D(kTRUE); } /**************************************************************************/ @@ -51,30 +51,30 @@ void NLT_trackcount_init() void on_new_event() { try { - Reve::PointSet* itsc = its_clusters(); + TEvePointSet* itsc = its_clusters(); itsc->SetMarkerColor(5); - Reve::PointSet* tpcc = tpc_clusters(); + TEvePointSet* tpcc = tpc_clusters(); tpcc->SetMarkerColor(4); } - catch(Reve::Exc_t& exc) { + catch(TEveException& exc) { printf("Exception loading ITS/TPC clusters: %s\n", exc.Data()); } primary_vertex(1, 1); - Reve::RenderElementList* cont = esd_tracks_vertex_cut(); + TEveElementList* cont = esd_tracks_vertex_cut(); - // Here we expect five TrackList containers. + // Here we expect five TEveTrackList containers. // First two have reasonable primaries (sigma-to-prim-vertex < 5). // Other three are almost certainly secondaries. Int_t count = 1; - Reve::TrackCounter* g_trkcnt = Reve::TrackCounter::fgInstance; + TEveTrackCounter* g_trkcnt = TEveTrackCounter::fgInstance; g_trkcnt->Reset(); g_trkcnt->SetEventId(Alieve::gEvent->GetEventId()); - Reve::RenderElement::List_i i = cont->BeginChildren(); + TEveElement::List_i i = cont->BeginChildren(); while (i != cont->EndChildren()) { - Reve::TrackList* l = dynamic_cast(*i); + TEveTrackList* l = dynamic_cast(*i); if (l != 0) { l->SetLineWidth(2); g_trkcnt->RegisterTracks(l, (count <= 2)); @@ -82,7 +82,7 @@ void on_new_event() } ++i; } - Reve::RenderElement* top = gReve->GetCurrentEvent(); + TEveElement* top = gEve->GetCurrentEvent(); proj->DestroyElements(); AliESDEvent* esd = Alieve::Event::AssertESD(); Double_t x[3]; @@ -112,10 +112,10 @@ TParticle* id(Int_t label=0, Bool_t showParents=kTRUE) } TParticle* part = stack->Particle(label); - if(part != 0) { + if (part != 0) { part->Print(); - if(showParents) { - while(part->GetMother(0) >= 0) { + if (showParents) { + while (part->GetMother(0) >= 0) { part = stack->Particle(part->GetMother(0)); part->Print(); } diff --git a/EVE/alice-macros/acorde_hits.C b/EVE/alice-macros/acorde_hits.C index 040fab42eef..c33459f01db 100644 --- a/EVE/alice-macros/acorde_hits.C +++ b/EVE/alice-macros/acorde_hits.C @@ -1,9 +1,9 @@ // $Id$ -Reve::PointSet* +TEvePointSet* acorde_hits(const char *varexp = "ACORDE.fX:ACORDE.fY:ACORDE.fZ", const char *selection = "", - Reve::RenderElement* cont = 0) + TEveElement* cont = 0) { AliRunLoader* rl = Alieve::Event::AssertRunLoader(); rl->LoadHits("ACORDE"); @@ -13,18 +13,19 @@ acorde_hits(const char *varexp = "ACORDE.fX:ACORDE.fY:ACORDE.fZ", //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT //PH on some platforms (alphalinuxgcc, solariscc5, etc.) - //PH Reve::PointSet* points = new Reve::PointSet(Form("ACORDE Hits '%s'", selection)); + //PH TEvePointSet* points = new TEvePointSet(Form("ACORDE Hits '%s'", selection)); char form[1000]; sprintf(form,"ACORDE Hits '%s'", selection); - Reve::PointSet* points = new Reve::PointSet(form); + TEvePointSet* points = new TEvePointSet(form); - TPointSelector ps(ht, points, varexp, selection); + TEvePointSelector ps(ht, points, varexp, selection); ps.Select(); - if(points->Size() == 0 && gReve->GetKeepEmptyCont() == kFALSE) { + if(points->Size() == 0 && gEve->GetKeepEmptyCont() == kFALSE) + { Warning("acorde_hits", Form("No hits match '%s'", selection)); delete points; - return 0; + return 0; } //PH points->SetTitle(Form("N=%d", points->Size())); @@ -33,11 +34,8 @@ acorde_hits(const char *varexp = "ACORDE.fX:ACORDE.fY:ACORDE.fZ", points->SetMarkerSize(.5); points->SetMarkerColor((Color_t)2); - if(cont) - gReve->AddRenderElement(cont, points); - else - gReve->AddRenderElement(points); - gReve->Redraw3D(); + gEve->AddElement(points, cont); + gEve->Redraw3D(); return points; } diff --git a/EVE/alice-macros/clusters_from_index.C b/EVE/alice-macros/clusters_from_index.C index 6521bf00ce4..b0cdb92f08a 100644 --- a/EVE/alice-macros/clusters_from_index.C +++ b/EVE/alice-macros/clusters_from_index.C @@ -1,6 +1,6 @@ // $Id$ -Reve::PointSet* clusters_from_index(Int_t index=0, Reve::RenderElement* cont=0) +TEvePointSet* clusters_from_index(Int_t index=0, TEveElement* cont=0) { AliESDEvent* esd = Alieve::Event::AssertESD(); @@ -14,7 +14,7 @@ Reve::PointSet* clusters_from_index(Int_t index=0, Reve::RenderElement* cont=0) return 0; } - Reve::PointSet* clusters = new Reve::PointSet(64); + TEvePointSet* clusters = new TEvePointSet(64); clusters->SetOwnIds(kTRUE); AliESDtrack* at = esd->GetTrack(index); @@ -34,7 +34,7 @@ Reve::PointSet* clusters_from_index(Int_t index=0, Reve::RenderElement* cont=0) clusters->SetPointId(atp); } - if(clusters->Size() == 0 && gReve->GetKeepEmptyCont() == kFALSE) { + if(clusters->Size() == 0 && gEve->GetKeepEmptyCont() == kFALSE) { Warning("clusters_from_index", Form("No clusters for index '%d'", index)); delete clusters; return 0; @@ -55,10 +55,8 @@ Reve::PointSet* clusters_from_index(Int_t index=0, Reve::RenderElement* cont=0) char tip[1000]; sprintf(tip,"N=%d", clusters->Size()); clusters->SetTitle(tip); - - using namespace Reve; - gReve->AddRenderElement(clusters); - gReve->Redraw3D(); + gEve->AddElement(clusters); + gEve->Redraw3D(); return clusters; } diff --git a/EVE/alice-macros/clusters_from_label.C b/EVE/alice-macros/clusters_from_label.C index 32868d66597..6d6505b37bb 100644 --- a/EVE/alice-macros/clusters_from_label.C +++ b/EVE/alice-macros/clusters_from_label.C @@ -1,9 +1,9 @@ // $Id$ -Reve::PointSet* clusters_from_label(Int_t label=0, Reve::RenderElement* cont=0) +TEvePointSet* clusters_from_label(Int_t label=0, TEveElement* cont=0) { AliESDEvent* esd = Alieve::Event::AssertESD(); - Reve::PointSet* clusters = new Reve::PointSet(64); + TEvePointSet* clusters = new TEvePointSet(64); clusters->SetOwnIds(kTRUE); for (Int_t n=0; nGetNumberOfTracks(); n++) @@ -28,7 +28,7 @@ Reve::PointSet* clusters_from_label(Int_t label=0, Reve::RenderElement* cont=0) } } - if(clusters->Size() == 0 && gReve->GetKeepEmptyCont() == kFALSE) { + if(clusters->Size() == 0 && gEve->GetKeepEmptyCont() == kFALSE) { Warning("clusters_from_label", Form("No clusters match label '%d'", label)); delete clusters; return 0; @@ -48,10 +48,8 @@ Reve::PointSet* clusters_from_label(Int_t label=0, Reve::RenderElement* cont=0) char tip[1000]; sprintf(tip,"N=%d", clusters->Size()); clusters->SetTitle(tip); - - using namespace Reve; - gReve->AddRenderElement(clusters, cont); - gReve->Redraw3D(); + gEve->AddElement(clusters, cont); + gEve->Redraw3D(); return clusters; } diff --git a/EVE/alice-macros/emcal_digits.C b/EVE/alice-macros/emcal_digits.C index 11451af7dbe..6e9f20b9b55 100644 --- a/EVE/alice-macros/emcal_digits.C +++ b/EVE/alice-macros/emcal_digits.C @@ -9,7 +9,7 @@ void emcal_digits() rl->LoadDigits("EMCAL"); TTree* dt = rl->GetTreeD("EMCAL", kFALSE); - gGeoManager = gReve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); + gGeoManager = gEve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); TGeoNode* node = gGeoManager->GetTopVolume()->FindNode("XEN1_1"); TGeoBBox* bbbox = (TGeoBBox*) node->GetDaughter(0) ->GetVolume()->GetShape(); @@ -17,27 +17,27 @@ void emcal_digits() TGeoBBox* sbbox = (TGeoBBox*) node->GetDaughter(10)->GetVolume()->GetShape(); sbbox->Dump(); - Reve::RenderElementList* l = new Reve::RenderElementList("EMCAL"); + TEveElementList* l = new TEveElementList("EMCAL"); l->SetTitle("Tooltip"); - gReve->AddRenderElement(l); + gEve->AddElement(l); - Reve::FrameBox* frame_big = new Reve::FrameBox(); + TEveFrameBox* frame_big = new TEveFrameBox(); frame_big->SetAABoxCenterHalfSize(0, 0, 0, bbbox->GetDX(), bbbox->GetDY(), bbbox->GetDZ()); - Reve::FrameBox* frame_sml = new Reve::FrameBox(); + TEveFrameBox* frame_sml = new TEveFrameBox(); frame_sml->SetAABoxCenterHalfSize(0, 0, 0, sbbox->GetDX(), sbbox->GetDY(), sbbox->GetDZ()); gStyle->SetPalette(1, 0); - Reve::RGBAPalette* pal = new Reve::RGBAPalette(0, 512); + TEveRGBAPalette* pal = new TEveRGBAPalette(0, 512); pal->SetLimits(0, 1024); - Reve::QuadSet* smodules[12]; + TEveQuadSet* smodules[12]; for (Int_t sm=0; sm<12; ++sm) { - Reve::QuadSet* q = new Reve::QuadSet(Form("SM %d", sm+1)); + TEveQuadSet* q = new TEveQuadSet(Form("SM %d", sm+1)); q->SetOwnIds(kTRUE); - q->Reset(Reve::QuadSet::QT_RectangleYZFixedDimX, kFALSE, 32); + q->Reset(TEveQuadSet::kQT_RectangleYZFixedDimX, kFALSE, 32); q->SetDefWidth (geom->GetPhiTileSize()); q->SetDefHeight(geom->GetEtaTileSize()); @@ -46,7 +46,7 @@ void emcal_digits() q->SetFrame(sm < 10 ? frame_big : frame_sml); q->SetPalette(pal); - gReve->AddRenderElement(q, l); + gEve->AddElement(q, l); smodules[sm] = q; } @@ -68,7 +68,7 @@ void emcal_digits() Int_t ieta = 0 ; Double_t x, y, z; - for(Int_t idig = 0; idig(digits->At(idig)); @@ -93,7 +93,7 @@ void emcal_digits() geom->RelPosCellInSModule(id, x, y, z); cout << x <<" "<< y <<" "<< z <AddQuad(y, z); q->QuadValue(amp); q->QuadId(dig); @@ -102,10 +102,10 @@ void emcal_digits() } } - for (Int_t sm=0; sm<12; ++sm) + for (Int_t sm = 0; sm < 12; ++sm) { smodules[iSupMod]->RefitPlex(); } - gReve->Redraw3D(); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/emcal_hits.C b/EVE/alice-macros/emcal_hits.C index 7e223fefa86..12af37a679f 100644 --- a/EVE/alice-macros/emcal_hits.C +++ b/EVE/alice-macros/emcal_hits.C @@ -1,9 +1,9 @@ // $Id$ -Reve::PointSet* +TEvePointSet* emcal_hits(const char *varexp = "fX:fY:fZ", const char *selection = "", - Reve::RenderElement* cont = 0) + TEveElement* cont = 0) { AliRunLoader* rl = Alieve::Event::AssertRunLoader(); rl->LoadHits("EMCAL"); @@ -13,15 +13,15 @@ emcal_hits(const char *varexp = "fX:fY:fZ", //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT //PH on some platforms (alphalinuxgcc, solariscc5, etc.) - //PH Reve::PointSet* points = new Reve::PointSet(Form("EMCAL Hits '%s'", selection)); + //PH TEvePointSet* points = new TEvePointSet(Form("EMCAL Hits '%s'", selection)); char form[1000]; sprintf(form,"EMCAL Hits '%s'", selection); - Reve::PointSet* points = new Reve::PointSet(form); + TEvePointSet* points = new TEvePointSet(form); - TPointSelector ps(ht, points, varexp, selection); + TEvePointSelector ps(ht, points, varexp, selection); ps.Select(); - if(points->Size() == 0 && gReve->GetKeepEmptyCont() == kFALSE) { + if (points->Size() == 0 && gEve->GetKeepEmptyCont() == kFALSE) { Warning("emcal_hits", Form("No hits match '%s'", selection)); delete points; return 0; @@ -33,8 +33,8 @@ emcal_hits(const char *varexp = "fX:fY:fZ", points->SetMarkerSize(.5); points->SetMarkerColor((Color_t)2); - gReve->AddRenderElement(points, cont); - gReve->Redraw3D(); + gEve->AddElement(points, cont); + gEve->Redraw3D(); return points; } diff --git a/EVE/alice-macros/esd_Cascade.C b/EVE/alice-macros/esd_Cascade.C index 12bc770977f..1cc1d31b239 100644 --- a/EVE/alice-macros/esd_Cascade.C +++ b/EVE/alice-macros/esd_Cascade.C @@ -1,18 +1,18 @@ // #include "EVE/Alieve/EventAlieve.h" -// #include "Reve/ReveManager.h" -// #include "Reve/Cascade.h" +// #include "TEveManager.h" +// #include "Cascade.h" // #include "AliESD.h" // #include "AliESDtrack.h" // #include "AliESDcascade.h" // #include "AliESDVertex.h" -// using namespace Reve; +// using namespace TEveUtil; // using namespace Alieve; -Alieve::Cascade* esd_make_cas(Reve::TrackRnrStyle* rnrStyle, AliESDVertex* primVtx, +Alieve::Cascade* esd_make_cas(TEveTrackPropagator* rnrStyle, AliESDVertex* primVtx, AliESDcascade* cas, AliESDtrack* neg, AliESDtrack* pos, AliESDtrack* bach,Int_t i) { @@ -58,16 +58,20 @@ Alieve::Cascade* esd_make_cas(Reve::TrackRnrStyle* rnrStyle, AliESDVertex* primV Alieve::CascadeList* esd_Cascade(Double_t min_pt=0.1, Double_t max_pt=100) { + printf("THIS SCRIPT DOES NOT WORK.\n" + "Alieve::Cascade classes have been temporarily removed.\n" + "They need to be cleaned up.\n"); + return; AliESDEvent* esd = Alieve::Event::AssertESD(); AliESDVertex* primVertex =(AliESDVertex*) esd->GetVertex(); Alieve::CascadeList* cont = new Alieve::CascadeList("ESD cascade"); cont->SetMainColor(Color_t(3)); // green - Reve::TrackRnrStyle* rnrStyle = cont->GetRnrStyle(); + TEveTrackPropagator* rnrStyle = cont->GetPropagator(); rnrStyle->SetMagField( esd->GetMagneticField() ); - gReve->AddRenderElement(cont); + gEve->AddElement(cont); Int_t count = 0; //for (Int_t n=0; count<3; n++) { @@ -85,7 +89,7 @@ Alieve::CascadeList* esd_Cascade(Double_t min_pt=0.1, Double_t max_pt=100) Alieve::Cascade* myCas = esd_make_cas(rnrStyle, primVertex, cas, negTr, posTr, bachTr, n); if (myCas) { - gReve->AddRenderElement(myCas, cont); + gEve->AddElement(myCas, cont); count++; } } @@ -95,7 +99,7 @@ Alieve::CascadeList* esd_Cascade(Double_t min_pt=0.1, Double_t max_pt=100) cont->UpdateItems(); cont->MakeCascades(); - gReve->Redraw3D(); + gEve->Redraw3D(); return cont; } diff --git a/EVE/alice-macros/esd_V0.C b/EVE/alice-macros/esd_V0.C index acc25609cb0..ab9f0ed552d 100644 --- a/EVE/alice-macros/esd_V0.C +++ b/EVE/alice-macros/esd_V0.C @@ -1,26 +1,26 @@ // #include "EVE/Alieve/EventAlieve.h" -// #include "Reve/ReveManager.h" -// #include "Reve/V0.h" +// #include "TEveManager.h" +// #include "V0.h" // #include "AliESD.h" // #include "AliESDtrack.h" // #include "AliESDv0.h" // #include "AliESDVertex.h" -// using namespace Reve; +// using namespace TEveUtil; // using namespace Alieve; -Alieve::V0* esd_make_v0(Reve::TrackRnrStyle* rnrStyle, AliESDVertex* primVtx, +Alieve::V0* esd_make_v0(TEveTrackPropagator* rnrStyle, AliESDVertex* primVtx, AliESDtrack* neg, AliESDtrack* pos, AliESDv0* v0, Int_t i) { if (! v0->GetOnFlyStatus()) { // v0 on fly do not have the momentum vector filled... - Reve::RecTrack rcPos; - Reve::RecTrack rcNeg; - Reve::RecV0 rcV0; + TEveRecTrack rcPos; + TEveRecTrack rcNeg; + TEveRecV0 rcV0; Double_t p[3]; v0->GetNPxPyPz(p[0], p[1], p[2]); @@ -74,16 +74,20 @@ Alieve::V0* esd_make_v0(Reve::TrackRnrStyle* rnrStyle, AliESDVertex* primVtx, Alieve::V0List* esd_V0(Double_t min_pt=0.1, Double_t max_pt=100) { + printf("THIS SCRIPT DOES NOT WORK.\n" + "Alieve::V0 classes have been temporarily removed.\n" + "They need to be cleaned up.\n"); + return; AliESDEvent* esd = Alieve::Event::AssertESD(); AliESDVertex* primVertex =(AliESDVertex*) esd->GetVertex(); Alieve::V0List* cont = new Alieve::V0List("ESD v0"); cont->SetMainColor(Color_t(3)); // green - Reve::TrackRnrStyle* rnrStyle = cont->GetRnrStyle(); + TEveTrackPropagator* rnrStyle = cont->GetPropagator(); rnrStyle->SetMagField( esd->GetMagneticField() ); - gReve->AddRenderElement(cont); + gEve->AddElement(cont); Int_t count = 0; //for (Int_t n=0; count<3; n++) { @@ -99,7 +103,7 @@ Alieve::V0List* esd_V0(Double_t min_pt=0.1, Double_t max_pt=100) Alieve::V0* myV0 = esd_make_v0(rnrStyle, primVertex, negTr,posTr, v0, n); if (myV0) { - gReve->AddRenderElement(myV0, cont); + gEve->AddElement(myV0, cont); count++; } } @@ -108,7 +112,7 @@ Alieve::V0List* esd_V0(Double_t min_pt=0.1, Double_t max_pt=100) cont->UpdateItems(); cont->MakeV0s(); - gReve->Redraw3D(); + gEve->Redraw3D(); return cont; } diff --git a/EVE/alice-macros/esd_V0_points.C b/EVE/alice-macros/esd_V0_points.C index aa31cddd041..cebb3768746 100644 --- a/EVE/alice-macros/esd_V0_points.C +++ b/EVE/alice-macros/esd_V0_points.C @@ -1,14 +1,15 @@ // $Id$ -Reve::PointSet* +TEvePointSet* esd_V0_points() { AliESDEvent* esd = Alieve::Event::AssertESD(); Int_t NV0s = esd->GetNumberOfV0s(); - Reve::PointSet* points = new Reve::PointSet("V0 CA points", NV0s); + TEvePointSet* points = new TEvePointSet("V0 CA points", NV0s); - for (Int_t n =0; nGetV0(n); points->SetNextPoint(av->GetXr(0), av->GetXr(1), av->GetXr(2)); points->SetPointId(av); @@ -25,8 +26,8 @@ esd_V0_points() points->SetMarkerSize(1); points->SetMarkerColor((Color_t)30); - gReve->AddRenderElement(points); - gReve->Redraw3D(); + gEve->AddElement(points); + gEve->Redraw3D(); return points; } diff --git a/EVE/alice-macros/esd_spd_tracklets.C b/EVE/alice-macros/esd_spd_tracklets.C index 053d8decdd7..92f379e401b 100644 --- a/EVE/alice-macros/esd_spd_tracklets.C +++ b/EVE/alice-macros/esd_spd_tracklets.C @@ -6,7 +6,7 @@ public: // virtual void Print(const Option_t* opt="") {} }; -Reve::StraightLineSet* esd_spd_tracklets(Float_t rad=8) +TEveStraightLineSet* esd_spd_tracklets(Float_t rad=8) { AliESDEvent * esd = Alieve::Event::AssertESD(); AliESDVertex * pv = esd->GetPrimaryVertex(); @@ -16,7 +16,7 @@ Reve::StraightLineSet* esd_spd_tracklets(Float_t rad=8) pv->GetXYZ(pvx); pv->GetSigmaXYZ(pve); - Reve::StraightLineSet* ls = new Reve::StraightLineSet(); + TEveStraightLineSet* ls = new TEveStraightLineSet(); for (Int_t i=0; iGetNumberOfTracklets(); ++i) { @@ -30,8 +30,8 @@ Reve::StraightLineSet* esd_spd_tracklets(Float_t rad=8) pvx[0]+dr[0], pvx[1]+dr[1], pvx[2]+dr[2]); } - gReve->AddRenderElement(ls); - gReve->Redraw3D(); + gEve->AddElement(ls); + gEve->Redraw3D(); return ls; } diff --git a/EVE/alice-macros/esd_tracks.C b/EVE/alice-macros/esd_tracks.C index 11a841c0c38..d1db1af42bd 100644 --- a/EVE/alice-macros/esd_tracks.C +++ b/EVE/alice-macros/esd_tracks.C @@ -1,37 +1,37 @@ // $Id$ -Reve::Track* esd_make_track(Reve::TrackRnrStyle* rnrStyle, +TEveTrack* esd_make_track(TEveTrackPropagator* rnrStyle, Int_t index, AliESDtrack* at, AliExternalTrackParam* tp=0) { // Helper function - Double_t pbuf[3], vbuf[3]; - Reve::RecTrack rt; + Double_t pbuf[3], vbuf[3]; + TEveRecTrack rt; if(tp == 0) tp = at; - rt.label = at->GetLabel(); - rt.index = index; - rt.status = (Int_t) at->GetStatus(); - rt.sign = tp->GetSign(); + rt.fLabel = at->GetLabel(); + rt.fIndex = index; + rt.fStatus = (Int_t) at->GetStatus(); + rt.fSign = tp->GetSign(); tp->GetXYZ(vbuf); - rt.V.Set(vbuf); + rt.fV.Set(vbuf); tp->GetPxPyPz(pbuf); - rt.P.Set(pbuf); + rt.fP.Set(pbuf); Double_t ep = at->GetP(), mc = at->GetMass(); - rt.beta = ep/TMath::Sqrt(ep*ep + mc*mc); + rt.fBeta = ep/TMath::Sqrt(ep*ep + mc*mc); - Reve::Track* track = new Reve::Track(&rt, rnrStyle); + TEveTrack* track = new TEveTrack(&rt, rnrStyle); //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT //PH on some platforms (alphalinuxgcc, solariscc5, etc.) - //PH track->SetName(Form("ESDTrack %d", rt.label)); + //PH track->SetName(Form("ESDTrack %d", rt.fLabel)); //PH track->SetTitle(Form("pT=%.3f, pZ=%.3f; V=(%.3f, %.3f, %.3f)", - //PH rt.sign*TMath::Hypot(rt.P.x, rt.P.y), rt.P.z, - //PH rt.V.x, rt.V.y, rt.V.z)); + //PH rt.fSign*TMath::Hypot(rt.fP.fX, rt.fP.fY), rt.fP.fZ, + //PH rt.fV.fX, rt.fV.fY, rt.fV.fZ)); char form[1000]; - sprintf(form,"Track %d", rt.index); + sprintf(form,"TEveTrack %d", rt.fIndex); track->SetName(form); track->SetStdTitle(); return track; @@ -39,7 +39,7 @@ Reve::Track* esd_make_track(Reve::TrackRnrStyle* rnrStyle, Bool_t gkFixFailedITSExtr = kFALSE; -Reve::TrackList* esd_tracks(Double_t min_pt=0.1, Double_t max_pt=100) +TEveTrackList* esd_tracks(Double_t min_pt=0.1, Double_t max_pt=100) { AliESDEvent* esd = Alieve::Event::AssertESD(); @@ -47,12 +47,12 @@ Reve::TrackList* esd_tracks(Double_t min_pt=0.1, Double_t max_pt=100) Double_t maxptsq = max_pt*max_pt; Double_t ptsq; - Reve::TrackList* cont = new Reve::TrackList("ESD Tracks"); + TEveTrackList* cont = new TEveTrackList("ESD Tracks"); cont->SetMainColor(Color_t(6)); - Reve::TrackRnrStyle* rnrStyle = cont->GetRnrStyle(); + TEveTrackPropagator* rnrStyle = cont->GetPropagator(); rnrStyle->SetMagField( esd->GetMagneticField() ); - gReve->AddRenderElement(cont); + gEve->AddElement(cont); Int_t count = 0; Double_t pbuf[3]; @@ -75,9 +75,9 @@ Reve::TrackList* esd_tracks(Double_t min_pt=0.1, Double_t max_pt=100) tp = at->GetInnerParam(); } - Reve::Track* track = esd_make_track(rnrStyle, n, at, tp); + TEveTrack* track = esd_make_track(rnrStyle, n, at, tp); track->SetAttLineAttMarker(cont); - gReve->AddRenderElement(track, cont); + gEve->AddElement(track, cont); } //PH The line below is replaced waiting for a fix in Root @@ -91,7 +91,7 @@ Reve::TrackList* esd_tracks(Double_t min_pt=0.1, Double_t max_pt=100) cont->MakeTracks(); - gReve->Redraw3D(); + gEve->Redraw3D(); return cont; } @@ -100,26 +100,26 @@ Reve::TrackList* esd_tracks(Double_t min_pt=0.1, Double_t max_pt=100) // esd_tracks_from_array() /**************************************************************************/ -Reve::TrackList* esd_tracks_from_array(TCollection* col, AliESDEvent* esd=0) +TEveTrackList* esd_tracks_from_array(TCollection* col, AliESDEvent* esd=0) { // Retrieves AliESDTrack's from collection. // See example usage with AliAnalysisTrackCuts in the next function. - if(esd == 0) esd = Alieve::Event::AssertESD(); + if (esd == 0) esd = Alieve::Event::AssertESD(); - Reve::TrackList* cont = new Reve::TrackList("ESD Tracks"); + TEveTrackList* cont = new TEveTrackList("ESD Tracks"); cont->SetMainColor(Color_t(6)); - Reve::TrackRnrStyle* rnrStyle = cont->GetRnrStyle(); + TEveTrackPropagator* rnrStyle = cont->GetPropagator(); rnrStyle->SetMagField( esd->GetMagneticField() ); - gReve->AddRenderElement(cont); + gEve->AddElement(cont); Int_t count = 0; TIter next(col); TObject *obj; - while((obj = next()) != 0) + while ((obj = next()) != 0) { - if(obj->IsA()->InheritsFrom("AliESDtrack") == kFALSE) { + if (obj->IsA()->InheritsFrom("AliESDtrack") == kFALSE) { Warning("Object '%s', '%s' is not an AliESDtrack.", obj->GetName(), obj->GetTitle()); continue; @@ -128,9 +128,9 @@ Reve::TrackList* esd_tracks_from_array(TCollection* col, AliESDEvent* esd=0) ++count; AliESDtrack* at = (AliESDtrack*) obj; - Reve::Track* track = esd_make_track(rnrStyle, count, at); + TEveTrack* track = esd_make_track(rnrStyle, count, at); track->SetAttLineAttMarker(cont); - gReve->AddRenderElement(track, cont); + gEve->AddElement(track, cont); } //PH The line below is replaced waiting for a fix in Root @@ -144,7 +144,7 @@ Reve::TrackList* esd_tracks_from_array(TCollection* col, AliESDEvent* esd=0) cont->MakeTracks(); - gReve->Redraw3D(); + gEve->Redraw3D(); return cont; } @@ -206,48 +206,48 @@ Float_t get_sigma_to_vertex(AliESDtrack* esdTrack) return d; } -Reve::RenderElementList* esd_tracks_vertex_cut() +TEveElementList* esd_tracks_vertex_cut() { // Import ESD tracks, separate them into five containers according to // primary-vertex cut and ITS refit status. AliESDEvent* esd = Alieve::Event::AssertESD(); - Reve::RenderElementList* cont = new Reve::RenderElementList("ESD Tracks", 0, kTRUE); - gReve->AddRenderElement(cont); - Reve::TrackList *tl[5]; + TEveElementList* cont = new TEveElementList("ESD Tracks", 0, kTRUE); + gEve->AddElement(cont); + TEveTrackList *tl[5]; Int_t tc[5]; Int_t count = 0; - tl[0] = new Reve::TrackList("Sigma < 3"); + tl[0] = new TEveTrackList("Sigma < 3"); tc[0] = 0; - tl[0]->GetRnrStyle()->SetMagField( esd->GetMagneticField() ); + tl[0]->GetPropagator()->SetMagField( esd->GetMagneticField() ); tl[0]->SetMainColor(Color_t(3)); - gReve->AddRenderElement(tl[0], cont); + gEve->AddElement(tl[0], cont); - tl[1] = new Reve::TrackList("3 < Sigma < 5"); + tl[1] = new TEveTrackList("3 < Sigma < 5"); tc[1] = 0; - tl[1]->GetRnrStyle()->SetMagField( esd->GetMagneticField() ); + tl[1]->GetPropagator()->SetMagField( esd->GetMagneticField() ); tl[1]->SetMainColor(Color_t(7)); - gReve->AddRenderElement(tl[1], cont); + gEve->AddElement(tl[1], cont); - tl[2] = new Reve::TrackList("5 < Sigma"); + tl[2] = new TEveTrackList("5 < Sigma"); tc[2] = 0; - tl[2]->GetRnrStyle()->SetMagField( esd->GetMagneticField() ); + tl[2]->GetPropagator()->SetMagField( esd->GetMagneticField() ); tl[2]->SetMainColor(Color_t(46)); - gReve->AddRenderElement(tl[2], cont); + gEve->AddElement(tl[2], cont); - tl[3] = new Reve::TrackList("no ITS refit; Sigma < 5"); + tl[3] = new TEveTrackList("no ITS refit; Sigma < 5"); tc[3] = 0; - tl[3]->GetRnrStyle()->SetMagField( esd->GetMagneticField() ); + tl[3]->GetPropagator()->SetMagField( esd->GetMagneticField() ); tl[3]->SetMainColor(Color_t(41)); - gReve->AddRenderElement(tl[3], cont); + gEve->AddElement(tl[3], cont); - tl[4] = new Reve::TrackList("no ITS refit; Sigma > 5"); + tl[4] = new TEveTrackList("no ITS refit; Sigma > 5"); tc[4] = 0; - tl[4]->GetRnrStyle()->SetMagField( esd->GetMagneticField() ); + tl[4]->GetPropagator()->SetMagField( esd->GetMagneticField() ); tl[4]->SetMainColor(Color_t(48)); - gReve->AddRenderElement(tl[4], cont); + gEve->AddElement(tl[4], cont); for (Int_t n=0; nGetNumberOfTracks(); n++) { @@ -269,11 +269,11 @@ Reve::RenderElementList* esd_tracks_vertex_cut() ti = (ti == 2) ? 4 : 3; } - Reve::TrackList* tlist = tl[ti]; + TEveTrackList* tlist = tl[ti]; ++tc[ti]; ++count; - Reve::Track* track = esd_make_track(tlist->GetRnrStyle(), n, at, tp); + TEveTrack* track = esd_make_track(tlist->GetPropagator(), n, at, tp); track->SetAttLineAttMarker(tlist); //PH The line below is replaced waiting for a fix in Root @@ -281,13 +281,13 @@ Reve::RenderElementList* esd_tracks_vertex_cut() //PH on some platforms (alphalinuxgcc, solariscc5, etc.) //PH track->SetName(Form("track %d, sigma=%5.3f", at->GetLabel(), s)); char form[1000]; - sprintf(form,"Track idx=%d, sigma=%5.3f", at->GetID(), s); + sprintf(form,"TEveTrack idx=%d, sigma=%5.3f", at->GetID(), s); track->SetName(form); - gReve->AddRenderElement(track, tlist); + gEve->AddElement(track, tlist); } for (Int_t ti=0; ti<5; ++ti) { - Reve::TrackList* tlist = tl[ti]; + TEveTrackList* tlist = tl[ti]; //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT //PH on some platforms (alphalinuxgcc, solariscc5, etc.) @@ -310,7 +310,7 @@ Reve::RenderElementList* esd_tracks_vertex_cut() sprintf(form,"N all tracks = %d", count); cont->SetTitle(form); cont->UpdateItems(); - gReve->Redraw3D(); + gEve->Redraw3D(); return cont; } diff --git a/EVE/alice-macros/fmd_hits.C b/EVE/alice-macros/fmd_hits.C index 15f85e6f745..745f10a38d9 100644 --- a/EVE/alice-macros/fmd_hits.C +++ b/EVE/alice-macros/fmd_hits.C @@ -1,6 +1,6 @@ // $Id$ -Reve::PointSet* +TEvePointSet* fmd_hits(const char *varexp = "fX:fY:fZ", const char *selection = "") { @@ -12,12 +12,12 @@ fmd_hits(const char *varexp = "fX:fY:fZ", //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT //PH on some platforms (alphalinuxgcc, solariscc5, etc.) - //PH Reve::PointSet* points = new Reve::PointSet(Form("FMD Hits '%s'", selection)); + //PH TEvePointSet* points = new TEvePointSet(Form("FMD Hits '%s'", selection)); char form[1000]; sprintf(form,"FMD Hits '%s'", selection); - Reve::PointSet* points = new Reve::PointSet(form); + TEvePointSet* points = new TEvePointSet(form); - TPointSelector ps(ht, points, varexp, selection); + TEvePointSelector ps(ht, points, varexp, selection); ps.Select(); //PH points->SetTitle(Form("N=%d", points->Size())); @@ -26,8 +26,8 @@ fmd_hits(const char *varexp = "fX:fY:fZ", points->SetMarkerSize(.5); points->SetMarkerColor((Color_t)2); - gReve->AddRenderElement(points); - gReve->Redraw3D(); + gEve->AddElement(points); + gEve->Redraw3D(); return points; } diff --git a/EVE/alice-macros/geom_acorde.C b/EVE/alice-macros/geom_acorde.C index b1263a2f034..00327cf52a1 100644 --- a/EVE/alice-macros/geom_acorde.C +++ b/EVE/alice-macros/geom_acorde.C @@ -2,22 +2,20 @@ void geom_acorde() { - using namespace std; + gGeoManager = gEve->GetGeometry("geometry.root"); - gGeoManager = gReve->GetGeometry("geometry.root"); + TEveElementList* list = new TEveElementList("ACORDE"); + gEve->AddGlobalElement(list); - Reve::RenderElementList* list = new Reve::RenderElementList("ACORDE"); - gReve->AddGlobalRenderElement(list); - - for(Int_t i=1; i<61; ++i) { - char form[10000]; + for (Int_t i=1; i<61; ++i) + { + char form[1000]; sprintf(form, "ACORDE1_%d", i); - TGeoNode* node = gGeoManager->GetTopVolume()->FindNode(form); - Reve::GeoTopNodeRnrEl* re = new Reve::GeoTopNodeRnrEl(gGeoManager, node); + TGeoNode* node = gGeoManager->GetTopVolume()->FindNode(form); + TEveGeoTopNode* re = new TEveGeoTopNode(gGeoManager, node); re->UseNodeTrans(); - gReve->AddGlobalRenderElement(list, re); - // gReve->AddGlobalRenderElement(re, list); // For EVE-dev + gEve->AddGlobalElement(re, list); } - - gReve->Redraw3D(); + + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/geom_all.C b/EVE/alice-macros/geom_all.C index 7fadde4784c..a4020b78804 100644 --- a/EVE/alice-macros/geom_all.C +++ b/EVE/alice-macros/geom_all.C @@ -2,12 +2,9 @@ void geom_all() { - using namespace std; + gGeoManager = gEve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); - gGeoManager = gReve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); - - Reve::GeoTopNodeRnrEl* topn_re = new Reve::GeoTopNodeRnrEl - (gGeoManager, gGeoManager->GetTopNode()); - gReve->AddGlobalRenderElement(topn_re); - gReve->Redraw3D(); + TEveGeoTopNode* topn_re = new TEveGeoTopNode(gGeoManager, gGeoManager->GetTopNode()); + gEve->AddGlobalElement(topn_re); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/geom_ddip.C b/EVE/alice-macros/geom_ddip.C index 4868bfbc672..1986d845c35 100644 --- a/EVE/alice-macros/geom_ddip.C +++ b/EVE/alice-macros/geom_ddip.C @@ -2,13 +2,11 @@ void geom_ddip() { - using namespace std; - - gGeoManager = gReve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); + gGeoManager = gEve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); TGeoNode* node = gGeoManager->GetTopVolume()->FindNode("DDIP_1"); - Reve::GeoTopNodeRnrEl* re = new Reve::GeoTopNodeRnrEl(gGeoManager, node); + TEveGeoTopNode* re = new TEveGeoTopNode(gGeoManager, node); re->UseNodeTrans(); - gReve->AddGlobalRenderElement(re); - gReve->Redraw3D(); + gEve->AddGlobalElement(re); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/geom_emcal.C b/EVE/alice-macros/geom_emcal.C index d18a7f3e8f5..e98f47e3c79 100644 --- a/EVE/alice-macros/geom_emcal.C +++ b/EVE/alice-macros/geom_emcal.C @@ -2,13 +2,10 @@ void geom_emcal() { - using namespace std; - - gGeoManager = gReve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); + gGeoManager = gEve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); TGeoNode* node = gGeoManager->GetTopVolume()->FindNode("XEN1_1"); - Reve::GeoTopNodeRnrEl* emcal_re = - new Reve::GeoTopNodeRnrEl(gGeoManager, node); - gReve->AddGlobalRenderElement(emcal_re); - gReve->Redraw3D(); + TEveGeoTopNode* emcal_re = new TEveGeoTopNode(gGeoManager, node); + gEve->AddGlobalElement(emcal_re); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/geom_fmd.C b/EVE/alice-macros/geom_fmd.C index 682093f8c25..2a0efbc5e2c 100644 --- a/EVE/alice-macros/geom_fmd.C +++ b/EVE/alice-macros/geom_fmd.C @@ -2,16 +2,15 @@ void geom_fmd() { - using namespace std; + gGeoManager = gEve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); - gGeoManager = gReve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); + TEveElementList* list = new TEveElementList("FMD"); + gEve->AddGlobalElement(list); - Reve::RenderElementList* list = new Reve::RenderElementList("FMD"); - gReve->AddGlobalRenderElement(list); - - for(Int_t i=1; i<=3; ++i) { - TGeoNode* node; - Reve::GeoTopNodeRnrEl* re; + for(Int_t i=1; i<=3; ++i) + { + TGeoNode *node = 0; + TEveGeoTopNode *re = 0; //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT @@ -20,16 +19,16 @@ void geom_fmd() char form[1000]; sprintf(form,"F%dMT_%d", i, i); node = gGeoManager->GetTopVolume()->FindNode(form); - re = new Reve::GeoTopNodeRnrEl(gGeoManager, node); + re = new TEveGeoTopNode(gGeoManager, node); re->UseNodeTrans(); - gReve->AddGlobalRenderElement(re, list); + gEve->AddGlobalElement(re, list); sprintf(form,"F%dMB_%d", i, i); node = gGeoManager->GetTopVolume()->FindNode(form); - re = new Reve::GeoTopNodeRnrEl(gGeoManager, node); + re = new TEveGeoTopNode(gGeoManager, node); re->UseNodeTrans(); - gReve->AddGlobalRenderElement(re, list); + gEve->AddGlobalElement(re, list); } - gReve->Redraw3D(); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/geom_gentle.C b/EVE/alice-macros/geom_gentle.C index f10d3c92425..83ecd0e0bb8 100644 --- a/EVE/alice-macros/geom_gentle.C +++ b/EVE/alice-macros/geom_gentle.C @@ -1,10 +1,10 @@ // $Id$ -Reve::GeoShapeRnrEl* geom_gentle() +TEveGeoShape* geom_gentle() { TFile f("$REVESYS/alice-data/gentle_geo.root"); - TGeoShapeExtract* gse = (TGeoShapeExtract*) f.Get("Gentle"); - Reve::GeoShapeRnrEl* gsre = Reve::GeoShapeRnrEl::ImportShapeExtract(gse, 0); + TEveGeoShapeExtract* gse = (TEveGeoShapeExtract*) f.Get("Gentle"); + TEveGeoShape* gsre = TEveGeoShape::ImportShapeExtract(gse, 0); f.Close(); return gsre; diff --git a/EVE/alice-macros/geom_hmpid.C b/EVE/alice-macros/geom_hmpid.C index a59e9a7615c..423d5c1a228 100644 --- a/EVE/alice-macros/geom_hmpid.C +++ b/EVE/alice-macros/geom_hmpid.C @@ -2,12 +2,10 @@ void geom_hmpid() { - using namespace std; + gGeoManager = gEve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); - gGeoManager = gReve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); - - Reve::RenderElementList* list = new Reve::RenderElementList("HMPID"); - gReve->AddGlobalRenderElement(list); + TEveElementList* list = new TEveElementList("HMPID"); + gEve->AddGlobalElement(list); for(Int_t i=0; i<7; ++i) { //PH The line below is replaced waiting for a fix in Root @@ -18,10 +16,10 @@ void geom_hmpid() sprintf(form, "HMPID_%d", i); TGeoNode* node = gGeoManager->GetTopVolume()->FindNode(form); - Reve::GeoTopNodeRnrEl* re = new Reve::GeoTopNodeRnrEl(gGeoManager, node); + TEveGeoTopNode* re = new TEveGeoTopNode(gGeoManager, node); re->UseNodeTrans(); - gReve->AddGlobalRenderElement(re, list); + gEve->AddGlobalElement(re, list); } - gReve->Redraw3D(); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/geom_its.C b/EVE/alice-macros/geom_its.C index 47b89e456fd..0dfacf5f945 100644 --- a/EVE/alice-macros/geom_its.C +++ b/EVE/alice-macros/geom_its.C @@ -2,13 +2,10 @@ void geom_its() { - using namespace std; - - gGeoManager = gReve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); + gGeoManager = gEve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); TGeoNode* node = gGeoManager->GetTopVolume()->FindNode("ITSV_1"); - Reve::GeoTopNodeRnrEl* its_re = - new Reve::GeoTopNodeRnrEl(gGeoManager, node); - gReve->AddGlobalRenderElement(its_re); - gReve->Redraw3D(); + TEveGeoTopNode* its_re = new TEveGeoTopNode(gGeoManager, node); + gEve->AddGlobalElement(its_re); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/geom_phos.C b/EVE/alice-macros/geom_phos.C index ff80a9039bd..ce86844f1b4 100644 --- a/EVE/alice-macros/geom_phos.C +++ b/EVE/alice-macros/geom_phos.C @@ -2,12 +2,10 @@ void geom_phos() { - using namespace std; + gGeoManager = gEve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); - gGeoManager = gReve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); - - Reve::RenderElementList* list = new Reve::RenderElementList("PHOS"); - gReve->AddGlobalRenderElement(list); + TEveElementList* list = new TEveElementList("PHOS"); + gEve->AddGlobalElement(list); for(Int_t i=1; i<=5; ++i) { //PH The line below is replaced waiting for a fix in Root @@ -18,10 +16,10 @@ void geom_phos() sprintf(form,"PHOS_%d", i); TGeoNode* node = gGeoManager->GetTopVolume()->FindNode(form); - Reve::GeoTopNodeRnrEl* re = new Reve::GeoTopNodeRnrEl(gGeoManager, node); + TEveGeoTopNode* re = new TEveGeoTopNode(gGeoManager, node); re->UseNodeTrans(); - gReve->AddGlobalRenderElement(re, list); + gEve->AddGlobalElement(re, list); } - gReve->Redraw3D(); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/geom_pmd.C b/EVE/alice-macros/geom_pmd.C index d0beb47e546..62851036606 100644 --- a/EVE/alice-macros/geom_pmd.C +++ b/EVE/alice-macros/geom_pmd.C @@ -2,9 +2,7 @@ void geom_pmd() { - using namespace std; - - gGeoManager = gReve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); + gGeoManager = gEve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); for(Int_t i=1; i<=4; ++i) { //PH The line below is replaced waiting for a fix in Root @@ -15,10 +13,10 @@ void geom_pmd() sprintf(form,"EPM%d_1", i); TGeoNode* node = gGeoManager->GetTopVolume()->FindNode(form); - Reve::GeoTopNodeRnrEl* re = new Reve::GeoTopNodeRnrEl(gGeoManager, node); + TEveGeoTopNode* re = new TEveGeoTopNode(gGeoManager, node); re->UseNodeTrans(); - gReve->AddGlobalRenderElement(re); + gEve->AddGlobalElement(re); } - gReve->Redraw3D(); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/geom_simple.C b/EVE/alice-macros/geom_simple.C index 151d6396001..876e70a986a 100644 --- a/EVE/alice-macros/geom_simple.C +++ b/EVE/alice-macros/geom_simple.C @@ -2,12 +2,9 @@ void geom_simple() { - using namespace std; + gGeoManager = gEve->GetGeometry("$REVESYS/alice-data/simple_geo.root"); - gGeoManager = gReve->GetGeometry("$REVESYS/alice-data/simple_geo.root"); - - Reve::GeoTopNodeRnrEl* topn_re = new Reve::GeoTopNodeRnrEl - (gGeoManager, gGeoManager->GetTopNode()); - gReve->AddGlobalRenderElement(topn_re); - gReve->Redraw3D(); + TEveGeoTopNode* topn_re = new TEveGeoTopNode(gGeoManager, gGeoManager->GetTopNode()); + gEve->AddGlobalElement(topn_re); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/geom_t0.C b/EVE/alice-macros/geom_t0.C index 52d4c9d7314..8c5cf8b8188 100644 --- a/EVE/alice-macros/geom_t0.C +++ b/EVE/alice-macros/geom_t0.C @@ -2,25 +2,23 @@ void geom_t0() { - using namespace std; + gGeoManager = gEve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); - gGeoManager = gReve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); - - Reve::RenderElementList* list = new Reve::RenderElementList("T0"); - gReve->AddGlobalRenderElement(list); + TEveElementList* list = new TEveElementList("T0"); + gEve->AddGlobalElement(list); TGeoNode* node; - Reve::GeoTopNodeRnrEl* re; + TEveGeoTopNode* re; node = gGeoManager->GetTopVolume()->FindNode("0STR_1"); - re = new Reve::GeoTopNodeRnrEl(gGeoManager, node); + re = new TEveGeoTopNode(gGeoManager, node); re->UseNodeTrans(); - gReve->AddGlobalRenderElement(re, list); + gEve->AddGlobalElement(re, list); node = gGeoManager->GetTopVolume()->FindNode("0STL_1"); - re = new Reve::GeoTopNodeRnrEl(gGeoManager, node); + re = new TEveGeoTopNode(gGeoManager, node); re->UseNodeTrans(); - gReve->AddGlobalRenderElement(re, list); + gEve->AddGlobalElement(re, list); - gReve->Redraw3D(); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/geom_tpc.C b/EVE/alice-macros/geom_tpc.C index a990a1c7241..6280303b502 100644 --- a/EVE/alice-macros/geom_tpc.C +++ b/EVE/alice-macros/geom_tpc.C @@ -2,13 +2,10 @@ void geom_tpc() { - using namespace std; - - gGeoManager = gReve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); + gGeoManager = gEve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); TGeoNode* node = gGeoManager->GetTopVolume()->FindNode("TPC_M_1"); - Reve::GeoTopNodeRnrEl* tpc_re = - new Reve::GeoTopNodeRnrEl(gGeoManager, node); - gReve->AddGlobalRenderElement(tpc_re); - gReve->Redraw3D(); + TEveGeoTopNode* tpc_re = new TEveGeoTopNode(gGeoManager, node); + gEve->AddGlobalElement(tpc_re); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/geom_trd_tof.C b/EVE/alice-macros/geom_trd_tof.C index 9a5a73b1df3..726e09e82d2 100644 --- a/EVE/alice-macros/geom_trd_tof.C +++ b/EVE/alice-macros/geom_trd_tof.C @@ -4,11 +4,10 @@ void geom_trd_tof() { using namespace std; - gGeoManager = gReve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); + gGeoManager = gEve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); TGeoNode* node = gGeoManager->GetTopVolume()->FindNode("B077_1"); - Reve::GeoTopNodeRnrEl* its_re = - new Reve::GeoTopNodeRnrEl(gGeoManager, node); - gReve->AddGlobalRenderElement(its_re); - gReve->Redraw3D(); + TEveGeoTopNode* its_re = new TEveGeoTopNode(gGeoManager, node); + gEve->AddGlobalElement(its_re); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/geom_vzero.C b/EVE/alice-macros/geom_vzero.C index f7f9a4dd4fa..34102a7fe48 100644 --- a/EVE/alice-macros/geom_vzero.C +++ b/EVE/alice-macros/geom_vzero.C @@ -4,15 +4,15 @@ void geom_vzero() { using namespace std; - static const Reve::Exc_t eH("geom_vzero() "); + static const TEveException eH("geom_vzero() "); - gGeoManager = gReve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); + gGeoManager = gEve->GetGeometry("$REVESYS/alice-data/alice_fullgeo.root"); - Reve::RenderElementList* list = new Reve::RenderElementList("VZero"); - gReve->AddGlobalRenderElement(list); + TEveElementList* list = new TEveElementList("VZero"); + gEve->AddGlobalElement(list); TGeoNode* node = 0; - Reve::GeoTopNodeRnrEl* re; + TEveGeoTopNode* re; TGeoNode* mnode = gGeoManager->GetTopVolume()->FindNode("VZERO_1"); if (!mnode) { @@ -26,18 +26,18 @@ void geom_vzero() Error(eH, "V0R not found."); return; } - re = new Reve::GeoTopNodeRnrEl(gGeoManager, node); + re = new TEveGeoTopNode(gGeoManager, node); re->UseNodeTrans(); - gReve->AddGlobalRenderElement(re, list); + gEve->AddGlobalElement(re, list); node = mnode->GetVolume()->FindNode("V0LE_1"); if (!node) { Error(eH, "V0L not found."); return; } - re = new Reve::GeoTopNodeRnrEl(gGeoManager, node); + re = new TEveGeoTopNode(gGeoManager, node); re->UseNodeTrans(); - gReve->AddGlobalRenderElement(re, list); + gEve->AddGlobalElement(re, list); - gReve->Redraw3D(); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/hits_from_label.C b/EVE/alice-macros/hits_from_label.C index 7d400db857a..7800838601d 100644 --- a/EVE/alice-macros/hits_from_label.C +++ b/EVE/alice-macros/hits_from_label.C @@ -1,9 +1,10 @@ // $Id$ -void hits_from_label(Int_t label=0, Reve::RenderElement* cont) +void hits_from_label(Int_t label=0, TEveElement* cont) { - Reve::PointSet* h; - Reve::LoadMacro("its_hits.C"); + TEveUtil::LoadMacro("its_hits.C"); + + TEvePointSet* h = 0; //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT //PH on some platforms (alphalinuxgcc, solariscc5, etc.) @@ -11,24 +12,24 @@ void hits_from_label(Int_t label=0, Reve::RenderElement* cont) char form[1000]; sprintf(form,"ITS.fTrack==%d", label); h = its_hits("fX:fY:fZ", form, cont); - if(h) h->SetMarkerSize(1); + if (h) h->SetMarkerSize(1); - Reve::LoadMacro("tpc_hits.C"); + TEveUtil::LoadMacro("tpc_hits.C"); sprintf(form,"TPC2.fArray.fTrackID==%d", label); h = tpc_hits("TPC2.fArray.fR:TPC2.fArray.fFi:TPC2.fArray.fZ",form, cont); //PH h = tpc_hits("TPC2.fArray.fR:TPC2.fArray.fFi:TPC2.fArray.fZ", //PH Form("TPC2.fArray.fTrackID==%d", label)); - if(h) h->SetMarkerSize(1); + if (h) h->SetMarkerSize(1); - Reve::LoadMacro("trd_hits.C"); + TEveUtil::LoadMacro("trd_hits.C"); sprintf(form,"TRD.fTrack==%d", label); h = trd_hits("fX:fY:fZ", form, cont); - if(h) h->SetMarkerSize(1); + if (h) h->SetMarkerSize(1); - Reve::LoadMacro("tof_hits.C"); + TEveUtil::LoadMacro("tof_hits.C"); sprintf(form,"TOF.fTrack==%d", label); h = tof_hits("fX:fY:fZ", form, cont); - if(h) h->SetMarkerSize(1); + if (h) h->SetMarkerSize(1); - gReve->Redraw3D(); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/hmpid_clusters.C b/EVE/alice-macros/hmpid_clusters.C index 466e83884f7..26194067c3d 100644 --- a/EVE/alice-macros/hmpid_clusters.C +++ b/EVE/alice-macros/hmpid_clusters.C @@ -1,16 +1,16 @@ #ifdef __CINT__ -namespace Reve +namespace TEveUtil { -class RenderElement; -class PointSet; +class TEveElement; +class TEvePointSet; } #else -#include -#include -#include +#include +#include +#include #include #include @@ -20,7 +20,7 @@ class PointSet; #endif -Reve::PointSet* hmpid_clusters(Reve::RenderElement* cont=0, Float_t maxR=1000) +TEvePointSet* hmpid_clusters(TEveElement* cont=0, Float_t maxR=1000) { const Int_t nCh=7; TClonesArray *cl[nCh] = {0,0,0,0,0,0,0}; @@ -35,7 +35,7 @@ Reve::PointSet* hmpid_clusters(Reve::RenderElement* cont=0, Float_t maxR=1000) }; - Reve::PointSet* clusters = new Reve::PointSet(10000); + TEvePointSet* clusters = new TEvePointSet(10000); clusters->SetOwnIds(kTRUE); Alieve::Event::AssertGeometry(); @@ -73,7 +73,7 @@ Reve::PointSet* hmpid_clusters(Reve::RenderElement* cont=0, Float_t maxR=1000) } } - if(clusters->Size() == 0 && gReve->GetKeepEmptyCont() == kFALSE) { + if (clusters->Size() == 0 && gEve->GetKeepEmptyCont() == kFALSE) { Warning("hmpid_clusters", "No HMPID clusters"); delete clusters; return 0; @@ -90,10 +90,8 @@ Reve::PointSet* hmpid_clusters(Reve::RenderElement* cont=0, Float_t maxR=1000) char tip[1000]; sprintf(tip,"N=%d", clusters->Size()); clusters->SetTitle(tip); - - using namespace Reve; - gReve->AddRenderElement(clusters, cont); - gReve->Redraw3D(); + gEve->AddElement(clusters, cont); + gEve->Redraw3D(); return clusters; } diff --git a/EVE/alice-macros/init_trd.C b/EVE/alice-macros/init_trd.C index d0e2588948f..9c5ad9c6ed8 100644 --- a/EVE/alice-macros/init_trd.C +++ b/EVE/alice-macros/init_trd.C @@ -1,12 +1,12 @@ void init_trd() { - TString macdir("$(REVESYS)/alice-macros"); - gSystem->ExpandPathName(macdir); - gROOT->GetListOfBrowsables()->Add - (new TSystemDirectory(macdir.Data(), macdir.Data())); - Reve::AssertMacro("region_marker.C"); + TString macdir("$(REVESYS)/alice-macros"); + gSystem->ExpandPathName(macdir); + gROOT->GetListOfBrowsables()->Add + (new TSystemDirectory(macdir.Data(), macdir.Data())); + AssertMacro("region_marker.C"); - Alieve::TRDLoaderManager *trd=new Alieve::TRDLoaderManager("TRD manager", "Loader manager for TRD data monitoring"); - gReve->AddRenderElement(trd); - gReve->AddToListTree(trd, kTRUE); + Alieve::TRDLoaderManager *trd=new Alieve::TRDLoaderManager("TRD manager", "Loader manager for TRD data monitoring"); + gEve->AddElement(trd); + gEve->AddToListTree(trd, kTRUE); } diff --git a/EVE/alice-macros/its_clusters.C b/EVE/alice-macros/its_clusters.C index 353a83fae76..f43ee581526 100644 --- a/EVE/alice-macros/its_clusters.C +++ b/EVE/alice-macros/its_clusters.C @@ -1,16 +1,16 @@ #ifdef __CINT__ -namespace Reve +namespace TEveUtil { -class RenderElement; -class PointSet; +class TEveElement; +class TEvePointSet; } #else -#include -#include -#include +#include +#include +#include #include #include @@ -20,7 +20,7 @@ class PointSet; #endif -Reve::PointSet* its_clusters(Reve::RenderElement* cont=0, Float_t maxR=50) +TEvePointSet* its_clusters(TEveElement* cont=0, Float_t maxR=50) { Alieve::Event::AssertGeometry(); @@ -29,7 +29,7 @@ Reve::PointSet* its_clusters(Reve::RenderElement* cont=0, Float_t maxR=50) TTree *cTree = rl->GetTreeR("ITS", false); - Reve::PointSet* clusters = new Reve::PointSet(10000); + TEvePointSet* clusters = new TEvePointSet(10000); clusters->SetOwnIds(kTRUE); TClonesArray *cl = NULL; @@ -56,7 +56,7 @@ Reve::PointSet* its_clusters(Reve::RenderElement* cont=0, Float_t maxR=50) } } - if(clusters->Size() == 0 && gReve->GetKeepEmptyCont() == kFALSE) { + if (clusters->Size() == 0 && gEve->GetKeepEmptyCont() == kFALSE) { Warning("its_clusters", "No ITS clusters"); delete clusters; return 0; @@ -73,10 +73,8 @@ Reve::PointSet* its_clusters(Reve::RenderElement* cont=0, Float_t maxR=50) char tip[1000]; sprintf(tip,"N=%d", clusters->Size()); clusters->SetTitle(tip); - - using namespace Reve; - gReve->AddRenderElement(clusters, cont); - gReve->Redraw3D(); + gEve->AddElement(clusters, cont); + gEve->Redraw3D(); return clusters; } diff --git a/EVE/alice-macros/its_digits.C b/EVE/alice-macros/its_digits.C index da927a8f588..8d9bc9d8307 100644 --- a/EVE/alice-macros/its_digits.C +++ b/EVE/alice-macros/its_digits.C @@ -23,7 +23,7 @@ void its_digits(Int_t mode=63) gStyle->SetPalette(1, 0); // Initialize palettes (?) - gReve->DisableRedraw(); + gEve->DisableRedraw(); TString sSector; TString bsSector="Sector"; @@ -36,25 +36,25 @@ void its_digits(Int_t mode=63) Int_t nsec, nstave, nlad, nMod; if (mode & 1) { - Reve::RenderElementList* l = new Reve::RenderElementList("SPD0"); + TEveElementList* l = new TEveElementList("SPD0"); l->SetTitle("SPDs' first layer"); l->SetMainColor((Color_t)2); - gReve->AddRenderElement(l); - for(nsec=0; nsec<10; nsec++) { + gEve->AddElement(l); + for (nsec=0; nsec<10; nsec++) { sSector = bsSector; sSector += nsec; - Reve::RenderElementList* relSector = new Reve::RenderElementList(sSector.Data()); + TEveElementList* relSector = new TEveElementList(sSector.Data()); relSector->SetMainColor((Color_t)2); - gReve->AddRenderElement(relSector, l); - for(nstave=0; nstave<2; nstave++){ + gEve->AddElement(relSector, l); + for (nstave=0; nstave<2; nstave++){ sStave = bsStave; sStave += nstave; - Reve::RenderElementList* relStave = new Reve::RenderElementList(sStave.Data()); + TEveElementList* relStave = new TEveElementList(sStave.Data()); relStave->SetMainColor((Color_t)2); - gReve->AddRenderElement(relStave, relSector); - for(nMod=0; nMod<4; nMod++) { + gEve->AddElement(relStave, relSector); + for (nMod=0; nMod<4; nMod++) { Alieve::ITSModule* m = new Alieve::ITSModule(i++, di); - gReve->AddRenderElement(m, relStave); + gEve->AddElement(m, relStave); } } } @@ -63,26 +63,26 @@ void its_digits(Int_t mode=63) } if (mode & 2) { - Reve::RenderElementList* l = new Reve::RenderElementList("SPD1"); + TEveElementList* l = new TEveElementList("SPD1"); l->SetTitle("SPDs' second layer"); l->SetMainColor((Color_t)2); - gReve->AddRenderElement(l); + gEve->AddElement(l); - for(nsec=0; nsec<10; nsec++) { + for (nsec=0; nsec<10; nsec++) { sSector = bsSector; sSector += nsec; - Reve::RenderElementList* relSector = new Reve::RenderElementList(sSector.Data()); + TEveElementList* relSector = new TEveElementList(sSector.Data()); relSector->SetMainColor((Color_t)2); - gReve->AddRenderElement(relSector, l); - for(nstave=0; nstave<4; nstave++){ + gEve->AddElement(relSector, l); + for (nstave=0; nstave<4; nstave++){ sStave = bsStave; sStave += nstave; - Reve::RenderElementList* relStave = new Reve::RenderElementList(sStave.Data()); + TEveElementList* relStave = new TEveElementList(sStave.Data()); relStave->SetMainColor((Color_t)2); - gReve->AddRenderElement(relStave, relSector); - for(nMod=0; nMod<4; nMod++) { + gEve->AddElement(relStave, relSector); + for (nMod=0; nMod<4; nMod++) { Alieve::ITSModule* m = new Alieve::ITSModule(i++, di); - gReve->AddRenderElement(m, relStave); + gEve->AddElement(m, relStave); } } } @@ -91,20 +91,20 @@ void its_digits(Int_t mode=63) } if (mode & 4) { - Reve::RenderElementList* l = new Reve::RenderElementList("SDD2"); + TEveElementList* l = new TEveElementList("SDD2"); l->SetTitle("SDDs' first layer"); l->SetMainColor((Color_t)3); - gReve->AddRenderElement(l); + gEve->AddElement(l); - for(nlad=0; nlad<14; nlad++) { + for (nlad=0; nlad<14; nlad++) { sLadder = bsLadder; sLadder += nlad; - Reve::RenderElementList* relLadder = new Reve::RenderElementList(sLadder.Data()); + TEveElementList* relLadder = new TEveElementList(sLadder.Data()); relLadder->SetMainColor((Color_t)3); - gReve->AddRenderElement(relLadder, l); - for(nMod=0; nMod<6; nMod++) { + gEve->AddElement(relLadder, l); + for (nMod=0; nMod<6; nMod++) { Alieve::ITSModule* m = new Alieve::ITSModule(i++, di); - gReve->AddRenderElement(m, relLadder); + gEve->AddElement(m, relLadder); } } } else { @@ -112,19 +112,19 @@ void its_digits(Int_t mode=63) } if (mode & 8) { - Reve::RenderElementList* l = new Reve::RenderElementList("SDD3"); + TEveElementList* l = new TEveElementList("SDD3"); l->SetTitle("SDDs' second layer"); l->SetMainColor((Color_t)3); - gReve->AddRenderElement(l); - for(nlad=0; nlad<22; nlad++) { + gEve->AddElement(l); + for (nlad=0; nlad<22; nlad++) { sLadder = bsLadder; sLadder += nlad; - Reve::RenderElementList* relLadder = new Reve::RenderElementList(sLadder.Data()); + TEveElementList* relLadder = new TEveElementList(sLadder.Data()); relLadder->SetMainColor((Color_t)3); - gReve->AddRenderElement(relLadder, l); - for(nMod=0; nMod<8; nMod++) { + gEve->AddElement(relLadder, l); + for (nMod=0; nMod<8; nMod++) { Alieve::ITSModule* m = new Alieve::ITSModule(i++, di); - gReve->AddRenderElement(m, relLadder); + gEve->AddElement(m, relLadder); } } } else { @@ -132,19 +132,19 @@ void its_digits(Int_t mode=63) } if (mode & 16) { - Reve::RenderElementList* l = new Reve::RenderElementList("SSD4"); + TEveElementList* l = new TEveElementList("SSD4"); l->SetTitle("SSDs' first layer"); l->SetMainColor((Color_t)4); - gReve->AddRenderElement(l); - for(nlad=0; nlad<34; nlad++) { + gEve->AddElement(l); + for (nlad=0; nlad<34; nlad++) { sLadder = bsLadder; sLadder += nlad; - Reve::RenderElementList* relLadder = new Reve::RenderElementList(sLadder.Data()); + TEveElementList* relLadder = new TEveElementList(sLadder.Data()); relLadder->SetMainColor((Color_t)4); - gReve->AddRenderElement(relLadder, l); - for(nMod=0; nMod<22; nMod++) { + gEve->AddElement(relLadder, l); + for (nMod=0; nMod<22; nMod++) { Alieve::ITSModule* m = new Alieve::ITSModule(i++, di); - gReve->AddRenderElement(m, relLadder); + gEve->AddElement(m, relLadder); } } } else { @@ -152,24 +152,24 @@ void its_digits(Int_t mode=63) } if (mode & 32) { - Reve::RenderElementList* l = new Reve::RenderElementList("SSD5"); + TEveElementList* l = new TEveElementList("SSD5"); l->SetTitle("SSDs' second layer"); l->SetMainColor((Color_t)4); - gReve->AddRenderElement(l); - for(nlad=0; nlad<38; nlad++) { + gEve->AddElement(l); + for (nlad=0; nlad<38; nlad++) { sLadder = bsLadder; sLadder += nlad; - Reve::RenderElementList* relLadder = new Reve::RenderElementList(sLadder.Data()); + TEveElementList* relLadder = new TEveElementList(sLadder.Data()); relLadder->SetMainColor((Color_t)4); - gReve->AddRenderElement(relLadder, l); - for(nMod=0; nMod<25; nMod++) { + gEve->AddElement(relLadder, l); + for (nMod=0; nMod<25; nMod++) { Alieve::ITSModule* m = new Alieve::ITSModule(i++, di); - gReve->AddRenderElement(m, relLadder); + gEve->AddElement(m, relLadder); } } } else { i += 38*25; } - gReve->EnableRedraw(); + gEve->EnableRedraw(); } diff --git a/EVE/alice-macros/its_hits.C b/EVE/alice-macros/its_hits.C index 6fca038a146..6bec89e879f 100644 --- a/EVE/alice-macros/its_hits.C +++ b/EVE/alice-macros/its_hits.C @@ -1,9 +1,9 @@ // $Id$ -Reve::PointSet* +TEvePointSet* its_hits(const char *varexp = "fX:fY:fZ", const char *selection = "", - Reve::RenderElement* cont = 0) + TEveElement* cont = 0) { AliRunLoader* rl = Alieve::Event::AssertRunLoader(); rl->LoadHits("ITS"); @@ -13,16 +13,16 @@ its_hits(const char *varexp = "fX:fY:fZ", //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT //PH on some platforms (alphalinuxgcc, solariscc5, etc.) - //PH Reve::PointSet* points = new Reve::PointSet(Form("ITS Hits '%s'", selection)); + //PH TEvePointSet* points = new TEvePointSet(Form("ITS Hits '%s'", selection)); char form[1000]; sprintf(form,"ITS Hits '%s'", selection); - Reve::PointSet* points = new Reve::PointSet(form); + TEvePointSet* points = new TEvePointSet(form); - TPointSelector ps(ht, points, varexp, selection); + TEvePointSelector ps(ht, points, varexp, selection); // ps.SetSubIdExp("fTrack:fStatus"); ps.Select(); - if(points->Size() == 0 && gReve->GetKeepEmptyCont() == kFALSE) { + if(points->Size() == 0 && gEve->GetKeepEmptyCont() == kFALSE) { Warning("its_hits", Form("No hits match '%s'", selection)); delete points; return 0; @@ -34,8 +34,8 @@ its_hits(const char *varexp = "fX:fY:fZ", points->SetMarkerSize(.5); points->SetMarkerColor((Color_t)2); - gReve->AddRenderElement(points, cont); - gReve->Redraw3D(); + gEve->AddElement(points, cont); + gEve->Redraw3D(); return points; } diff --git a/EVE/alice-macros/its_hits_layer_split.C b/EVE/alice-macros/its_hits_layer_split.C index fb01526a125..e28e9faecd6 100644 --- a/EVE/alice-macros/its_hits_layer_split.C +++ b/EVE/alice-macros/its_hits_layer_split.C @@ -1,28 +1,33 @@ // $Id$ -void its_hits_layer_split(const char *varexp = "fX:fY:fZ:fLayer", +void its_hits_layer_split(const char *varexp = "fX:fY:fZ:GetLayer()", const char *selection = "") { // Extracts 'major' TPC hits (not the compressed ones). // This gives ~2.5% of all hits. + printf("THIS SCRIPT DOES NOT WORK.\n" + "GetLayer() crashes when trying to load ITS geometry.\n" + "Needs to be fixed together with ITS experts.\n"); + return; + AliRunLoader* rl = Alieve::Event::AssertRunLoader(); rl->LoadHits("ITS"); TTree* ht = rl->GetTreeH("ITS", false); - Reve::PointSetArray* l = new Reve::PointSetArray("ITS hits - Layer Slices", ""); + TEvePointSetArray* l = new TEvePointSetArray("ITS hits - Layer Slices", ""); l->SetMarkerColor((Color_t)2); l->SetMarkerStyle(2); // cross l->SetMarkerSize(.2); - gReve->AddRenderElement(l); + gEve->AddElement(l); l->InitBins("Layer", 6, 0.5, 6.5); - TPointSelector ps(ht, l, varexp, selection); + TEvePointSelector ps(ht, l, varexp, selection); ps.Select(); l->CloseBins(); - gReve->Redraw3D(); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/its_module_stepper.C b/EVE/alice-macros/its_module_stepper.C index dea5009cb52..87e203eb3d4 100644 --- a/EVE/alice-macros/its_module_stepper.C +++ b/EVE/alice-macros/its_module_stepper.C @@ -12,16 +12,16 @@ void its_module_stepper(Int_t det = 0) Alieve::ITSDigitsInfo* di = new Alieve::ITSDigitsInfo(); di->SetTree(tree); - gReve->DisableRedraw(); + gEve->DisableRedraw(); Alieve::ITSModuleStepper* ms = new Alieve::ITSModuleStepper(di); ms->SetMainColor(Color_t(8)); gStyle->SetPalette(1, 0); ms->DisplayDet(det, -1); - gReve->AddRenderElement(ms); - gReve->Redraw3D(kTRUE); // To enforce camera reset - gReve->EnableRedraw(); + gEve->AddElement(ms); + gEve->Redraw3D(kTRUE); // To enforce camera reset + gEve->EnableRedraw(); - TGLViewer* v = (TGLViewer *)gReve->GetGLViewer(); + TGLViewer* v = (TGLViewer *)gEve->GetGLViewer(); v->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); TGLCameraMarkupStyle* mup = v->GetCameraMarkup(); if(mup) mup->SetShow(kFALSE); diff --git a/EVE/alice-macros/its_raw.C b/EVE/alice-macros/its_raw.C index d11ea6ad66e..1e63fb7c3c7 100644 --- a/EVE/alice-macros/its_raw.C +++ b/EVE/alice-macros/its_raw.C @@ -49,7 +49,7 @@ void its_raw(const char *input = "rawdata.root", gStyle->SetPalette(1, 0); // Initialize palettes (?) - gReve->DisableRedraw(); + gEve->DisableRedraw(); TString sSector; TString bsSector="Sector"; @@ -62,28 +62,28 @@ void its_raw(const char *input = "rawdata.root", Int_t nsec, nstave, nlad, nMod; if (mode & 1) { - Reve::RenderElementList* l = new Reve::RenderElementList("SPD0"); + TEveElementList* l = new TEveElementList("SPD0"); l->SetTitle("SPDs' first layer"); l->SetMainColor((Color_t)2); - gReve->AddRenderElement(l); - for(nsec=0; nsec<10; nsec++) { + gEve->AddElement(l); + for (nsec=0; nsec<10; nsec++) { sSector = bsSector; sSector += nsec; - Reve::RenderElementList* relSector = new Reve::RenderElementList(sSector.Data()); + TEveElementList* relSector = new TEveElementList(sSector.Data()); relSector->SetMainColor((Color_t)2); - gReve->AddRenderElement(relSector, l); - for(nstave=0; nstave<2; nstave++){ + gEve->AddElement(relSector, l); + for (nstave=0; nstave<2; nstave++){ sStave = bsStave; sStave += nstave; - Reve::RenderElementList* relStave = new Reve::RenderElementList(sStave.Data()); + TEveElementList* relStave = new TEveElementList(sStave.Data()); relStave->SetMainColor((Color_t)2); - gReve->AddRenderElement(relStave, relSector); - for(nMod=0; nMod<4; nMod++) + gEve->AddElement(relStave, relSector); + for (nMod=0; nMod<4; nMod++) { if (di->GetDigits(i, 0) && di->GetDigits(i, 0)->GetEntriesFast() > 0) { Alieve::ITSModule* m = new Alieve::ITSModule(i, di); - gReve->AddRenderElement(m, relStave); + gEve->AddElement(m, relStave); } ++i; } @@ -94,29 +94,29 @@ void its_raw(const char *input = "rawdata.root", } if (mode & 2) { - Reve::RenderElementList* l = new Reve::RenderElementList("SPD1"); + TEveElementList* l = new TEveElementList("SPD1"); l->SetTitle("SPDs' second layer"); l->SetMainColor((Color_t)2); - gReve->AddRenderElement(l); + gEve->AddElement(l); - for(nsec=0; nsec<10; nsec++) { + for (nsec=0; nsec<10; nsec++) { sSector = bsSector; sSector += nsec; - Reve::RenderElementList* relSector = new Reve::RenderElementList(sSector.Data()); + TEveElementList* relSector = new TEveElementList(sSector.Data()); relSector->SetMainColor((Color_t)2); - gReve->AddRenderElement(relSector, l); - for(nstave=0; nstave<4; nstave++){ + gEve->AddElement(relSector, l); + for (nstave=0; nstave<4; nstave++){ sStave = bsStave; sStave += nstave; - Reve::RenderElementList* relStave = new Reve::RenderElementList(sStave.Data()); + TEveElementList* relStave = new TEveElementList(sStave.Data()); relStave->SetMainColor((Color_t)2); - gReve->AddRenderElement(relStave, relSector); - for(nMod=0; nMod<4; nMod++) + gEve->AddElement(relStave, relSector); + for (nMod=0; nMod<4; nMod++) { if (di->GetDigits(i, 0) && di->GetDigits(i, 0)->GetEntriesFast() > 0) { Alieve::ITSModule* m = new Alieve::ITSModule(i, di); - gReve->AddRenderElement(m, relStave); + gEve->AddElement(m, relStave); } ++i; } @@ -127,20 +127,20 @@ void its_raw(const char *input = "rawdata.root", } if (mode & 4) { - Reve::RenderElementList* l = new Reve::RenderElementList("SDD2"); + TEveElementList* l = new TEveElementList("SDD2"); l->SetTitle("SDDs' first layer"); l->SetMainColor((Color_t)3); - gReve->AddRenderElement(l); + gEve->AddElement(l); - for(nlad=0; nlad<14; nlad++) { + for (nlad=0; nlad<14; nlad++) { sLadder = bsLadder; sLadder += nlad; - Reve::RenderElementList* relLadder = new Reve::RenderElementList(sLadder.Data()); + TEveElementList* relLadder = new TEveElementList(sLadder.Data()); relLadder->SetMainColor((Color_t)3); - gReve->AddRenderElement(relLadder, l); - for(nMod=0; nMod<6; nMod++) { + gEve->AddElement(relLadder, l); + for (nMod=0; nMod<6; nMod++) { Alieve::ITSModule* m = new Alieve::ITSModule(i++, di); - gReve->AddRenderElement(m, relLadder); + gEve->AddElement(m, relLadder); } } } else { @@ -148,19 +148,19 @@ void its_raw(const char *input = "rawdata.root", } if (mode & 8) { - Reve::RenderElementList* l = new Reve::RenderElementList("SDD3"); + TEveElementList* l = new TEveElementList("SDD3"); l->SetTitle("SDDs' second layer"); l->SetMainColor((Color_t)3); - gReve->AddRenderElement(l); - for(nlad=0; nlad<22; nlad++) { + gEve->AddElement(l); + for (nlad=0; nlad<22; nlad++) { sLadder = bsLadder; sLadder += nlad; - Reve::RenderElementList* relLadder = new Reve::RenderElementList(sLadder.Data()); + TEveElementList* relLadder = new TEveElementList(sLadder.Data()); relLadder->SetMainColor((Color_t)3); - gReve->AddRenderElement(relLadder, l); - for(nMod=0; nMod<8; nMod++) { + gEve->AddElement(relLadder, l); + for (nMod=0; nMod<8; nMod++) { Alieve::ITSModule* m = new Alieve::ITSModule(i++, di); - gReve->AddRenderElement(m, relLadder); + gEve->AddElement(m, relLadder); } } } else { @@ -168,19 +168,19 @@ void its_raw(const char *input = "rawdata.root", } if (mode & 16) { - Reve::RenderElementList* l = new Reve::RenderElementList("SSD4"); + TEveElementList* l = new TEveElementList("SSD4"); l->SetTitle("SSDs' first layer"); l->SetMainColor((Color_t)4); - gReve->AddRenderElement(l); - for(nlad=0; nlad<34; nlad++) { + gEve->AddElement(l); + for (nlad=0; nlad<34; nlad++) { sLadder = bsLadder; sLadder += nlad; - Reve::RenderElementList* relLadder = new Reve::RenderElementList(sLadder.Data()); + TEveElementList* relLadder = new TEveElementList(sLadder.Data()); relLadder->SetMainColor((Color_t)4); - gReve->AddRenderElement(relLadder, l); - for(nMod=0; nMod<22; nMod++) { + gEve->AddElement(relLadder, l); + for (nMod=0; nMod<22; nMod++) { Alieve::ITSModule* m = new Alieve::ITSModule(i++, di); - gReve->AddRenderElement(m, relLadder); + gEve->AddElement(m, relLadder); } } } else { @@ -188,24 +188,24 @@ void its_raw(const char *input = "rawdata.root", } if (mode & 32) { - Reve::RenderElementList* l = new Reve::RenderElementList("SSD5"); + TEveElementList* l = new TEveElementList("SSD5"); l->SetTitle("SSDs' second layer"); l->SetMainColor((Color_t)4); - gReve->AddRenderElement(l); - for(nlad=0; nlad<38; nlad++) { + gEve->AddElement(l); + for (nlad=0; nlad<38; nlad++) { sLadder = bsLadder; sLadder += nlad; - Reve::RenderElementList* relLadder = new Reve::RenderElementList(sLadder.Data()); + TEveElementList* relLadder = new TEveElementList(sLadder.Data()); relLadder->SetMainColor((Color_t)4); - gReve->AddRenderElement(relLadder, l); - for(nMod=0; nMod<25; nMod++) { + gEve->AddElement(relLadder, l); + for (nMod=0; nMod<25; nMod++) { Alieve::ITSModule* m = new Alieve::ITSModule(i++, di); - gReve->AddRenderElement(m, relLadder); + gEve->AddElement(m, relLadder); } } } else { i += 38*25; } - gReve->EnableRedraw(); + gEve->EnableRedraw(); } diff --git a/EVE/alice-macros/jetplane.C b/EVE/alice-macros/jetplane.C index 4aa96a6b83b..94a6434d8a3 100644 --- a/EVE/alice-macros/jetplane.C +++ b/EVE/alice-macros/jetplane.C @@ -1,43 +1,42 @@ Alieve::JetPlane* jetplane(Int_t iev) - { - TFile* f = new TFile("aod.root"); - TTree* treeAOD = (TTree*) f->Get("AOD"); - AliAODEvent* aod = new AliAODEvent(); + TFile* f = new TFile("aod.root"); + TTree* treeAOD = (TTree*) f->Get("AOD"); + AliAODEvent* aod = new AliAODEvent(); aod->ReadFromTree(treeAOD); treeAOD->GetEntry(iev); - using namespace Alieve; - JetPlane* jp = new JetPlane(iev); + using namespace Alieve; + JetPlane* jp = new JetPlane(iev); - // Read Jets in current event + // Read Jets in current event - TClonesArray* jets = aod->GetJets(); - Int_t njets = jets->GetEntries(); - printf("Event: %5d Number of jets: %5d \n", iev, njets); + TClonesArray* jets = aod->GetJets(); + Int_t njets = jets->GetEntries(); + printf("Event: %5d Number of jets: %5d \n", iev, njets); - for (Int_t ij = 0; ij < njets; ij++) - { - AliAODJet jet = (AliAODJet) jets->At(ij); - jp->AddJet(jet); - } + for (Int_t ij = 0; ij < njets; ij++) + { + AliAODJet jet = (AliAODJet) jets->At(ij); + jp->AddJet(jet); + } -// Read tracks in current event + // Read tracks in current event - TClonesArray* tracks = aod->GetTracks(); - Int_t ntracks = tracks->GetEntries(); - printf("Event: %5d Number of tracks: %5d \n", iev, ntracks); + TClonesArray* tracks = aod->GetTracks(); + Int_t ntracks = tracks->GetEntries(); + printf("Event: %5d Number of tracks: %5d \n", iev, ntracks); - for (Int_t ij = 0; ij < ntracks; ij++) - { - AliAODTrack track = (AliAODTrack) tracks->At(ij); - jp->AddTrack(track); - } + for (Int_t ij = 0; ij < ntracks; ij++) + { + AliAODTrack track = (AliAODTrack) tracks->At(ij); + jp->AddTrack(track); + } -// Render Jet Plane - gStyle->SetPalette(1, 0); - gReve->AddRenderElement(jp); - gReve->Redraw3D(); + // Render Jet Plane + gStyle->SetPalette(1, 0); + gEve->AddElement(jp); + gEve->Redraw3D(); - return jp; + return jp; } diff --git a/EVE/alice-macros/kine_tracks.C b/EVE/alice-macros/kine_tracks.C index 8ede7ae06f0..0be211b106f 100644 --- a/EVE/alice-macros/kine_tracks.C +++ b/EVE/alice-macros/kine_tracks.C @@ -3,7 +3,7 @@ #include "TParticlePDG.h" -Reve::TrackList* +TEveTrackList* kine_tracks(Double_t min_pt = 0.1, Double_t min_p = 0.2, Bool_t pdg_col = kTRUE, Bool_t recurse = kTRUE, Bool_t use_track_refs = kTRUE) @@ -16,15 +16,15 @@ kine_tracks(Double_t min_pt = 0.1, Double_t min_p = 0.2, return 0; } - gReve->DisableRedraw(); + gEve->DisableRedraw(); - Reve::TrackList* cont = new Reve::TrackList("Kine Tracks"); + TEveTrackList* cont = new TEveTrackList("Kine Tracks"); cont->SetMainColor(Color_t(3)); - Reve::TrackRnrStyle* rnrStyle = cont->GetRnrStyle(); + TEveTrackPropagator* rnrStyle = cont->GetPropagator(); // !!! Watch the '-', apparently different sign convention then for ESD. rnrStyle->SetMagField( - gAlice->Field()->SolenoidField() ); - gReve->AddRenderElement(cont); + gEve->AddElement(cont); Int_t count = 0; Int_t N = stack->GetNtrack(); for (Int_t i=0; iPt() < min_pt && p->P() < min_p) continue; ++count; - Reve::Track* track = new Reve::Track(p, i, rnrStyle); + TEveTrack* track = new TEveTrack(p, i, rnrStyle); //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT @@ -47,7 +47,7 @@ kine_tracks(Double_t min_pt = 0.1, Double_t min_p = 0.2, track->SetStdTitle(); set_track_color(track, pdg_col); - gReve->AddRenderElement(track, cont); + gEve->AddElement(track, cont); if (recurse) kine_daughters(track, stack, min_pt, min_p, pdg_col, recurse); @@ -71,33 +71,33 @@ kine_tracks(Double_t min_pt = 0.1, Double_t min_p = 0.2, cont->UpdateItems(); cont->MakeTracks(recurse); - gReve->EnableRedraw(); - gReve->Redraw3D(); + gEve->EnableRedraw(); + gEve->Redraw3D(); return cont; } -void kine_daughters(Reve::Track* parent, AliStack* stack, +void kine_daughters(TEveTrack* parent, AliStack* stack, Double_t min_pt, Double_t min_p, Bool_t pdg_col, Bool_t recurse) { TParticle *p = stack->Particle(parent->GetLabel()); if (p->GetNDaughters() > 0) { - Reve::TrackRnrStyle* rs = parent->GetRnrStyle(); + TEveTrackPropagator* rs = parent->GetPropagator(); for (int d=p->GetFirstDaughter(); d>0 && d<=p->GetLastDaughter(); ++d) { TParticle* dp = stack->Particle(d); if (dp->Pt() < min_pt && dp->P() < min_p) continue; - Reve::Track* dtrack = new Reve::Track(dp, d, rs); + TEveTrack* dtrack = new TEveTrack(dp, d, rs); char form[1000]; sprintf(form,"%s [%d]", dp->GetName(), d); dtrack->SetName(form); dtrack->SetStdTitle(); set_track_color(dtrack, pdg_col); - gReve->AddRenderElement(dtrack, parent); + gEve->AddElement(dtrack, parent); if (recurse) kine_daughters(dtrack, stack, min_pt, min_p, pdg_col, recurse); @@ -105,7 +105,7 @@ void kine_daughters(Reve::Track* parent, AliStack* stack, } } -Color_t set_track_color(Reve::Track* t, Bool_t pdg_col) +Color_t set_track_color(TEveTrack* t, Bool_t pdg_col) { if (pdg_col) t->SetMainColor(get_pdg_color(t->GetPdg())); @@ -163,11 +163,11 @@ Color_t get_pdg_color(Int_t pdg) /******************************************************************************/ -Reve::RenderElement* +TEveElement* kine_track(Int_t label, Bool_t import_mother = kTRUE, Bool_t import_daughters = kTRUE, Bool_t pdg_col = kTRUE, Bool_t recurse = kTRUE, - Reve::RenderElement* cont = 0) + TEveElement* cont = 0) { // Create mother and daughters tracks with given label. @@ -192,17 +192,17 @@ kine_track(Int_t label, if (import_mother || (import_daughters && p->GetNDaughters())) { - Reve::Track* toptrack = 0; - Reve::TrackList* tracklist = 0; - Reve::TrackRnrStyle* rs = 0; + TEveTrack* toptrack = 0; + TEveTrackList* tracklist = 0; + TEveTrackPropagator* rs = 0; if (cont == 0) { - Reve::TrackList* tlist = new Reve::TrackList + TEveTrackList* tlist = new TEveTrackList (Form("Kinematics of %d", label, p->GetNDaughters())); cont = tlist; - Reve::TrackRnrStyle* rnrStyle = tlist->GetRnrStyle(); + TEveTrackPropagator* rnrStyle = tlist->GetPropagator(); // !!! Watch the '-', apparently different sign convention then for ESD. rnrStyle->SetMagField( - gAlice->Field()->SolenoidField() ); char tooltip[1000]; @@ -211,19 +211,19 @@ kine_track(Int_t label, rnrStyle->fMaxOrbs = 2; rnrStyle->SetEditPathMarks(kTRUE); - gReve->AddRenderElement(cont); - rs = tlist->GetRnrStyle(); + gEve->AddElement(cont); + rs = tlist->GetPropagator(); } else { - // check if container is TrackList or Track (has rnr-style) - Reve::Track* t = dynamic_cast(cont); + // check if container is TEveTrackList or TEveTrack (has rnr-style) + TEveTrack* t = dynamic_cast(cont); if (t) { - rs = t->GetRnrStyle(); + rs = t->GetPropagator(); } else { - Reve::TrackList* l = dynamic_cast(cont); + TEveTrackList* l = dynamic_cast(cont); if (l) - rs = l->GetRnrStyle(); + rs = l->GetPropagator(); else Error("kine_tracks.C", "TrackRenderStyle not set."); } @@ -231,7 +231,7 @@ kine_track(Int_t label, if (import_mother) { - Reve::Track* track = new Reve::Track(p, label, rs); + TEveTrack* track = new TEveTrack(p, label, rs); char form[1000]; sprintf(form,"%s [%d]", p->GetName(), label); track->SetName(form); @@ -239,7 +239,7 @@ kine_track(Int_t label, set_track_color(track, pdg_col); track->MakeTrack(); - gReve->AddRenderElement(track, cont); + gEve->AddElement(track, cont); cont = track; } @@ -248,7 +248,7 @@ kine_track(Int_t label, for (int d=p->GetFirstDaughter(); d>0 && d<=p->GetLastDaughter(); ++d) { TParticle* dp = stack->Particle(d); - Reve::Track* track = new Reve::Track(dp, d, rs); + TEveTrack* track = new TEveTrack(dp, d, rs); char form[1000]; sprintf(form,"%s [%d]", dp->GetName(), d); track->SetName(form); @@ -256,7 +256,7 @@ kine_track(Int_t label, set_track_color(track, pdg_col); track->MakeTrack(); - gReve->AddRenderElement(track, cont); + gEve->AddElement(track, cont); if (recurse) kine_daughters(track, stack, 0, 0, pdg_col, recurse); @@ -265,7 +265,7 @@ kine_track(Int_t label, } cont->UpdateItems(); - gReve->Redraw3D(); + gEve->Redraw3D(); return cont; } diff --git a/EVE/alice-macros/phos_clusters.C b/EVE/alice-macros/phos_clusters.C index 5e104fa046e..1bf63a1b69a 100644 --- a/EVE/alice-macros/phos_clusters.C +++ b/EVE/alice-macros/phos_clusters.C @@ -1,5 +1,5 @@ -Reve::PointSet* phos_clusters(Reve::RenderElement* cont=0) +TEvePointSet* phos_clusters(TEveElement* cont=0) { Alieve::Event::AssertGeometry(); @@ -8,7 +8,7 @@ Reve::PointSet* phos_clusters(Reve::RenderElement* cont=0) TTree *cTree = rl->GetTreeR("PHOS", false); - Reve::PointSet* clusters = new Reve::PointSet(10000); + TEvePointSet* clusters = new TEvePointSet(10000); clusters->SetOwnIds(kTRUE); TObjArray *arr=NULL; @@ -32,9 +32,9 @@ Reve::PointSet* phos_clusters(Reve::RenderElement* cont=0) } } - Warning("phos_clusters"," %d",clusters->Size()); + Warning("phos_clusters"," %d", clusters->Size()); - if(clusters->Size() == 0 && gReve->GetKeepEmptyCont() == kFALSE) { + if(clusters->Size() == 0 && gEve->GetKeepEmptyCont() == kFALSE) { Warning("phos_clusters", "No PHOS clusters"); delete clusters; return 0; @@ -51,10 +51,8 @@ Reve::PointSet* phos_clusters(Reve::RenderElement* cont=0) char tip[1000]; sprintf(tip,"N=%d", clusters->Size()); clusters->SetTitle(tip); - - using namespace Reve; - gReve->AddRenderElement(clusters); - gReve->Redraw3D(); + gEve->AddElement(clusters); + gEve->Redraw3D(); return clusters; } diff --git a/EVE/alice-macros/pmd_digits.C b/EVE/alice-macros/pmd_digits.C index b6a87e60268..d2572d76ace 100644 --- a/EVE/alice-macros/pmd_digits.C +++ b/EVE/alice-macros/pmd_digits.C @@ -18,14 +18,14 @@ void pmd_digits(Int_t mode = 0) // cout << pmdt->GetEntries() << endl; - gReve->DisableRedraw(); + gEve->DisableRedraw(); - Reve::RenderElementList* l = new Reve::RenderElementList("PMD"); + TEveElementList* l = new TEveElementList("PMD"); // l->SetTitle("tooltip"); // l->SetMainColor((Color_t)3); - gReve->AddRenderElement(l); + gEve->AddElement(l); - Reve::RGBAPalette* pal = new Reve::RGBAPalette(20, 1000); + TEveRGBAPalette* pal = new TEveRGBAPalette(20, 1000); pal->SetLimits(0, 1024); Int_t NSM = 0; @@ -78,17 +78,17 @@ void pmd_digits(Int_t mode = 0) zpos = 360.; } - Reve::RenderElementList* lplane = new Reve::RenderElementList(spl.Data()); + TEveElementList* lplane = new TEveElementList(spl.Data()); // l->SetMainColor((Color_t)3); - gReve->AddRenderElement(lplane, l); + gEve->AddElement(lplane, l); for (Int_t iddl = istartDDL; iddl < iendDDL; iddl++) { sddl = bsddl; sddl += iddl; - Reve::RenderElementList* lddl = new Reve::RenderElementList(sddl.Data()); + TEveElementList* lddl = new TEveElementList(sddl.Data()); // l->SetMainColor((Color_t)3); - gReve->AddRenderElement(lddl, lplane); + gEve->AddElement(lddl, lplane); modnumber = iddl*6; @@ -110,14 +110,14 @@ void pmd_digits(Int_t mode = 0) lmodule->SetPalette(pal); if (drawBackPolygons) { - Reve::FrameBox* b = lmodule->GetFrame(); + TEveFrameBox* b = lmodule->GetFrame(); b->SetFrameWidth(1.5); b->SetFrameColor((Color_t) 1); b->SetBackColor ((Color_t) (kTeal - 9)); b->SetFrameFill (kFALSE); b->SetDrawBack (kTRUE); } - gReve->AddRenderElement(lmodule, lddl); + gEve->AddElement(lmodule, lddl); modnumber++; if (iddl == 4 && modnumber == 30) modnumber = 42; } @@ -126,10 +126,7 @@ void pmd_digits(Int_t mode = 0) } - - gReve->EnableRedraw(); - - gReve->Redraw3D(); + gEve->EnableRedraw(); } // ---------------------------------------------------------------------- // diff --git a/EVE/alice-macros/pmd_hits.C b/EVE/alice-macros/pmd_hits.C index 0bb18eef687..4d722be8018 100644 --- a/EVE/alice-macros/pmd_hits.C +++ b/EVE/alice-macros/pmd_hits.C @@ -1,6 +1,6 @@ // $Id$ -Reve::PointSet* +TEvePointSet* pmd_hits(const char *varexp = "fX:fY:fZ", const char *selection = "") { @@ -12,12 +12,12 @@ pmd_hits(const char *varexp = "fX:fY:fZ", //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT //PH on some platforms (alphalinuxgcc, solariscc5, etc.) - //PH Reve::PointSet* points = new Reve::PointSet(Form("PMD Hits '%s'", selection)); + //PH TEvePointSet* points = new TEvePointSet(Form("PMD Hits '%s'", selection)); char form[1000]; sprintf(form,"PMD Hits '%s'", selection); - Reve::PointSet* points = new Reve::PointSet(form); + TEvePointSet* points = new TEvePointSet(form); - TPointSelector ps(ht, points, varexp, selection); + TEvePointSelector ps(ht, points, varexp, selection); ps.Select(); //PH points->SetTitle(Form("N=%d", points->Size())); @@ -26,8 +26,8 @@ pmd_hits(const char *varexp = "fX:fY:fZ", points->SetMarkerSize(.5); points->SetMarkerColor((Color_t)2); - gReve->AddRenderElement(points); - gReve->Redraw3D(); + gEve->AddElement(points); + gEve->Redraw3D(); return points; } diff --git a/EVE/alice-macros/pmd_raw.C b/EVE/alice-macros/pmd_raw.C index ba326e951d5..0c3f2d1c7f7 100644 --- a/EVE/alice-macros/pmd_raw.C +++ b/EVE/alice-macros/pmd_raw.C @@ -15,16 +15,16 @@ void pmd_raw(Int_t mode = 0) AliRawReaderRoot reader("raw.root",ievt); AliPMDRawStream stream(&reader); - gReve->DisableRedraw(); + gEve->DisableRedraw(); - Reve::RenderElementList* l = new Reve::RenderElementList("PMD"); + TEveElementList* l = new TEveElementList("PMD"); // l->SetTitle("PMD"); // l->SetMainColor((Color_t)3); - gReve->AddRenderElement(l); + gEve->AddElement(l); Int_t NSM = 0; Int_t istartDDL = 0; - Int_t iendDDL = 0; + Int_t iendDDL = 0; Int_t modnumber = 0; Int_t istartPlane = 0; Int_t iendPlane = 0; @@ -72,18 +72,18 @@ void pmd_raw(Int_t mode = 0) zpos = 360.; } - Reve::RenderElementList* lplane = new Reve::RenderElementList(spl.Data()); + TEveElementList* lplane = new TEveElementList(spl.Data()); // l->SetMainColor((Color_t)3); - gReve->AddRenderElement(lplane, l); + gEve->AddElement(lplane, l); for (Int_t iddl = istartDDL; iddl < iendDDL; iddl++) //for (Int_t iddl = 0; iddl < 1; iddl++) { sddl = bsddl; sddl += iddl; - Reve::RenderElementList* lddl = new Reve::RenderElementList(sddl.Data()); + TEveElementList* lddl = new TEveElementList(sddl.Data()); // l->SetMainColor((Color_t)3); - gReve->AddRenderElement(ddl, lplane); + gEve->AddElement(ddl, lplane); modnumber = iddl*6; @@ -104,7 +104,7 @@ void pmd_raw(Int_t mode = 0) Alieve::PMDModule *lmodule = new Alieve::PMDModule(); lmodule->SetPosition(0.,0.,zpos); lmodule->DisplayRawData(modnumber,pmdddlcont); - gReve->AddRenderElement(lmodule, lddl); + gEve->AddElement(lmodule, lddl); modnumber++; if (iddl == 4 && modnumber == 30) modnumber = 42; } @@ -113,10 +113,7 @@ void pmd_raw(Int_t mode = 0) } } - - gReve->EnableRedraw(); - - gReve->Redraw3D(); + gEve->EnableRedraw(); } // ---------------------------------------------------------------------- // diff --git a/EVE/alice-macros/primary_vertex.C b/EVE/alice-macros/primary_vertex.C index 3fc6f03ed0e..593bda0e0ad 100644 --- a/EVE/alice-macros/primary_vertex.C +++ b/EVE/alice-macros/primary_vertex.C @@ -1,4 +1,4 @@ -// $Header$ +// $Id$ TPolyMarker3D* make_vertex_marker(AliESDVertex* v, const Text_t* name ) { @@ -16,36 +16,35 @@ TPolyMarker3D* make_vertex_marker(AliESDVertex* v, const Text_t* name ) return m; } -Reve::BoxSet* make_vertex_boxes(AliESDVertex* v) +TEveBoxSet* make_vertex_boxes(AliESDVertex* v) { Double_t x[3], e[3]; v->GetXYZ(x); v->GetSigmaXYZ(e); - Reve::BoxSet* bs; + TEveBoxSet* bs; - bs = new BoxSet("+- 10 x 10 x 20mm"); - bs->SetRenderMode(Reve::BoxSet::RM_Line); - bs->AddBox(Reve::Box(-1, x[0], x[1], x[2], 1, 1, 2)); + bs = new TEveBoxSet("+- 10 x 10 x 20mm"); + bs->SetRenderMode(TEveBoxSet::RM_TEveLine); + bs->AddBox(Box(-1, x[0], x[1], x[2], 1, 1, 2)); bs->SetMainColor((Color_t) 2); - gReve->AddRenderElement(bs); + gEve->AddElement(bs); - bs = new BoxSet("+- 30 sigma_r x 10 sigma_z"); - bs->SetRenderMode(Reve::BoxSet::RM_Line); - bs->AddBox(Reve::Box(-1, x[0], x[1], x[2], 30*e[0], 30*e[1], 10*e[2])); + bs = new TEveBoxSet("+- 30 sigma_r x 10 sigma_z"); + bs->SetRenderMode(TEveBoxSet::RM_TEveLine); + bs->AddBox(Box(-1, x[0], x[1], x[2], 30*e[0], 30*e[1], 10*e[2])); bs->SetMainColor((Color_t) 3); - gReve->AddRenderElement(bs); + gEve->AddElement(bs); - gReve->Redraw3D(); + gEve->Redraw3D(); } void register_vertex_marker(TPolyMarker3D* m) { - using namespace Reve; Color_t* colp = FindColorVar(m, "fMarkerColor"); - RenderElementObjPtr* rnrEl = new RenderElementObjPtr(m, *colp); - gReve->AddRenderElement(rnrEl); - gReve->Redraw3D(); + TEveElementObjectPtr* rnrEl = new TEveElementObjectPtr(m, *colp); + gEve->AddElement(rnrEl); + gEve->Redraw3D(); } void primary_vertex_primitive(Bool_t showSPD=kTRUE, Bool_t showBoxes=kFALSE) @@ -59,7 +58,7 @@ void primary_vertex_primitive(Bool_t showSPD=kTRUE, Bool_t showBoxes=kFALSE) pvm->SetMarkerSize(1.4); register_vertex_marker(pvm); - if(showSPD) { + if (showSPD) { AliESDVertex* spdv = esd->GetVertex(); TPolyMarker3D* spdvm = make_vertex_marker(spdv, "SPD Vertex"); spdvm->SetMarkerStyle(2); @@ -67,23 +66,21 @@ void primary_vertex_primitive(Bool_t showSPD=kTRUE, Bool_t showBoxes=kFALSE) register_vertex_marker(spdvm); } - if(showBoxes) + if (showBoxes) make_vertex_boxes(pv); } /**************************************************************************/ -Reve::StraightLineSet* ESDvertex_lineset(AliESDVertex* v, const Text_t* name) +TEveStraightLineSet* ESDvertex_lineset(AliESDVertex* v, const Text_t* name) { - using namespace Reve; - Double_t x[3], e[3]; v->GetXYZ(x); v->GetSigmaXYZ(e); printf("%16s: %f %f %f - %f %f %f\n", name, x[0], x[1], x[2], e[0], e[1], e[2]); // dimensions - Reve::StraightLineSet* ls = new Reve::StraightLineSet(); + TEveStraightLineSet* ls = new TEveStraightLineSet(); ls->SetName(name); ls->AddLine(e[0], 0, 0, -e[0], 0, 0); ls->AddLine(0, e[1], 0, 0, -e[1], 0); @@ -100,14 +97,12 @@ Reve::StraightLineSet* ESDvertex_lineset(AliESDVertex* v, const Text_t* name) return ls; } -void make_vertex_ellipses(Reve::StraightLineSet* ls, AliESDVertex* v, Bool_t ellipseUseSigma) +void make_vertex_ellipses(TEveStraightLineSet* ls, AliESDVertex* v, Bool_t ellipseUseSigma) { - using namespace Reve; - Double_t x[3], e[3]; v->GetXYZ(x); v->GetSigmaXYZ(e); - if(ellipseUseSigma) + if (ellipseUseSigma) { e[0] *= 30; e[1] *= 30; e[2] *= 10; ls->SetMarkerStyle(5); @@ -129,17 +124,17 @@ void make_vertex_ellipses(Reve::StraightLineSet* ls, AliESDVertex* v, Bool_t ell Float_t b, a, phi; a = e[0]; b = e[1]; - for(Int_t i = 0; iAddLine(a*TMath::Cos(i*S) , b*TMath::Sin(i*S) , 0, a*TMath::Cos(i*S+S), b*TMath::Sin(i*S+S), 0); a = e[0]; b = e[2]; - for(Int_t i = 0; iAddLine(a*TMath::Cos(i*S) , 0, b*TMath::Sin(i*S), a*TMath::Cos(i*S+S), 0, b*TMath::Sin(i*S+S)); a = e[1]; b = e[2]; - for(Int_t i = 0; iAddLine(0, a*TMath::Cos(i*S) , b*TMath::Sin(i*S), 0, a*TMath::Cos(i*S+S), b*TMath::Sin(i*S+S)); } @@ -147,18 +142,18 @@ void make_vertex_ellipses(Reve::StraightLineSet* ls, AliESDVertex* v, Bool_t ell void primary_vertex(Bool_t showSPD=kTRUE, Bool_t rnrEllipse=kTRUE) { AliESDEvent* esd = Alieve::Event::AssertESD(); - Reve::StraightLineSet* ls; + TEveStraightLineSet* ls; AliESDVertex* PV = esd->GetPrimaryVertex(); ls = ESDvertex_lineset(PV, "Primary Vertex"); - if(rnrEllipse) make_vertex_ellipses(ls, PV, kTRUE); - gReve->AddRenderElement(ls); + if (rnrEllipse) make_vertex_ellipses(ls, PV, kTRUE); + gEve->AddElement(ls); - if(showSPD) + if (showSPD) { AliESDVertex* SPDV = esd->GetVertex(); ls = ESDvertex_lineset(SPDV, "SPD Vertex"); - if(rnrEllipse) make_vertex_ellipses(ls, SPDV, kFALSE); - gReve->AddRenderElement(ls); + if (rnrEllipse) make_vertex_ellipses(ls, SPDV, kFALSE); + gEve->AddElement(ls); } } diff --git a/EVE/alice-macros/primary_vertex_tracks.C b/EVE/alice-macros/primary_vertex_tracks.C index 3f185cb5ead..33520446a6f 100644 --- a/EVE/alice-macros/primary_vertex_tracks.C +++ b/EVE/alice-macros/primary_vertex_tracks.C @@ -1,29 +1,29 @@ -Reve::TrackList* primary_vertex_tracks() +TEveTrackList* primary_vertex_tracks() { - Reve::LoadMacro("esd_tracks.C"); + TEveUtil::LoadMacro("esd_tracks.C"); AliESDEvent *esd = Alieve::Event::AssertESD(); AliESDVertex *pv = esd->GetPrimaryVertex(); - Reve::TrackList* cont = new Reve::TrackList("Tracks for Primary Vertex"); + TEveTrackList* cont = new TEveTrackList("Tracks for Primary Vertex"); cont->SetMainColor(Color_t(7)); - Reve::TrackRnrStyle* rnrStyle = cont->GetRnrStyle(); + TEveTrackPropagator* rnrStyle = cont->GetPropagator(); rnrStyle->SetMagField( esd->GetMagneticField() ); rnrStyle->fRnrFV = kTRUE; rnrStyle->fFVAtt->SetMarkerColor(2); - gReve->AddRenderElement(cont); + gEve->AddElement(cont); for (Int_t n=0; nGetNIndices(); n++) { AliESDtrack* at = esd->GetTrack(pv->GetIndices()[n]); - Reve::Track* track = esd_make_track(rnrStyle, n, at, at); + TEveTrack* track = esd_make_track(rnrStyle, n, at, at); track->SetLineWidth(4); track->SetLineColor(cont->GetMainColor()); track->SetLineStyle(7); - gReve->AddRenderElement(track, cont); + gEve->AddElement(track, cont); } cont->MakeTracks(); - gReve->Redraw3D(); + gEve->Redraw3D(); return cont; } diff --git a/EVE/alice-macros/region_marker.C b/EVE/alice-macros/region_marker.C index 54ecd581088..918b477bd1c 100644 --- a/EVE/alice-macros/region_marker.C +++ b/EVE/alice-macros/region_marker.C @@ -1,4 +1,4 @@ -// $Header$ +// $Id$ void region_marker(Float_t a=10, Float_t b=10, Float_t c=20, Float_t x=0, Float_t y=0, Float_t z=0) @@ -16,10 +16,8 @@ void region_marker(Float_t a=10, Float_t b=10, Float_t c=20, mark->SetPoint(5, x+a, y-b, z-c); mark->SetPoint(6, x-a, y+b, z-c); mark->SetPoint(7, x-a, y-b, z-c); - - using namespace Reve; Color_t* colp = FindColorVar(mark, "fMarkerColor"); - RenderElementObjPtr* rnrEl = new RenderElementObjPtr(mark, *colp); - gReve->AddGlobalRenderElement(rnrEl); - gReve->Redraw3D(); + TEveElementObjectPtr* rnrEl = new TEveElementObjectPtr(mark, *colp); + gEve->AddGlobalElement(rnrEl); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/t0_digits.C b/EVE/alice-macros/t0_digits.C index 6f515a62629..55fdc7e9a4d 100644 --- a/EVE/alice-macros/t0_digits.C +++ b/EVE/alice-macros/t0_digits.C @@ -4,33 +4,19 @@ namespace Alieve { class Event; } - - void t0_digits() { AliRunLoader* rl = Alieve::Event::AssertRunLoader(); - Int_t g_currentEvent = Alieve::gEvent->GetEventId(); - cout<LoadDigits("T0"); TTree* dt = rl->GetTreeD("T0", false); - //Alieve::T0DigitsInfo* di = new Alieve::T0DigitsInfo(); - // di->SetDTree(dt); - //di->Dump(); - // AliSTARTdigit *digits = 0; - + AliT0digit *digits = 0; dt->SetBranchAddress("T0", &digits); dt->GetEntry(0); gStyle->SetPalette(1, 0); - // gReve->DisableRedraw(); Alieve::T0Module::MakeModules(digits); - - //Alieve::T0Module* m = new Alieve::T0Module(di); - // - //gReve->EnableRedraw(); - //m->LoadQuadsDigits(); } diff --git a/EVE/alice-macros/t0_hits.C b/EVE/alice-macros/t0_hits.C index 7914289c9bc..443ac8c0945 100644 --- a/EVE/alice-macros/t0_hits.C +++ b/EVE/alice-macros/t0_hits.C @@ -1,8 +1,8 @@ // $Id$ -Reve::PointSet* +TEvePointSet* t0_hits(const char *varexp = "T0.fX:T0.fY:T0.fZ", - const char *selection = "") + const char *selection = "") { // Extracts T0 hits. @@ -20,22 +20,22 @@ t0_hits(const char *varexp = "T0.fX:T0.fY:T0.fZ", ht->SetBranchAddress("T0",&hits); ht->GetEvent(it); - Int_t nHits = hits->GetEntriesFast(); - // printf("Found %d hits in track %d. \n",nHits,it); + // Int_t nHits = hits->GetEntriesFast(); + // printf("Found %d hits in track %d.\n", nHits, it); } - Reve::PointSet* points = new Reve::PointSet(Form("T0 Hits '%s'", selection)); - points->SetSourceCS(TPointSelectorConsumer::TVT_XYZ); + TEvePointSet* points = new TEvePointSet(Form("T0 Hits '%s'", selection)); + points->SetSourceCS(TEvePointSelectorConsumer::kTVT_XYZ); - TPointSelector ps(ht, points, varexp, selection); + TEvePointSelector ps(ht, points, varexp, selection); ps.Select(); points->SetTitle(Form("N=%d", points->Size())); points->SetMarkerSize(.5); points->SetMarkerColor((Color_t)3); - gReve->AddRenderElement(points); - gReve->Redraw3D(); + gEve->AddElement(points); + gEve->Redraw3D(); return points; } diff --git a/EVE/alice-macros/tof_digits.C b/EVE/alice-macros/tof_digits.C index 62355fb78ae..426cda534b7 100644 --- a/EVE/alice-macros/tof_digits.C +++ b/EVE/alice-macros/tof_digits.C @@ -4,7 +4,7 @@ void tof_digits() Int_t nDigitsInVolume[3] = {-1, -1, -1}; Int_t nStrips=19; - TGeoManager *localGeoManager = (TGeoManager*)gReve->GetGeometry("./geometry.root");//"$REVESYS/alice-data/alice_fullgeo.root"); + TGeoManager *localGeoManager = (TGeoManager*)gEve->GetGeometry("./geometry.root");//"$REVESYS/alice-data/alice_fullgeo.root"); if (!localGeoManager) { printf("ERROR: no TGeo\n"); } @@ -21,12 +21,12 @@ void tof_digits() AliTOFGeometry* g = di->fGeom; gStyle->SetPalette(1, 0); - gReve->DisableRedraw(); + gEve->DisableRedraw(); - Reve::RenderElementList* ll = new Reve::RenderElementList("TOF"); + TEveElementList* ll = new TEveElementList("TOF"); ll->SetTitle("TOF detector"); ll->SetMainColor((Color_t)2); - gReve->AddRenderElement(ll); + gEve->AddElement(ll); for(Int_t iSector=0; iSectorNSectors(); iSector++) { @@ -34,9 +34,9 @@ void tof_digits() Alieve::TOFSector* m = new Alieve::TOFSector(localGeoManager,iSector,array); - gReve->AddRenderElement(m, ll); + gEve->AddElement(m, ll); } - gReve->EnableRedraw(); + gEve->EnableRedraw(); } diff --git a/EVE/alice-macros/tof_digits_sector.C b/EVE/alice-macros/tof_digits_sector.C index 0d4fbace5b3..56ffec5591d 100644 --- a/EVE/alice-macros/tof_digits_sector.C +++ b/EVE/alice-macros/tof_digits_sector.C @@ -2,7 +2,7 @@ void tof_digits_sector(Int_t sector=0) { Int_t nDigitsInVolume[3] = {-1, -1, -1}; Int_t nStrips=19; - TGeoManager *localGeoManager = (TGeoManager*)gReve->GetGeometry("./geometry.root");//"$REVESYS/alice-data/alice_fullgeo.root"); + TGeoManager *localGeoManager = (TGeoManager*)gEve->GetGeometry("./geometry.root");//"$REVESYS/alice-data/alice_fullgeo.root"); if (!localGeoManager) { printf("ERROR: no TGeo\n"); } @@ -18,21 +18,21 @@ void tof_digits_sector(Int_t sector=0) AliTOFGeometry* g = di->fGeom; gStyle->SetPalette(1, 0); - gReve->DisableRedraw(); + gEve->DisableRedraw(); Char_t sectorName[100]; Char_t sectorTitle[200]; - Reve::RenderElementList* ll = new Reve::RenderElementList("TOF"); + TEveElementList* ll = new TEveElementList("TOF"); ll->SetTitle("TOF detector"); ll->SetMainColor((Color_t)2); - gReve->AddRenderElement(ll); + gEve->AddElement(ll); Alieve::TOFSector* m = new Alieve::TOFSector(localGeoManager, sector, dt); m->SetName("Sector"); m->SetAutoTrans(kFALSE); m->SetTrans(); - gReve->AddRenderElement(m, ll); + gEve->AddElement(m, ll); - gReve->EnableRedraw(); + gEve->EnableRedraw(); } diff --git a/EVE/alice-macros/tof_digits_strips.C b/EVE/alice-macros/tof_digits_strips.C index 6e393a53a39..22afd424bab 100644 --- a/EVE/alice-macros/tof_digits_strips.C +++ b/EVE/alice-macros/tof_digits_strips.C @@ -4,7 +4,7 @@ void tof_digits_strips() Int_t nDigitsInVolume[3] = {-1, -1, -1}; Int_t nStrips=19; - TGeoManager *localGeoManager = (TGeoManager*)gReve->GetGeometry("./geometry.root");//"$REVESYS/alice-data/alice_fullgeo.root"); + TGeoManager *localGeoManager = (TGeoManager*)gEve->GetGeometry("./geometry.root");//"$REVESYS/alice-data/alice_fullgeo.root"); if (!localGeoManager) { printf("ERROR: no TGeo\n"); } @@ -21,7 +21,7 @@ void tof_digits_strips() AliTOFGeometry* g = di->fGeom; gStyle->SetPalette(1, 0); - gReve->DisableRedraw(); + gEve->DisableRedraw(); TString sPlate; TString bsPlate="Plate"; @@ -35,18 +35,18 @@ void tof_digits_strips() Char_t sectorName[100]; Char_t sectorTitle[200]; - Reve::RenderElementList* ll = new Reve::RenderElementList("TOF"); + TEveElementList* ll = new TEveElementList("TOF"); ll->SetTitle("TOF detector"); ll->SetMainColor((Color_t)2); - gReve->AddRenderElement(ll); + gEve->AddElement(ll); for(Int_t iSector=0; iSectorNSectors(); iSector++) { sprintf(sectorName,"Sector%2i",iSector); - Reve::RenderElementList* l = new Reve::RenderElementList(sectorName); + TEveElementList* l = new TEveElementList(sectorName); l->SetTitle(sectorTitle); l->SetMainColor((Color_t)2); - gReve->AddRenderElement(l, ll); + gEve->AddElement(l, ll); for(Int_t iPlate=0; iPlateNPlates(); iPlate++) { @@ -55,9 +55,9 @@ void tof_digits_strips() sPlate=bsPlate; sPlate+=iPlate; - Reve::RenderElementList* relPlate = new Reve::RenderElementList(sPlate.Data()); + TEveElementList* relPlate = new TEveElementList(sPlate.Data()); relPlate->SetMainColor((Color_t)2); - gReve->AddRenderElement(relPlaete, l); + gEve->AddElement(relPlaete, l); for(Int_t iStrip=0; iStripGetDigits(iSector,iPlate, iStrip); Alieve::TOFStrip* m = new Alieve::TOFStrip(localGeoManager,iSector,iPlate,iStrip,array); - gReve->AddRenderElement(m, relPlate); + gEve->AddElement(m, relPlate); } } } - gReve->EnableRedraw(); + gEve->EnableRedraw(); } diff --git a/EVE/alice-macros/tof_hits.C b/EVE/alice-macros/tof_hits.C index 0b049920550..4cb5bab2508 100644 --- a/EVE/alice-macros/tof_hits.C +++ b/EVE/alice-macros/tof_hits.C @@ -1,9 +1,9 @@ // $Id$ -Reve::PointSet* +TEvePointSet* tof_hits(const char *varexp = "fX:fY:fZ", const char *selection = "", - Reve::RenderElement* cont) + TEveElement* cont) { AliRunLoader* rl = Alieve::Event::AssertRunLoader(); rl->LoadHits("TOF"); @@ -13,15 +13,15 @@ tof_hits(const char *varexp = "fX:fY:fZ", //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT //PH on some platforms (alphalinuxgcc, solariscc5, etc.) - //PH Reve::PointSet* points = new Reve::PointSet(Form("TOF Hits '%s'", selection)); + //PH TEvePointSet* points = new TEvePointSet(Form("TOF Hits '%s'", selection)); char form[1000]; sprintf(form,"TOF Hits '%s'", selection); - Reve::PointSet* points = new Reve::PointSet(form); + TEvePointSet* points = new TEvePointSet(form); - TPointSelector ps(ht, points, varexp, selection); + TEvePointSelector ps(ht, points, varexp, selection); ps.Select(); - if( points->Size() == 0 && gReve->GetKeepEmptyCont() == kFALSE) { + if( points->Size() == 0 && gEve->GetKeepEmptyCont() == kFALSE) { Warning("tof_hits", Form("No hits match '%s'", selection)); delete points; return 0; @@ -33,8 +33,8 @@ tof_hits(const char *varexp = "fX:fY:fZ", points->SetMarkerSize(.5); points->SetMarkerColor((Color_t)2); - gReve->AddRenderElement(points, cont); - gReve->Redraw3D(); + gEve->AddElement(points, cont); + gEve->Redraw3D(); return points; } diff --git a/EVE/alice-macros/tpc_calib_viewer.C b/EVE/alice-macros/tpc_calib_viewer.C index 55216379ebe..88982a07501 100644 --- a/EVE/alice-macros/tpc_calib_viewer.C +++ b/EVE/alice-macros/tpc_calib_viewer.C @@ -1,6 +1,6 @@ void tpc_calib_viewer(const char* file="CalibTree.root") { - Reve::RGBrowser* b = gReve->GetBrowser(); + TEveBrowser* b = gEve->GetBrowser(); b->StartEmbedding(1); TGMainFrame* frmMain = new TGMainFrame(gClient->GetRoot(), 1000, 600); diff --git a/EVE/alice-macros/tpc_clusters.C b/EVE/alice-macros/tpc_clusters.C index 5ec89296dc5..7550fbcdba0 100644 --- a/EVE/alice-macros/tpc_clusters.C +++ b/EVE/alice-macros/tpc_clusters.C @@ -1,16 +1,16 @@ #ifdef __CINT__ -namespace Reve +namespace TEveUtil { -class RenderElement; -class PointSet; +class TEveElement; +class TEvePointSet; } #else -#include -#include -#include +#include +#include +#include #include #include @@ -19,13 +19,13 @@ class PointSet; #endif -Reve::PointSet* tpc_clusters(Reve::RenderElement* cont=0, Float_t maxR=270) +TEvePointSet* tpc_clusters(TEveElement* cont=0, Float_t maxR=270) { const Int_t kMaxCl=100*160; Alieve::Event::AssertGeometry(); - Reve::PointSet* clusters = new Reve::PointSet(kMaxCl); + TEvePointSet* clusters = new TEvePointSet(kMaxCl); clusters->SetOwnIds(kTRUE); AliRunLoader* rl = Alieve::Event::AssertRunLoader(); @@ -62,7 +62,7 @@ Reve::PointSet* tpc_clusters(Reve::RenderElement* cont=0, Float_t maxR=270) delete clrow; - if(clusters->Size() == 0 && gReve->GetKeepEmptyCont() == kFALSE) { + if(clusters->Size() == 0 && gEve->GetKeepEmptyCont() == kFALSE) { Warning("tpc_clusters", "No TPC clusters"); delete clusters; return 0; @@ -79,10 +79,8 @@ Reve::PointSet* tpc_clusters(Reve::RenderElement* cont=0, Float_t maxR=270) char tip[1000]; sprintf(tip,"N=%d", clusters->Size()); clusters->SetTitle(tip); - - using namespace Reve; - gReve->AddRenderElement(clusters, cont); - gReve->Redraw3D(); + gEve->AddElement(clusters, cont); + gEve->Redraw3D(); return clusters; } diff --git a/EVE/alice-macros/tpc_digits.C b/EVE/alice-macros/tpc_digits.C index 90214d6a89b..3ed72c820a1 100644 --- a/EVE/alice-macros/tpc_digits.C +++ b/EVE/alice-macros/tpc_digits.C @@ -42,10 +42,10 @@ void tpc_digits(Int_t mode=1) Alieve::TPCSector2D* s = new Alieve::TPCSector2D(); s->SetFrameColor(col); s->SetDataSource(g_tpc_data); - gReve->AddRenderElement(s); - gReve->Redraw3D(); + gEve->AddElement(s); + gEve->Redraw3D(); - //TGLViewer* cam = gReve->GetGLViewer(); + //TGLViewer* cam = gEve->GetGLViewer(); //cam->SetCurrentCamera(TGLViewer::kCameraOrthoXOY) ; //cam->SetOrthoCamera(TGLViewer::kCameraOrthoXOY, 2*left, 2*right, 2*top, bottom); //printf("%f %f %f %f\n", left, right, top, bottom); @@ -54,12 +54,12 @@ void tpc_digits(Int_t mode=1) } case 1: { // Display all sectors - gReve->DisableRedraw(); + gEve->DisableRedraw(); { - Reve::RenderElementList* l = new Reve::RenderElementList("TPC plate 1"); + TEveElementList* l = new TEveElementList("TPC plate 1"); l->SetTitle("TPC Plate"); l->SetMainColor(Color_t(col)); - gReve->AddRenderElement(l); + gEve->AddElement(l); for(Int_t i = 0; i<18; i++) { Alieve::TPCSector2D* s = new Alieve::TPCSector2D(Form("TPCSector2D %d", i)); @@ -67,25 +67,25 @@ void tpc_digits(Int_t mode=1) s->SetDataSource(g_tpc_data); s->SetFrameColor(col); s->SetAutoTrans(kTRUE); - gReve->AddRenderElement(s, l); + gEve->AddElement(s, l); } } { - Reve::RenderElementList* l = new Reve::RenderElementList("TPC plate 2"); + TEveElementList* l = new TEveElementList("TPC plate 2"); l->SetTitle("TPC Plate"); l->SetMainColor(Color_t(col)); - gReve->AddRenderElement(l); + gEve->AddElement(l); for(Int_t i = 18; i<36; i++) { Alieve::TPCSector2D* s = new Alieve::TPCSector2D(Form("TPCSector2D %d", i)); s->SetSectorID(i); s->SetDataSource(g_tpc_data); s->SetFrameColor(col); s->SetAutoTrans(kTRUE); - gReve->AddRenderElement(s, l); + gEve->AddElement(s, l); } } - gReve->EnableRedraw(); + gEve->EnableRedraw(); break; } @@ -94,18 +94,18 @@ void tpc_digits(Int_t mode=1) Alieve::TPCSector3D* s = new Alieve::TPCSector3D(); s->SetFrameColor(col); s->SetDataSource(g_tpc_data); - gReve->AddRenderElement(s); - gReve->Redraw3D(); + gEve->AddElement(s); + gEve->Redraw3D(); break; } case 3: { // Display all sectors in 3D - gReve->DisableRedraw(); + gEve->DisableRedraw(); { - Reve::RenderElementList* l = new Reve::RenderElementList("TPC plate 1"); + TEveElementList* l = new TEveElementList("TPC plate 1"); l->SetTitle("TPC Plate"); l->SetMainColor(Color_t(col)); - gReve->AddRenderElement(l); + gEve->AddElement(l); for(Int_t i = 0; i<18; i++) { Alieve::TPCSector3D* s = new Alieve::TPCSector3D(Form("TPCSector3D %d", i)); @@ -113,25 +113,25 @@ void tpc_digits(Int_t mode=1) s->SetDataSource(g_tpc_data); s->SetFrameColor(col); s->SetAutoTrans(kTRUE); - gReve->AddRenderElement(s, l); + gEve->AddElement(s, l); } } { - Reve::RenderElementList* l = new Reve::RenderElementList("TPC plate 2"); + TEveElementList* l = new TEveElementList("TPC plate 2"); l->SetTitle("TPC Plate"); l->SetMainColor(Color_t(col)); - gReve->AddRenderElement(l); + gEve->AddElement(l); for(Int_t i = 18; i<36; i++) { Alieve::TPCSector3D* s = new Alieve::TPCSector3D(Form("TPCSector3D %d", i)); s->SetSectorID(i); s->SetDataSource(g_tpc_data); s->SetFrameColor(col); s->SetAutoTrans(kTRUE); - gReve->AddRenderElement(s, l); + gEve->AddElement(s, l); } } - gReve->EnableRedraw(); + gEve->EnableRedraw(); break; } @@ -159,11 +159,11 @@ void tpc_digits_2drange(Int_t start, Int_t end) gStyle->SetPalette(1, 0); Color_t col = 36; - gReve->DisableRedraw(); + gEve->DisableRedraw(); { - Reve::RenderElementList* l = new Reve::RenderElementList("TPC sectors"); + TEveElementList* l = new TEveElementList("TPC sectors"); l->SetMainColor(Color_t(col)); - gReve->AddRenderElement(l); + gEve->AddElement(l); for(Int_t i=start; i<=end; i++) { Alieve::TPCSector2D* s = new Alieve::TPCSector2D(); @@ -171,8 +171,8 @@ void tpc_digits_2drange(Int_t start, Int_t end) s->SetDataSource(g_tpc_data); s->SetFrameColor(col); s->SetAutoTrans(kTRUE); - gReve->AddRenderElement(s, l); + gEve->AddElement(s, l); } } - gReve->EnableRedraw(); + gEve->EnableRedraw(); } diff --git a/EVE/alice-macros/tpc_hits.C b/EVE/alice-macros/tpc_hits.C index 8170cd23f6d..e19b00e0149 100644 --- a/EVE/alice-macros/tpc_hits.C +++ b/EVE/alice-macros/tpc_hits.C @@ -1,9 +1,9 @@ // $Id$ -Reve::PointSet* +TEvePointSet* tpc_hits(const char *varexp = "TPC2.fArray.fR:TPC2.fArray.fFi:TPC2.fArray.fZ", const char *selection = "TPC2.fArray.fR>80", - Reve::RenderElement* cont = 0) + TEveElement* cont = 0) { // Extracts 'major' TPC hits (not the compressed ones). // This gives ~2.5% of all hits. @@ -16,16 +16,16 @@ tpc_hits(const char *varexp = "TPC2.fArray.fR:TPC2.fArray.fFi:TPC2.fArray.fZ" //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT //PH on some platforms (alphalinuxgcc, solariscc5, etc.) - //PH Reve::PointSet* points = new Reve::PointSet(Form("TPC Hits '%s'", selection)); + //PH TEvePointSet* points = new TEvePointSet(Form("TPC Hits '%s'", selection)); char form[1000]; sprintf(form,"TPC Hits '%s'", selection); - Reve::PointSet* points = new Reve::PointSet(form); - points->SetSourceCS(TPointSelectorConsumer::TVT_RPhiZ); + TEvePointSet* points = new TEvePointSet(form); + points->SetSourceCS(TEvePointSelectorConsumer::kTVT_RPhiZ); - TPointSelector ps(ht, points, varexp, selection); + TEvePointSelector ps(ht, points, varexp, selection); ps.Select(); - if (points->Size() == 0 && gReve->GetKeepEmptyCont() == kFALSE) { + if (points->Size() == 0 && gEve->GetKeepEmptyCont() == kFALSE) { Warning("tpc_hits", Form("No hits match '%s'", selection)); delete points; return 0; @@ -37,8 +37,8 @@ tpc_hits(const char *varexp = "TPC2.fArray.fR:TPC2.fArray.fFi:TPC2.fArray.fZ" points->SetMarkerSize(.5); points->SetMarkerColor((Color_t)3); - gReve->AddRenderElement(points, cont); - gReve->Redraw3D(); + gEve->AddElement(points, cont); + gEve->Redraw3D(); return points; } diff --git a/EVE/alice-macros/tpc_hits_charge_split.C b/EVE/alice-macros/tpc_hits_charge_split.C index 4a9fd6ec981..2a77dd3acea 100644 --- a/EVE/alice-macros/tpc_hits_charge_split.C +++ b/EVE/alice-macros/tpc_hits_charge_split.C @@ -13,19 +13,19 @@ void tpc_hits_charge_split(const char *varexp = TTree* ht = rl->GetTreeH("TPC", false); - Reve::PointSetArray* l = new Reve::PointSetArray("TPC hits - Log-Charge Slices", ""); - l->SetSourceCS(TPointSelectorConsumer::TVT_RPhiZ); + TEvePointSetArray* l = new TEvePointSetArray("TPC hits - Log-Charge Slices", ""); + l->SetSourceCS(TEvePointSelectorConsumer::kTVT_RPhiZ); l->SetMarkerColor((Color_t)3); l->SetMarkerStyle(20); // full circle l->SetMarkerSize(.5); - gReve->AddRenderElement(l); + gEve->AddElement(l); l->InitBins("Log Charge", 20, 0, 5); - TPointSelector ps(ht, l, varexp, selection); + TEvePointSelector ps(ht, l, varexp, selection); ps.Select(); l->CloseBins(); - gReve->Redraw3D(); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/tpc_hits_eta_split.C b/EVE/alice-macros/tpc_hits_eta_split.C index 31463dd739e..850cfa56760 100644 --- a/EVE/alice-macros/tpc_hits_eta_split.C +++ b/EVE/alice-macros/tpc_hits_eta_split.C @@ -13,19 +13,19 @@ void tpc_hits_eta_split(const char *varexp = TTree* ht = rl->GetTreeH("TPC", false); - Reve::PointSetArray* l = new Reve::PointSetArray("TPC hits - Eta Slices", ""); - l->SetSourceCS(TPointSelectorConsumer::TVT_RPhiZ); + TEvePointSetArray* l = new TEvePointSetArray("TPC hits - Eta Slices", ""); + l->SetSourceCS(TEvePointSelectorConsumer::kTVT_RPhiZ); l->SetMarkerColor((Color_t)3); l->SetMarkerStyle(20); // full circle l->SetMarkerSize(.5); - gReve->AddRenderElement(l); + gEve->AddElement(l); l->InitBins("Eta", 20, -2, 2); - TPointSelector ps(ht, l, varexp, selection); + TEvePointSelector ps(ht, l, varexp, selection); ps.Select(); l->CloseBins(); - gReve->Redraw3D(); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/trd_hits.C b/EVE/alice-macros/trd_hits.C index bb45b1e26f9..95b3d99e498 100644 --- a/EVE/alice-macros/trd_hits.C +++ b/EVE/alice-macros/trd_hits.C @@ -1,9 +1,9 @@ // $Id$ -Reve::PointSet* +TEvePointSet* trd_hits(const char *varexp = "fX:fY:fZ", const char *selection = "", - Reve::RenderElement* cont = 0) + TEveElement* cont = 0) { AliRunLoader* rl = Alieve::Event::AssertRunLoader(); rl->LoadHits("TRD"); @@ -13,15 +13,15 @@ trd_hits(const char *varexp = "fX:fY:fZ", //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT //PH on some platforms (alphalinuxgcc, solariscc5, etc.) - //PH Reve::PointSet* points = new Reve::PointSet(Form("TRD Hits '%s'", selection)); + //PH TEvePointSet* points = new TEvePointSet(Form("TRD Hits '%s'", selection)); char form[1000]; sprintf(form,"TRD Hits '%s'", selection); - Reve::PointSet* points = new Reve::PointSet(form); + TEvePointSet* points = new TEvePointSet(form); - TPointSelector ps(ht, points, varexp, selection); + TEvePointSelector ps(ht, points, varexp, selection); ps.Select(); - if (points->Size() == 0 && gReve->GetKeepEmptyCont() == kFALSE) { + if (points->Size() == 0 && gEve->GetKeepEmptyCont() == kFALSE) { Warning("trd_hits", Form("No hits match '%s'", selection)); delete points; return 0; @@ -33,8 +33,8 @@ trd_hits(const char *varexp = "fX:fY:fZ", points->SetMarkerSize(.5); points->SetMarkerColor((Color_t)7); - gReve->AddRenderElement(points, cont); - gReve->Redraw3D(); + gEve->AddElement(points, cont); + gEve->Redraw3D(); return points; } diff --git a/EVE/alice-macros/trd_hits_z_split.C b/EVE/alice-macros/trd_hits_z_split.C index cae3fa0dcc4..902346503ec 100644 --- a/EVE/alice-macros/trd_hits_z_split.C +++ b/EVE/alice-macros/trd_hits_z_split.C @@ -8,18 +8,18 @@ void trd_hits_z_split(const char *varexp = "fX:fY:fZ:fZ", TTree* ht = rl->GetTreeH("TRD", false); - Reve::PointSetArray* l = new Reve::PointSetArray("TRD hits - Z Slices", ""); + TEvePointSetArray* l = new TEvePointSetArray("TRD hits - Z Slices", ""); l->SetMarkerColor((Color_t)7); l->SetMarkerStyle(20); // full circle l->SetMarkerSize(.5); - gReve->AddRenderElement(l); + gEve->AddElement(l); l->InitBins("Z", 20, -360, 360); - TPointSelector ps(ht, l, varexp, selection); + TEvePointSelector ps(ht, l, varexp, selection); ps.Select(); l->CloseBins(); - gReve->Redraw3D(); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/vzero_digits.C b/EVE/alice-macros/vzero_digits.C index c6d732a2389..cede8179e4d 100644 --- a/EVE/alice-macros/vzero_digits.C +++ b/EVE/alice-macros/vzero_digits.C @@ -30,11 +30,11 @@ void vzero_digits() Float_t v[12]; - Reve::QuadSet* modR = new Reve::QuadSet("V0R"); - modR->Reset(Reve::QuadSet::QT_FreeQuad, kFALSE, 32); + TEveQuadSet* modR = new TEveQuadSet("V0R"); + modR->Reset(TEveQuadSet::kQT_FreeQuad, kFALSE, 32); - Reve::QuadSet* modL = new Reve::QuadSet("V0L"); - modL->Reset(Reve::QuadSet::QT_FreeQuad, kFALSE, 32); + TEveQuadSet* modL = new TEveQuadSet("V0L"); + modL->Reset(TEveQuadSet::kQT_FreeQuad, kFALSE, 32); Int_t numEntr = dca->GetEntriesFast(); for (Int_t entr=0; entrRefHMTrans().SetPos(0, 0, 324); modR->RefHMTrans().SetPos(0, 0, -84); - gReve->AddRenderElement(modL); - gReve->AddRenderElement(modR); + gEve->AddElement(modL); + gEve->AddElement(modR); - gReve->Redraw3D(); + gEve->Redraw3D(); } diff --git a/EVE/alice-macros/vzero_hits.C b/EVE/alice-macros/vzero_hits.C index 6704df335f9..73422dafa72 100644 --- a/EVE/alice-macros/vzero_hits.C +++ b/EVE/alice-macros/vzero_hits.C @@ -1,6 +1,6 @@ // $Id$ -Reve::PointSet* +TEvePointSet* vzero_hits(const char *varexp = "fX:fY:fZ", const char *selection = "") { @@ -12,12 +12,12 @@ vzero_hits(const char *varexp = "fX:fY:fZ", //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT //PH on some platforms (alphalinuxgcc, solariscc5, etc.) - //PH Reve::PointSet* points = new Reve::PointSet(Form("VZERO Hits '%s'", selection)); + //PH TEvePointSet* points = new TEvePointSet(Form("VZERO Hits '%s'", selection)); char form[1000]; sprintf(form,"VZERO Hits '%s'", selection); - Reve::PointSet* points = new Reve::PointSet(form); + TEvePointSet* points = new TEvePointSet(form); - TPointSelector ps(ht, points, varexp, selection); + TEvePointSelector ps(ht, points, varexp, selection); ps.Select(); //PH points->SetTitle(Form("N=%d", points->Size())); @@ -26,8 +26,8 @@ vzero_hits(const char *varexp = "fX:fY:fZ", points->SetMarkerSize(.5); points->SetMarkerColor((Color_t)2); - gReve->AddRenderElement(points); - gReve->Redraw3D(); + gEve->AddElement(points); + gEve->Redraw3D(); return points; } diff --git a/EVE/binalieve.pkg b/EVE/binalieve.pkg index 4ff0121847d..af01add302c 100644 --- a/EVE/binalieve.pkg +++ b/EVE/binalieve.pkg @@ -3,7 +3,7 @@ CSRCS := EINCLUDE := ELIBSDIR := -ELIBS := Reve Alieve \ +ELIBS := Alieve \ MUONevaluation MUONgeometry MUONrec MUONsim MUONbase MUONtrigger MUONraw MUONcalib MUONmapping MUONcore \ TPCbase TPCsim TPCrec TPCfast \ ITSbase ITSsim ITSrec PMDbase PMDsim PMDrec TRDbase \ @@ -20,7 +20,7 @@ ELIBS := Reve Alieve \ RAWDatabase RAWDatarec RAWDatasim \ HLTbase XMLParser -PACKBLIBS := $(ROOTCLIBS) $(ROOTPLIBS) -lTreePlayer -lGeomPainter -lGed -lFTGL -lRGL $(SYSLIBS) +PACKBLIBS := $(ROOTCLIBS) $(ROOTPLIBS) -lTreePlayer -lGeomPainter -lGed -lFTGL -lRGL -lEve $(SYSLIBS) ifeq (macosx,$(ALICE_TARGET)) diff --git a/EVE/binreve.pkg b/EVE/binreve.pkg deleted file mode 100644 index 41637f5fc47..00000000000 --- a/EVE/binreve.pkg +++ /dev/null @@ -1,17 +0,0 @@ -SRCS := Reve/reve_main/reve_main.cxx -CSRCS := - -EINCLUDE := -ELIBSDIR := -ELIBS := Reve - -PACKBLIBS := $(ROOTCLIBS) -lTreePlayer -lGeomPainter -lGed \ - -L$(shell root-config --libdir)/$(dir $(shell root-config --version)) -lFTGL -lRGL \ - $(SYSLIBS) - -ifeq (macosx,$(ALICE_TARGET)) - -# On Mac OS X gcc we need GL and GLU -ELIBS+=GL GLU -ELIBSDIR+=/usr/X11R6/lib/ -endif diff --git a/EVE/hlt-macros/command_queue.C b/EVE/hlt-macros/command_queue.C index 92e3abbe7f4..ce0588c76bc 100644 --- a/EVE/hlt-macros/command_queue.C +++ b/EVE/hlt-macros/command_queue.C @@ -98,12 +98,12 @@ void command_queue() } // ============================================================================ -// Reve side +// TEveUtil side // ============================================================================ -#include -#include -#include +#include +#include +#include #include @@ -112,24 +112,24 @@ void make_crap(void* arg) Int_t num = 1024; TRandom rnd(0); - Reve::PointSet* ps = new Reve::PointSet("Testus", num); + TEvePointSet* ps = new TEvePointSet("Testus", num); for (Int_t i=0; iSetNextPoint(rnd.Uniform(-100, 100), rnd.Uniform(-100, 100), rnd.Uniform(-100, 100)); } ps->SetMainColor((Color_t)kRed); - printf("make_crap() -> produced Reve::PointSet* %p)\n", ps); + printf("make_crap() -> produced TEvePointSet* %p)\n", ps); ((CommandQueue*)arg)->RegisterCommand - (Form("register_crap((Reve::RenderElement*)0x%lx)", ps)); + (Form("register_crap((TEveElement*)0x%lx)", ps)); } -void register_crap(Reve::RenderElement* el) +void register_crap(TEveElement* el) { - printf("register_crap(Reve::RenderElement* %p)\n", el); - gReve->AddRenderElement(el); - gReve->Redraw3D(); + printf("register_crap(TEveElement* %p)\n", el); + gEve->AddElement(el); + gEve->Redraw3D(); } void test() diff --git a/EVE/hlt-macros/homer_display.C b/EVE/hlt-macros/homer_display.C index e5f8bf59e44..5325046a6e1 100644 --- a/EVE/hlt-macros/homer_display.C +++ b/EVE/hlt-macros/homer_display.C @@ -22,11 +22,9 @@ class AliRawReaderMemory; class AliEVEHOMERManager; class AliHLTHOMERBlockDesc; -namespace Reve { -class PointSet; -class TrackList; -class Track; -} +class TEvePointSet; +class TEveTrackList; +class TEveTrack; namespace Alieve { class TPCLoader; @@ -34,14 +32,12 @@ class TPCData; class TPCSector2D; class TPCSector3D; } - -using namespace Reve; using namespace Alieve; TPCLoader* loader = 0; TPCData* tpcdata = 0; -PointSet* tpc_cls = 0; -TrackList* tpc_trk = 0; +TEvePointSet* tpc_cls = 0; +TEveTrackList* tpc_trk = 0; AliRawReaderMemory* memreader = 0; AliEVEHOMERManager* homerM = 0; @@ -70,7 +66,7 @@ void homer_display() homerM = new AliEVEHOMERManager("/local/home/hlt/TPC-SCC1-Generate.xml"); // homerM = new AliEVEHOMERManager("/local/home/hlt/sampleConfig2.xml"); - gReve->AddToListTree(homerM, kTRUE); + gEve->AddToListTree(homerM, kTRUE); homerM->CreateHOMERSourcesList(); // homerM->SelectRawTPC(); @@ -90,16 +86,16 @@ void homer_display() tpcdata->SetLoadThreshold(0); // tpcdata->SetAutoPedestal(kTRUE); // For non-zero suppressed data. tpcdata->SetAutoPedestal(kFALSE); - gReve->AddRenderElement(loader); + gEve->AddElement(loader); - tpc_cls = new Reve::PointSet("TPC Clusters"); + tpc_cls = new TEvePointSet("TPC Clusters"); tpc_cls->SetMainColor((Color_t)kRed); - gReve->AddRenderElement(tpc_cls); + gEve->AddElement(tpc_cls); - tpc_trk = new TrackList("TPC Tracks"); - gReve->AddRenderElement(tpc_trk); + tpc_trk = new TEveTrackList("TPC Tracks"); + gEve->AddElement(tpc_trk); tpc_trk->SetMainColor(Color_t(6)); - Reve::TrackRnrStyle* rnrStyle = tpc_trk->GetRnrStyle(); + TEveTrackPropagator* rnrStyle = tpc_trk->GetPropagator(); rnrStyle->SetMagField( 5 ); nextEvent(); @@ -152,7 +148,7 @@ void nextEvent() tpc_cls->ResetBBox(); tpc_trk->MakeTracks(); - gReve->Redraw3D(1, 1); + gEve->Redraw3D(1, 1); } //**************************************************************************** @@ -180,14 +176,14 @@ void process_tpc_clusters(AliHLTHOMERBlockDesc* b) } //**************************************************************************** -Reve::Track* esd_make_track(Reve::TrackRnrStyle* rnrStyle, +TEveTrack* esd_make_track(TEveTrackPropagator* rnrStyle, Int_t index, AliESDtrack* at, AliExternalTrackParam* tp=0) { // Helper function Double_t pbuf[3], vbuf[3]; - Reve::RecTrack rt; + TEveRecTrack rt; if(tp == 0) tp = at; @@ -202,7 +198,7 @@ Reve::Track* esd_make_track(Reve::TrackRnrStyle* rnrStyle, Double_t ep = at->GetP(), mc = at->GetMass(); rt.beta = ep/TMath::Sqrt(ep*ep + mc*mc); - Reve::Track* track = new Reve::Track(&rt, rnrStyle); + TEveTrack* track = new TEveTrack(&rt, rnrStyle); //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT //PH on some platforms (alphalinuxgcc, solariscc5, etc.) @@ -211,7 +207,7 @@ Reve::Track* esd_make_track(Reve::TrackRnrStyle* rnrStyle, //PH rt.sign*TMath::Hypot(rt.P.x, rt.P.y), rt.P.z, //PH rt.V.x, rt.V.y, rt.V.z)); char form[1000]; - sprintf(form,"Track %d", rt.index); + sprintf(form,"TEveTrack %d", rt.index); track->SetName(form); track->SetStdTitle(); return track; @@ -222,16 +218,16 @@ void process_tpc_tracks(AliHLTHOMERBlockDesc* b) { AliESDEvent* esd = (AliESDEvent*) b->GetTObject(); - Reve::TrackRnrStyle* rnrStyle = tpc_trk->GetRnrStyle(); + TEveTrackPropagator* rnrStyle = tpc_trk->GetPropagator(); for (Int_t n=0; nGetNumberOfTracks(); n++) { AliESDtrack *at = esd->GetTrack(n); AliExternalTrackParam *tp = at; - Reve::Track* track = esd_make_track(rnrStyle, n, at, tp); + TEveTrack* track = esd_make_track(rnrStyle, n, at, tp); track->SetAttLineAttMarker(tpc_trk); - gReve->AddRenderElement(track, tpc_trk); + gEve->AddElement(track, tpc_trk); } } @@ -239,16 +235,16 @@ void process_tpc_tracks(AliHLTHOMERBlockDesc* b) //**************************************************************************** void process_tpc_xxxx(AliESDEvent* esd) { - Reve::TrackRnrStyle* rnrStyle = tpc_trk->GetRnrStyle(); + TEveTrackPropagator* rnrStyle = tpc_trk->GetPropagator(); for (Int_t n=0; nGetNumberOfTracks(); n++) { AliESDtrack *at = esd->GetTrack(n); AliExternalTrackParam *tp = at; - Reve::Track* track = esd_make_track(rnrStyle, n, at, tp); + TEveTrack* track = esd_make_track(rnrStyle, n, at, tp); track->SetAttLineAttMarker(tpc_trk); - gReve->AddRenderElement(track, tpc_trk); + gEve->AddElement(track, tpc_trk); } } @@ -274,9 +270,9 @@ root [5] esdTree->GetEntry(0) root [6] esd->GetNumberOfTracks() (const Int_t)(275) root [7] process_tpc_xxxx(esd) -root [8] gReve->Redraw3D( +root [8] gEve->Redraw3D( void Redraw3D(Bool_t resetCameras = kFALSE, Bool_t dropLogicals = kFALSE) -root [8] gReve->Redraw3D(1,1) +root [8] gEve->Redraw3D(1,1) root [9] trk_cnt->Elem variable "trk_cnt" not defined. @@ -295,7 +291,7 @@ SelectByP SelectByP root [10] tpc_trk->SelectByPt( void SelectByPt(Float_t min_pt, Float_t max_pt) -void SelectByPt(Float_t min_pt, Float_t max_pt, Reve::RenderElement* el) +void SelectByPt(Float_t min_pt, Float_t max_pt, TEveElement* el) root [10] tpc_trk->SelectByPt(0,1000000000000) root [11] tpc_trk->MakeTracks( void MakeTracks(Bool_t recurse = kTRUE) diff --git a/EVE/hlt-macros/rootlogon.C b/EVE/hlt-macros/rootlogon.C index 1213313895b..0c89190eb87 100644 --- a/EVE/hlt-macros/rootlogon.C +++ b/EVE/hlt-macros/rootlogon.C @@ -5,7 +5,7 @@ TString includePath = "-I${ALICE_ROOT}/include "; includePath += "-I${ALICE_ROOT}/EVE "; includePath += "-I${ALICE_ROOT}/EVE/Alieve "; - includePath += "-I${ALICE_ROOT}/EVE/Reve "; + includePath += "-I${ALICE_ROOT}/EVE/TEveUtil "; includePath += "-I${ALICE_ROOT}/HLT/BASE "; includePath += "-I${ALICE_ROOT}/HLT/TPCLib "; includePath += "-I${ALICE_ROOT}/HLT/BASE/HOMER "; diff --git a/EVE/icons/fontdefault.txf b/EVE/icons/fontdefault.txf deleted file mode 100644 index c333664759acad232f9de747c2cfcdbda716f3bd..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3220 zcmeH|&vO(-6vtmr&-83Io$MAaI7?yz0R==%FN-A6$c7&(K|~Y`_ye64Srj)IG2(&< zv$e(Ug#%Sy_J8n_6J?c`+1e_&>>uF4!|)fl#~cjt+p`_u9xhfnTT}D-zIpw+-|N@2 ztBaLVWp3XFMnr+RC7vAj7q~AGm#ZtBZ2W#EThfX{{or2=KL`F4K5WINA@Dgcfycl* z;lox0?E>SDIS0N$R_s3o-cF*Q9=TKiUnG&F6_;kg3x-dDzc+jie2rZAB;ae)XJq#g zo>y@1AjX;CbR9fH$s}8qpbULU0zNKn0Don87+fL;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p-!i$#~?~ zvEsn7zARr8sjYl$(u2oDuUO59z+x5%KF%9KyClkxz6WPZp9dTPP?4;IkGT>ktxJk! z`uR4F=?T}^E5K3nMXFAVnvd=6MjBMy&R!d38pv{RZD_Gt0w1EqgyY;CdN{kIFvhM~ zU0kfhdbr;2bPM}HjZ%A#$CX;Fykp>aA~zbB_!$ZA*GPdcS^M-1?qiej5&rTk6Mi!1 zSSDLIW?PdRLF%Q|QbqUAkTSjE{iI+Y;{Ey}xYYJuy_I8pL4qVQmJeA)PVtaxxJLW9 zn4l&O(#A^Lt5AmVC3*iLX`_u-gMXK^AYE_ygz*n?zw9xA(r`KF8a&iNIutp#{=wlM z#bc)HHG}C0QBgs9Y7u)Ls!{m2YfNP7V^%|bNp_J~e!N=3=4evWMuBRCi7v1jzF8r= z$SUxk;|kGBO#8));`wMb=W=Dj7ZG{fE@@fz+pNVayWn@}%O>hnZSBk0Gq-$}2sLNY zJQb0g31 z%jwnsokTSD;y^OuHOWHUc~Xy(LvZQ9Jdn)q#p*E3+?{hC-ee& zw|tZnt2|Wrx@hc;?Uy*ImkDWBI{3=?nFyTW_7s5M^=~gjrlN=*qjYT!Jd%TYB}kaQ z#69ge+?w-8Eg!dV3ko}0m&2H8^!(lfY%;8-d8cbx5_AnDc<$4_;A zZI3{V5A}t=414fcb{Tk#Rnhe`dk*FEBXE40K4ZCa& zTW;ZB)D<~5ohHT~V%5OWxqq?dbBO=3dzqZ4E6quK5Z}osHDr+e0^8I|&&78_^54jh z467^WHb1uFtNyFJmzuqL)!@w8_EY{@yVa`)FUf<|jkR8Vaa&vaFjzHD^y-%_>Z#U2 zB|6)ym!_U c #454545", -", c #626262", -"' c #B2B2B2", -") c #545454", -"! c #3D3D3D", -"~ c #888888", -"{ c #E4E4E4", -"] c #F7F7F7", -"^ c #121212", -"/ c #616161", -"( c #858585", -"_ c #DCDCDC", -": c #000000", -"< c #5A5A5A", -"[ c #FDFDFD", -"} c #393939", -"| c #0C0C0C", -"1 c #F4F4F4", -"2 c #585858", -"3 c #737373", -"4 c #2D2D2D", -"5 c #F9F9F9", -"6 c #EDEDED", -"7 c #D9D9D9", -"8 c #FCFCFC", -"9 c #6B6B6B", -"0 c #606060", -"a c #B8B8B8", -"b c #A0A0A0", -"c c #D4D4D4", -"................", -"..............+@", -"............#$%&", -"..........#*=-;.", -"..........>,'...", -".......).!~{]...", -".......^/(_.....", -".....>:::<;.....", -".....[}|$1].....", -".....2345.......", -"...6!78-........", -"...97...........", -"..0.............", -".=a.............", -"=b..............", -"c1.............."}; diff --git a/EVE/icons/viewer.xpm b/EVE/icons/viewer.xpm deleted file mode 100644 index e4b4b71c364..00000000000 --- a/EVE/icons/viewer.xpm +++ /dev/null @@ -1,108 +0,0 @@ -/* XPM */ -static char * tes_xpm[] = { -"16 16 89 1", -" c #FFFFFF", -". c #FCFCFC", -"+ c #CCCCCC", -"@ c #A0A0A0", -"# c #8D8D8D", -"$ c #939393", -"% c #B4B4B4", -"& c #EEEEEE", -"* c #E4E4E4", -"= c #737373", -"- c #161616", -"; c #000000", -"> c #0D0D0D", -", c #2F2F2F", -"' c #202020", -") c #515151", -"! c #FEFEFE", -"~ c #949494", -"{ c #0B0B0B", -"] c #060606", -"^ c #5A5A5A", -"/ c #BBBBBB", -"( c #F9F9F9", -"_ c #D3D3D3", -": c #A2A2A2", -"< c #606060", -"[ c #070707", -"} c #6D6D6D", -"| c #E2E2E2", -"1 c #8A8A8A", -"2 c #222222", -"3 c #F1F1F1", -"4 c #636363", -"5 c #555555", -"6 c #DFDFDF", -"7 c #4C4C4C", -"8 c #363636", -"9 c #A4A4A4", -"0 c #1D1D1D", -"a c #B7B7B7", -"b c #D8D8D8", -"c c #3D3D3D", -"d c #0F0F0F", -"e c #4F4F4F", -"f c #E9E9E9", -"g c #F6F6F6", -"h c #F7F7F7", -"i c #1A1A1A", -"j c #414141", -"k c #ECECEC", -"l c #EDEDED", -"m c #2B2B2B", -"n c #282828", -"o c #808080", -"p c #646464", -"q c #C5C5C5", -"r c #0A0A0A", -"s c #565656", -"t c #333333", -"u c #525252", -"v c #EFEFEF", -"w c #959595", -"x c #4E4E4E", -"y c #DDDDDD", -"z c #464646", -"A c #CBCBCB", -"B c #585858", -"C c #BABABA", -"D c #111111", -"E c #2E2E2E", -"F c #5E5E5E", -"G c #050505", -"H c #818181", -"I c #3A3A3A", -"J c #DCDCDC", -"K c #505050", -"L c #F5F5F5", -"M c #1C1C1C", -"N c #ACACAC", -"O c #5F5F5F", -"P c #626262", -"Q c #DBDBDB", -"R c #B3B3B3", -"S c #FDFDFD", -"T c #E6E6E6", -"U c #F4F4F4", -"V c #6F6F6F", -"W c #747474", -"X c #E0E0E0", -" ", -" ", -" .+@#$%& ", -" *=-;;;>,')+", -" !~{;;]^/( _:", -" .<;;[}| 123 ", -" 4;;56 78 ", -" 9;0a bcdefg. ", -"hijk9lmno{pqrs. ", -"9tg uv;w x8yzA! ", -"BC !D&EiFGH.! ", -"I. !d=JK,oLM^! ", -"N O;PAQRS4^T ", -" UVmtWX ", -" ", -" "}; diff --git a/EVE/libReve.pkg b/EVE/libReve.pkg deleted file mode 100644 index 95c0d22c9d3..00000000000 --- a/EVE/libReve.pkg +++ /dev/null @@ -1,8 +0,0 @@ -# $Header$ - -ORGSRCS := $(wildcard EVE/Reve/*.cxx) -SRCS := $(patsubst EVE/%, %, ${ORGSRCS}) -HDRS := $(SRCS:.cxx=.h) -DHDR := Reve/LinkDef.h - -all-EVE: all-Reve all-reve all-Alieve all-alieve diff --git a/EVE/macros/alieve_create_vsd.C b/EVE/macros/alieve_create_vsd.C index b493540273f..458cbca45cf 100644 --- a/EVE/macros/alieve_create_vsd.C +++ b/EVE/macros/alieve_create_vsd.C @@ -11,7 +11,7 @@ void alieve_create_vsd() gSystem->Load("libReve"); gSystem->Load("libAlieve"); - Reve::DisablePODTObjectStreamers(); + DisablePODTObjectStreamers(); TGeoManager::Import("geometry.root"); diff --git a/EVE/macros/alieve_init.C b/EVE/macros/alieve_init.C index 2afab1256ca..2626e107acf 100644 --- a/EVE/macros/alieve_init.C +++ b/EVE/macros/alieve_init.C @@ -1,4 +1,4 @@ -// $Header$ +// $Id$ #ifndef __CINT_ #include @@ -9,16 +9,12 @@ void alieve_init(const Text_t* path = ".", Int_t event=0, const Text_t* cdburi = 0, Bool_t assert_runloader=kFALSE, Bool_t assert_esd=kFALSE) { - using namespace std; - - // Set-up environment, load libraries. - Reve::SetupEnvironment(); - - Info("alieve_init", "Adding standard macros."); + TString hack = gSystem->pwd(); // Problem with TGFileBrowser cding alieve_init_import_macros(); + gSystem->cd(hack); - // Reve::AssertMacro("region_marker.C"); + // AssertMacro("region_marker.C"); gSystem->ProcessEvents(); @@ -29,7 +25,7 @@ void alieve_init(const Text_t* path = ".", Int_t event=0, printf("Opening event %d from '%s' ...", event, path); fflush(stdout); Alieve::gEvent = new Alieve::Event(path, event); printf(" done.\n"); - gReve->AddEvent(Alieve::gEvent); + gEve->AddEvent(Alieve::gEvent); } } @@ -41,12 +37,12 @@ void alieve_init_import_macros() TString macdir("$(REVESYS)/alice-macros"); gSystem->ExpandPathName(macdir); - TFolder* f = gReve->GetMacroFolder(); + TFolder* f = gEve->GetMacroFolder(); void* dirhandle = gSystem->OpenDirectory(macdir.Data()); if(dirhandle != 0) { char* filename; TPRegexp re("\.C$"); - list names; + std::list names; while((filename = gSystem->GetDirEntry(dirhandle)) != 0) { if(re.Match(filename)) { names.push_back(filename); @@ -56,12 +52,12 @@ void alieve_init_import_macros() //PH The line below is replaced waiting for a fix in Root //PH which permits to use variable siza arguments in CINT //PH on some platforms (alphalinuxgcc, solariscc5, etc.) - // f->Add(new Reve::RMacro(Form("%s/%s", macdir.Data(), filename))); + // f->Add(new TEveMacro(Form("%s/%s", macdir.Data(), filename))); char fullName[1000]; - for (list::iterator si=names.begin(); si!=names.end(); ++si) + for (std::list::iterator si=names.begin(); si!=names.end(); ++si) { sprintf(fullName,"%s/%s", macdir.Data(), si->c_str()); - f->Add(new Reve::RMacro(fullName)); + f->Add(new TEveMacro(fullName)); } } gSystem->FreeDirectory(dirhandle); @@ -71,8 +67,8 @@ void alieve_init_import_macros() (new TSystemDirectory(macdir.Data(), macdir.Data())); { - Reve::RGBrowser *br = gReve->GetBrowser(); - TGFileBrowser *fb = 0; + TEveBrowser *br = gEve->GetBrowser(); + TGFileBrowser *fb = 0; fb = br->GetFileBrowser(); fb->GotoDir(macdir); { @@ -84,5 +80,5 @@ void alieve_init_import_macros() br->SetTabTitle("Macros", 0); br->SetTab(0, 0); } - } + } } diff --git a/EVE/macros/alieve_loadlibs.C b/EVE/macros/alieve_loadlibs.C index 8ba5488c530..12f6612e342 100644 --- a/EVE/macros/alieve_loadlibs.C +++ b/EVE/macros/alieve_loadlibs.C @@ -1,4 +1,4 @@ -// $Header$ +// $Id$ void alieve_loadlibs () { diff --git a/EVE/macros/isegv.C b/EVE/macros/isegv.C index 147f2e595ba..17d3556adf1 100644 --- a/EVE/macros/isegv.C +++ b/EVE/macros/isegv.C @@ -1,4 +1,4 @@ -// $Header$ +// $Id$ // Cause ROOT to properly crash and dump core on SigSEGV. { diff --git a/EVE/macros/reve_lineset_test.C b/EVE/macros/reve_lineset_test.C deleted file mode 100644 index 78a2bee2602..00000000000 --- a/EVE/macros/reve_lineset_test.C +++ /dev/null @@ -1,25 +0,0 @@ -// $Header$ - -Reve::StraightLineSet* reve_lineset_test(Int_t nlines = 40, Int_t nmarkers = 4) -{ - Reve::StraightLineSet* ls = new Reve::StraightLineSet(); - - TRandom r(0); - Float_t s = 100; - - for(Int_t i = 0; iAddLine( r.Uniform(-s,s), r.Uniform(-s,s), r.Uniform(-s,s), - r.Uniform(-s,s), r.Uniform(-s,s), r.Uniform(-s,s)); - // add random number of markers - Int_t nm = Int_t(nmarkers* r.Rndm()); - for(Int_t m = 0; m < nm; m++) { - ls->AddMarker(i, r.Rndm()); - } - } - - gReve->AddRenderElement(ls); - gReve->Redraw3D(); - - return ls; -} diff --git a/EVE/macros/reve_load_vsd.C b/EVE/macros/reve_load_vsd.C deleted file mode 100644 index b1c9a4cee64..00000000000 --- a/EVE/macros/reve_load_vsd.C +++ /dev/null @@ -1,7 +0,0 @@ -// $Header$ - -void reve_load_vsd(const Text_t* vsd = "AliVSD.root") -{ - gReve->GetSelector()->LoadVSD(vsd); - gReve->GetSelector()->SelectHits(); -} diff --git a/EVE/macros/reve_quad_test.C b/EVE/macros/reve_quad_test.C deleted file mode 100644 index c0424798535..00000000000 --- a/EVE/macros/reve_quad_test.C +++ /dev/null @@ -1,200 +0,0 @@ -// $Header$ - -Reve::QuadSet* reve_quad_test(Float_t x=0, Float_t y=0, Float_t z=0, - Int_t num=100, Bool_t register=kTRUE) -{ - TRandom r(0); - - gStyle->SetPalette(1, 0); - - Reve::RGBAPalette* pal = new Reve::RGBAPalette(0, 130); - - Reve::QuadSet* q = new Reve::QuadSet("RectangleXY"); - q->SetPalette(pal); - q->Reset(Reve::QuadSet::QT_RectangleXY, kFALSE, 32); - for (Int_t i=0; iAddQuad(r.Uniform(-10, 10), r.Uniform(-10, 10), r.Uniform(-10, 10), - r.Uniform(0.2, 1), r.Uniform(0.2, 1)); - q->QuadValue(r.Uniform(0, 130)); - } - q->RefitPlex(); - - Reve::ZTrans& t = q->RefHMTrans(); - t.SetPos(x, y, z); - - if (register) - { - gReve->AddRenderElement(q); - gReve->Redraw3D(); - } - - return q; -} - -Reve::QuadSet* reve_quad_test_emc(Float_t x=0, Float_t y=0, Float_t z=0, - Int_t num=100) -{ - TRandom r(0); - - gStyle->SetPalette(1, 0); - - Reve::QuadSet* q = new Reve::QuadSet("EMC Supermodule"); - q->SetOwnIds(kTRUE); - q->Reset(Reve::QuadSet::QT_RectangleXZFixedDimY, kFALSE, 32); - q->SetDefWidth(8); - q->SetDefHeight(8); - - for (Int_t i=0; iAddQuad(r.Uniform(-100, 100), r.Uniform(-100, 100)); - q->QuadValue(r.Uniform(0, 130)); - q->AddId(new TNamed(Form("Cell %d", i))); - } - q->RefitPlex(); - - Reve::ZTrans& t = q->RefHMTrans(); - t.SetPos(x, y, z); - - gReve->AddRenderElement(q); - gReve->Redraw3D(); - - return q; -} - -Reve::QuadSet* reve_quad_test_circ() -{ - TRandom r(0); - - gStyle->SetPalette(1, 0); - - Reve::QuadSet* q = new Reve::QuadSet("Pepe"); - q->Reset(Reve::QuadSet::QT_RectangleXY, kFALSE, 32); - - Float_t R = 10, dW = 1, dH = .5; - for (Int_t i=0; i<12; ++i) { - Float_t x = R * TMath::Cos(TMath::TwoPi()*i/12); - Float_t y = R * TMath::Sin(TMath::TwoPi()*i/12); - q->AddQuad(x-dW, y-dH, r.Uniform(-1, 1), 2*dW, 2*dH); - q->QuadValue(r.Uniform(0, 130)); - } - q->RefitPlex(); - - Reve::ZTrans& t = q->RefHMTrans(); - t.SetPos(0, 0, 300); - - gReve->AddRenderElement(q); - gReve->Redraw3D(); - - return q; -} - -Reve::QuadSet* reve_quad_test_hex(Float_t x=0, Float_t y=0, Float_t z=0, - Int_t num=100, Bool_t register=kTRUE) -{ - TRandom r(0); - - gStyle->SetPalette(1, 0); - - { - Reve::QuadSet* q = new Reve::QuadSet("HexagonXY"); - q->Reset(Reve::QuadSet::QT_HexagonXY, kFALSE, 32); - for (Int_t i=0; iAddHexagon(r.Uniform(-10, 10), r.Uniform(-10, 10), r.Uniform(-10, 10), - r.Uniform(0.2, 1)); - q->QuadValue(r.Uniform(0, 120)); - } - q->RefitPlex(); - - Reve::ZTrans& t = q->RefHMTrans(); - t.SetPos(x, y, z); - - if (register) - { - gReve->AddRenderElement(q); - gReve->Redraw3D(); - } - } - - { - Reve::QuadSet* q = new Reve::QuadSet("HexagonYX"); - q->Reset(Reve::QuadSet::QT_HexagonYX, kFALSE, 32); - for (Int_t i=0; iAddHexagon(r.Uniform(-10, 10), r.Uniform(-10, 10), r.Uniform(-10, 10), - r.Uniform(0.2, 1)); - q->QuadValue(r.Uniform(0, 120)); - } - q->RefitPlex(); - - Reve::ZTrans& t = q->RefHMTrans(); - t.SetPos(x, y, z); - - if (register) - { - gReve->AddRenderElement(q); - gReve->Redraw3D(); - } - } - - return q; -} - -Reve::QuadSet* reve_quad_test_hexid(Float_t x=0, Float_t y=0, Float_t z=0, - Int_t num=100, Bool_t register=kTRUE) -{ - TRandom r(0); - - gStyle->SetPalette(1, 0); - - { - Reve::QuadSet* q = new Reve::QuadSet("HexagonXY"); - q->SetOwnIds(kTRUE); - q->Reset(Reve::QuadSet::QT_HexagonXY, kFALSE, 32); - for (Int_t i=0; iAddHexagon(r.Uniform(-10, 10), r.Uniform(-10, 10), r.Uniform(-10, 10), - r.Uniform(0.2, 1)); - q->QuadValue(r.Uniform(0, 120)); - q->QuadId(new TNamed(Form("Quad with idx=%d", i), "This title is not confusing.")); - } - q->RefitPlex(); - - Reve::ZTrans& t = q->RefHMTrans(); - t.SetPos(x, y, z); - - if (register) - { - gReve->AddRenderElement(q); - gReve->Redraw3D(); - } - } - - return q; -} - -void reve_quad_test_hierarchy(Int_t n=4) -{ - gStyle->SetPalette(1, 0); - - Reve::RGBAPalette* pal = new Reve::RGBAPalette(20, 100); - pal->SetLimits(0, 120); - - Reve::FrameBox* box = new Reve::FrameBox(); - box->SetAABox(-10, -10, -10, 20, 20, 20); - box->SetFrameColor((Color_t) 33); - - Reve::RenderElementList* l = new Reve::RenderElementList("Parent/Dir"); - l->SetTitle("Tooltip"); - // l->SetMainColor((Color_t)3); - gReve->AddRenderElement(l); - - // PMD: obtain digit-tree from run-loader, loop over entries. - - for (Int_t i=0; iSetPalette(pal); - qs->SetFrame(box); - gReve->AddRenderElement(qs, l); - } - - gReve->Redraw3D(); -} diff --git a/EVE/macros/reve_sa_init.C b/EVE/macros/reve_sa_init.C deleted file mode 100644 index 19a8b21f0fa..00000000000 --- a/EVE/macros/reve_sa_init.C +++ /dev/null @@ -1,21 +0,0 @@ -// Stand-Alone reve initialization. -// If class Reve::ReveManager is not know it attempts to load -// "libReve". - -void reve_sa_init(int mode=1) -{ - TClass* c = gROOT->GetClass("Reve::ReveManager"); - if (!c) { - Info("reve_sa_init", "tring to load libReve."); - //gSystem->Load("libTreePlayer"); - //gSystem->Load("libGeomPainter"); - //gSystem->Load("libGed"); - gSystem->Load("libRGL"); - gSystem->Load("libEG"); - if (gSystem->Load("libReve") == -1) - Warning("reve_sa_init", "loading of libReve failed."); - } - - Reve::SetupEnvironment(); - Reve::ReveManager::SpawnGui(mode); -} diff --git a/EVE/macros/trackcount_init.C b/EVE/macros/trackcount_init.C index 85107d4cf4e..b728b8caf92 100644 --- a/EVE/macros/trackcount_init.C +++ b/EVE/macros/trackcount_init.C @@ -1,47 +1,47 @@ void trackcount_init() { - Reve::LoadMacro("alieve_init.C"); + LoadMacro("alieve_init.C"); alieve_init(".", -1); - Reve::LoadMacro("primary_vertex.C"); - Reve::LoadMacro("esd_tracks.C"); - Reve::LoadMacro("its_clusters.C+"); - Reve::LoadMacro("tpc_clusters.C+"); + LoadMacro("primary_vertex.C"); + LoadMacro("esd_tracks.C"); + LoadMacro("its_clusters.C+"); + LoadMacro("tpc_clusters.C+"); - Reve::TrackCounter* g_trkcnt = new Reve::TrackCounter("Primary Counter"); - gReve->AddGlobalRenderElement(g_trkcnt); + TEveTrackCounter* g_trkcnt = new TEveTrackCounter("Primary Counter"); + gEve->AddGlobalElement(g_trkcnt); Alieve::gEvent->AddNewEventCommand("on_new_event();"); Alieve::gEvent->GotoEvent(0); - gReve->Redraw3D(kTRUE); + gEve->Redraw3D(kTRUE); } void on_new_event() { - Reve::PointSet* itsc = its_clusters(); + TEvePointSet* itsc = its_clusters(); itsc->SetMarkerColor(5); - Reve::PointSet* tpcc = tpc_clusters(); + TEvePointSet* tpcc = tpc_clusters(); tpcc->SetMarkerColor(4); primary_vertex(1, 1); - Reve::RenderElementList* cont = esd_tracks_vertex_cut(); - TGListTree* lt = gReve->GetListTree(); + TEveElementList* cont = esd_tracks_vertex_cut(); + TGListTree* lt = gEve->GetListTree(); TGListTreeItem* ti = cont->FindListTreeItem(lt); lt->OpenItem(ti); - // Here we expect five TrackList containers. + // Here we expect five TEveTrackList containers. // First two have reasonable primaries (sigma-to-prim-vertex < 5). // Other three are almost certainly secondaries. Int_t count = 1; - Reve::TrackCounter* g_trkcnt = Reve::TrackCounter::fgInstance; + TEveTrackCounter* g_trkcnt = TEveTrackCounter::fgInstance; g_trkcnt->Reset(); g_trkcnt->SetEventId(Alieve::gEvent->GetEventId()); - Reve::RenderElement::List_i i = cont->BeginChildren(); + TEveElement::List_i i = cont->BeginChildren(); while (i != cont->EndChildren()) { - Reve::TrackList* l = dynamic_cast(*i); + TEveTrackList* l = dynamic_cast(*i); if (l != 0) { l->SetLineWidth(2); g_trkcnt->RegisterTracks(l, (count <= 2)); diff --git a/EVE/test-macros/broken_torus.tring b/EVE/test-macros/broken_torus.tring deleted file mode 100644 index 1f566fd62a1..00000000000 --- a/EVE/test-macros/broken_torus.tring +++ /dev/null @@ -1,1003 +0,0 @@ -334 668 --0.150000 0.800000 -0.198925 --0.150000 0.700000 -0.176981 -0.050000 0.800000 -0.199935 -0.500000 -0.500000 0.171236 -0.389558 -0.496174 0.103750 -0.496174 -0.389558 0.103750 --0.300000 0.578076 0.122188 --0.400000 0.600000 0.179255 --0.350000 0.700000 0.197475 -0.250000 0.800000 0.194057 -0.050000 0.700000 0.168951 -0.050000 0.800000 0.199935 -0.350000 -0.700000 0.197475 -0.150000 -0.700000 0.176981 -0.300000 -0.578076 0.122188 --0.400000 -0.600000 0.179255 --0.500000 -0.650000 0.193353 --0.389558 -0.496174 0.103750 -0.600000 -0.800000 -0.000000 -0.693572 -0.693572 0.054899 -0.642832 -0.707882 -0.112606 --0.300000 0.578076 -0.122188 --0.389558 0.496174 -0.103750 --0.316354 0.511607 -0.000000 -0.524276 0.807341 0.107864 -0.345670 0.903201 0.096121 -0.500000 0.860483 -0.000000 -0.300000 -0.578076 -0.122188 -0.350000 -0.700000 -0.197475 -0.400000 -0.600000 -0.179255 -0.500000 -0.700000 0.187907 -0.550000 -0.600000 0.195475 -0.050000 -0.800000 -0.199935 --0.150000 -0.926578 -0.128324 -0.050000 -0.931936 -0.132385 --0.700000 -0.200000 0.182725 --0.800000 -0.250000 0.194057 --0.700000 -0.050000 0.168951 --0.389558 0.496174 0.103750 --0.425343 0.425343 -0.000000 --0.496174 0.389558 0.103750 --0.800000 0.600000 -0.000000 --0.693572 0.693572 0.054899 --0.730101 0.600000 0.125212 -0.300000 -0.800000 0.190135 -0.150000 -0.800000 0.198925 --0.300000 0.947786 -0.000000 --0.403525 0.901347 -0.039543 --0.300000 0.910540 -0.113155 -0.642832 0.707882 -0.112606 -0.500000 0.650000 -0.193353 -0.600000 0.550000 -0.195475 -0.578076 -0.300000 -0.122188 -0.496174 -0.389558 -0.103750 -0.600000 -0.400000 -0.179255 -0.600000 -0.400000 0.179255 --0.524276 0.807341 -0.107864 --0.350000 0.750000 -0.188841 --0.316354 -0.511607 -0.000000 --0.300000 -0.578076 0.122188 --0.000000 -0.633333 0.100000 --0.050000 -0.700000 0.168951 --0.144449 -0.611414 0.100804 --0.903201 -0.345670 0.096121 --0.922618 -0.200000 0.125212 -0.916579 0.250000 -0.119184 -0.931936 0.050000 -0.132385 -0.975139 0.200000 -0.000000 -0.926578 -0.150000 -0.128324 -0.800000 -0.250000 -0.194057 -0.910540 -0.300000 -0.113155 -0.050000 -0.931936 0.132385 --0.050000 -0.800000 0.199935 --0.800000 0.150000 0.198925 --0.931936 -0.050000 0.132385 --0.926578 0.150000 0.128324 -0.050000 0.996730 -0.000000 --0.150000 0.926578 -0.128324 -0.050000 0.931936 -0.132385 --0.800000 -0.600000 -0.000000 --0.860483 -0.500000 -0.000000 --0.807341 -0.524276 0.107864 -0.860483 -0.500000 -0.000000 -0.807341 -0.524276 0.107864 -0.800000 -0.600000 -0.000000 -0.400000 0.800000 0.170278 -0.700000 -0.050000 -0.168951 -0.611414 -0.144449 -0.100804 -0.633333 -0.000000 -0.100000 -0.903201 -0.345670 0.096121 -0.800000 -0.400000 0.170278 -0.345670 -0.903201 0.096121 -0.200000 -0.922618 0.125212 -0.693572 0.693572 0.054899 -0.600000 0.800000 -0.000000 --0.860483 0.500000 -0.000000 --0.903201 0.345670 0.096121 --0.901347 0.403525 -0.039543 -0.389558 -0.496174 -0.103750 --0.000000 0.633333 0.100000 --0.150000 0.700000 0.176981 -0.700000 -0.200000 -0.182725 -0.200000 0.975139 -0.000000 -0.250000 0.916579 -0.119184 -0.300000 0.947786 -0.000000 --0.600000 -0.550000 0.195475 --0.700000 -0.500000 0.187907 --0.600000 -0.400000 0.179255 -0.700000 0.350000 0.197475 -0.578076 0.300000 0.122188 -0.600000 0.400000 0.179255 --0.800000 -0.400000 0.170278 -0.650000 -0.500000 0.193353 --0.144449 0.611414 0.100804 --0.100000 0.598290 0.008105 --0.200000 0.570402 -0.000000 -0.350000 0.700000 -0.197475 -0.300000 0.578076 -0.122188 -0.400000 0.600000 -0.179255 -0.144449 -0.611414 0.100804 -0.700000 0.200000 0.182725 -0.611414 0.144449 0.100804 --0.693572 -0.693572 0.054899 --0.730101 -0.600000 0.125212 --0.600000 -0.730101 0.125212 -0.600000 0.400000 -0.179255 -0.578076 0.300000 -0.122188 -0.700000 0.350000 -0.197475 -0.511607 -0.316354 -0.000000 -0.578076 -0.300000 0.122188 --0.500000 0.500000 0.171236 -0.903201 0.345670 0.096121 -0.800000 0.300000 0.190135 -0.800000 0.400000 0.170278 -0.901347 -0.403525 -0.039543 --0.975139 -0.200000 -0.000000 -0.350000 0.700000 0.197475 -0.200000 0.700000 0.182725 --0.700000 -0.350000 0.197475 --0.707882 0.642832 -0.112606 --0.511607 0.316354 -0.000000 --0.578076 0.300000 0.122188 --0.700000 0.050000 -0.168951 --0.800000 -0.050000 -0.199935 --0.700000 -0.150000 -0.176981 --0.611414 -0.144449 -0.100804 --0.599573 -0.081250 0.008105 --0.633333 -0.000000 -0.100000 -0.500000 -0.700000 -0.187907 -0.524276 -0.807341 -0.107864 --0.650000 0.500000 0.193353 --0.800000 0.400000 0.170278 --0.807341 0.524276 0.107864 -0.800000 0.600000 -0.000000 -0.860483 0.500000 -0.000000 -0.807341 0.524276 0.107864 -0.700000 0.050000 0.168951 --0.496174 0.389558 -0.103750 --0.578076 0.300000 -0.122188 -0.496174 0.389558 -0.103750 -0.050000 -0.700000 -0.168951 -0.200000 -0.700000 -0.182725 --0.570402 0.200000 -0.000000 --0.578076 -0.300000 0.122188 --0.611414 -0.144449 0.100804 -0.500000 -0.500000 -0.171236 -0.550000 -0.600000 -0.195475 --0.611414 0.144449 -0.100804 --0.550000 0.600000 -0.195475 --0.400000 0.600000 -0.179255 --0.150000 0.984299 -0.000000 --0.800000 -0.050000 0.199935 --0.700000 0.150000 0.176981 -0.500000 -0.860483 -0.000000 -0.700000 -0.350000 0.197475 -0.800000 -0.250000 0.194057 -0.400000 0.600000 0.179255 -0.300000 0.578076 0.122188 --0.600000 0.730101 -0.125212 --0.600000 0.800000 -0.000000 -0.650000 -0.500000 -0.193353 -0.524276 0.807341 -0.107864 -0.496174 0.389558 0.103750 -0.730101 0.600000 -0.125212 --0.524276 -0.807341 -0.107864 --0.400000 -0.800000 -0.170278 --0.403525 -0.901347 -0.039543 -0.400000 -0.600000 0.179255 -0.250000 -0.800000 -0.194057 -0.400000 -0.800000 -0.170278 -0.250000 -0.916579 -0.119184 -0.403525 -0.901347 -0.039543 --0.807341 -0.524276 -0.107864 --0.650000 -0.500000 -0.193353 --0.730101 -0.600000 -0.125212 --0.345670 -0.903201 0.096121 --0.524276 -0.807341 0.107864 --0.400000 -0.800000 0.170278 --0.800000 0.300000 0.190135 --0.600000 0.400000 0.179255 --0.700000 0.350000 0.197475 -0.700000 0.500000 -0.187907 -0.570402 -0.200000 -0.000000 -0.599573 -0.081250 0.008105 -0.611414 -0.144449 0.100804 -0.389558 0.496174 0.103750 -0.316354 0.511607 -0.000000 -0.400000 0.800000 -0.170278 --0.578076 -0.300000 -0.122188 --0.600000 -0.400000 -0.179255 --0.496174 -0.389558 -0.103750 -0.700000 0.500000 0.187907 --0.150000 0.800000 0.198925 --0.000000 0.633333 -0.100000 -0.081250 0.599573 0.008105 -0.144449 0.611414 -0.100804 -0.730101 -0.600000 -0.125212 --0.500000 -0.500000 -0.171236 --0.389558 -0.496174 -0.103750 --0.600000 -0.800000 -0.000000 --0.642832 -0.707882 -0.112606 --0.633333 -0.000000 0.100000 --0.611414 0.144449 0.100804 --0.550000 -0.600000 -0.195475 -0.700000 -0.150000 0.176981 -0.800000 -0.050000 0.199935 -0.700000 -0.350000 -0.197475 -0.200000 0.570402 -0.000000 --0.500000 0.500000 -0.171236 -0.500000 0.500000 -0.171236 --0.144449 -0.611414 -0.100804 --0.150000 -0.700000 -0.176981 --0.000000 -0.633333 -0.100000 --0.500000 0.700000 -0.187907 -0.807341 -0.524276 -0.107864 -0.807341 0.524276 -0.107864 -0.144449 -0.611414 -0.100804 --0.400000 0.800000 0.170278 --0.500000 0.700000 0.187907 --0.524276 0.807341 0.107864 -0.730101 0.600000 0.125212 -0.600000 0.550000 0.195475 -0.524276 -0.807341 0.107864 --0.800000 0.300000 -0.190135 --0.800000 0.150000 -0.198925 --0.700000 0.350000 -0.197475 -0.922618 0.200000 0.125212 -0.996730 0.050000 -0.000000 -0.931936 0.050000 0.132385 --0.807341 0.524276 -0.107864 --0.800000 0.400000 -0.170278 --0.650000 0.500000 -0.193353 --0.250000 -0.800000 0.194057 --0.200000 -0.700000 0.182725 --0.500000 -0.860483 -0.000000 --0.984299 0.150000 -0.000000 --0.926578 0.150000 -0.128324 --0.947786 0.300000 -0.000000 -0.800000 -0.400000 -0.170278 --0.350000 -0.700000 0.197475 -0.200000 -0.975139 -0.000000 -0.800000 0.150000 0.198925 --0.050000 0.931936 0.132385 --0.550000 0.600000 0.195475 --0.600000 0.730101 0.125212 -0.400000 -0.800000 0.170278 --0.800000 -0.400000 -0.170278 --0.901347 -0.403525 -0.039543 -0.144449 0.611414 0.100804 --0.700000 0.200000 -0.182725 --0.570402 -0.200000 -0.000000 -0.150000 0.926578 0.128324 --0.996730 -0.050000 -0.000000 -0.984299 -0.150000 -0.000000 --0.496174 -0.389558 0.103750 --0.425343 -0.425343 -0.000000 --0.300000 -0.800000 -0.190135 --0.300000 -0.910540 -0.113155 --0.150000 -0.800000 -0.198925 -0.800000 0.150000 -0.198925 -0.316354 -0.511607 -0.000000 --0.500000 -0.500000 0.171236 -0.600000 -0.730101 0.125212 --0.910540 0.300000 -0.113155 --0.600000 0.400000 -0.179255 --0.400000 -0.600000 -0.179255 --0.300000 -0.578076 -0.122188 -0.050000 0.700000 -0.168951 -0.081250 -0.599573 0.008105 -0.403525 0.901347 -0.039543 -0.947786 0.300000 -0.000000 -0.389558 0.496174 -0.103750 -0.250000 0.800000 -0.194057 -0.200000 0.700000 -0.182725 -0.926578 -0.150000 0.128324 --0.947786 -0.300000 -0.000000 --0.100000 -0.598290 0.008105 --0.350000 -0.700000 -0.197475 --0.144449 0.611414 -0.100804 --0.150000 -0.926578 0.128324 -0.947786 -0.300000 -0.000000 --0.511607 -0.316354 -0.000000 -0.425343 -0.425343 -0.000000 -0.500000 0.650000 0.193353 -0.600000 0.730101 0.125212 --0.931936 -0.050000 -0.132385 --0.200000 -0.570402 -0.000000 --0.916579 -0.250000 -0.119184 --0.598290 0.100000 0.008105 --0.700000 -0.350000 -0.197475 -0.300000 -0.947786 -0.000000 --0.500000 -0.700000 -0.187907 --0.500000 0.860483 -0.000000 --0.345670 0.903201 0.096121 --0.200000 0.922618 0.125212 -0.598290 0.100000 0.008105 -0.700000 0.150000 -0.176981 -0.611414 0.144449 -0.100804 -0.901347 0.403525 -0.039543 -0.500000 0.500000 0.171236 -0.200000 -0.570402 -0.000000 --0.150000 -0.984299 -0.000000 -0.800000 -0.050000 -0.199935 -0.511607 0.316354 -0.000000 -0.633333 -0.000000 0.100000 --0.300000 -0.947786 -0.000000 -0.800000 0.400000 -0.170278 --0.300000 0.800000 0.190135 -0.050000 -0.996730 -0.000000 -0.800000 0.300000 -0.190135 --0.800000 -0.250000 -0.194057 -0.570402 0.200000 -0.000000 -0.425343 0.425343 -0.000000 -0.730101 -0.600000 0.125212 -1 0 2 -4 3 5 -7 6 8 -10 9 11 -13 12 14 -16 15 17 -19 18 20 -22 21 23 -25 24 26 -28 27 29 -12 30 31 -33 32 34 -36 35 37 -39 38 40 -42 41 43 -45 44 12 -47 46 48 -50 49 51 -53 52 54 -3 55 5 -56 47 57 -58 17 59 -61 60 62 -63 36 64 -66 65 67 -69 68 70 -71 45 72 -74 73 75 -77 76 78 -80 79 81 -82 83 84 -9 85 25 -86 87 88 -83 89 90 -92 91 44 -93 49 94 -96 95 97 -27 98 29 -100 99 10 -87 86 101 -103 102 104 -106 105 107 -109 108 110 -63 111 36 -3 112 55 -114 113 115 -117 116 118 -61 119 60 -121 120 108 -123 122 124 -126 125 127 -128 5 129 -130 38 7 -132 131 133 -89 82 134 -135 64 74 -137 136 9 -36 138 35 -42 139 41 -140 40 141 -143 142 144 -146 145 147 -149 148 20 -151 150 152 -114 99 113 -154 153 155 -121 156 120 -158 157 140 -159 51 125 -32 160 161 -162 140 141 -138 163 164 -29 165 166 -167 158 140 -168 57 169 -38 6 7 -52 87 101 -48 46 170 -171 37 172 -149 18 173 -174 90 175 -177 176 136 -56 178 179 -165 54 180 -50 181 49 -182 109 110 -51 49 183 -184 185 186 -12 31 187 -188 28 189 -34 188 190 -91 191 173 -190 189 191 -28 29 166 -192 193 194 -196 195 197 -122 79 194 -77 170 76 -75 73 198 -200 199 150 -125 201 127 -203 202 204 -206 205 177 -116 207 181 -121 108 109 -78 102 103 -209 208 210 -110 108 211 -152 96 151 -190 188 189 -100 11 212 -214 213 215 -14 187 4 -19 216 84 -217 210 218 -184 219 220 -37 221 222 -194 193 223 -193 209 210 -224 175 225 -180 54 226 -214 215 227 -228 169 22 -229 50 51 -231 230 232 -168 178 233 -216 234 84 -183 153 235 -160 232 236 -238 237 239 -166 165 180 -241 240 93 -54 52 226 -18 242 173 -244 243 245 -247 246 248 -181 26 94 -250 249 251 -252 61 253 -63 80 81 -195 254 186 -256 255 257 -258 70 134 -196 259 16 -251 139 168 -260 91 92 -225 248 261 -253 61 62 -212 11 262 -96 198 151 -43 263 264 -265 30 12 -224 225 156 -266 192 267 -41 152 43 -10 99 268 -244 269 142 -157 39 140 -203 87 202 -146 164 270 -11 9 271 -135 74 272 -70 68 273 -275 274 17 -129 224 204 -277 276 278 -279 65 66 -233 56 57 -236 280 27 -105 281 274 -52 202 87 -108 155 211 -228 168 169 -36 37 171 -72 45 13 -18 282 242 -283 250 243 -108 133 155 -141 40 199 -245 284 158 -261 248 246 -285 218 286 -23 6 38 -1 287 213 -74 171 73 -23 115 113 -288 60 119 -68 66 247 -207 289 181 -67 290 131 -93 153 183 -179 264 239 -39 40 140 -142 167 147 -214 268 99 -117 118 291 -293 292 116 -112 174 55 -250 251 245 -287 2 292 -225 294 248 -295 64 135 -142 269 167 -16 259 15 -296 232 230 -122 220 219 -148 166 20 -200 141 199 -185 297 276 -16 17 281 -21 298 115 -299 71 72 -300 294 89 -98 53 165 -242 282 30 -208 270 301 -194 79 192 -53 98 302 -287 215 213 -156 204 224 -97 95 249 -265 242 30 -11 271 262 -89 83 82 -303 241 304 -122 219 124 -93 240 153 -58 59 62 -1 2 287 -305 256 244 -296 230 306 -252 253 259 -307 135 272 -112 83 90 -308 146 147 -193 309 209 -85 24 25 -191 310 190 -21 115 23 -184 311 297 -313 312 239 -46 313 314 -55 174 129 -291 50 229 -313 47 312 -291 118 50 -187 31 3 -168 233 57 -227 177 268 -114 298 213 -308 222 221 -315 88 203 -181 94 49 -144 142 147 -316 88 317 -215 293 116 -308 162 222 -31 112 3 -25 289 104 -292 103 289 -318 235 154 -319 241 303 -275 301 274 -234 258 134 -223 218 285 -90 89 175 -267 192 80 -259 253 62 -86 316 279 -320 119 14 -152 150 43 -302 4 5 -91 173 242 -277 33 321 -261 246 131 -86 279 322 -30 282 31 -277 278 33 -64 171 74 -25 26 289 -317 323 126 -283 97 250 -301 270 164 -197 195 252 -156 324 204 -305 272 255 -277 321 325 -10 137 9 -182 110 241 -280 14 4 -180 226 258 -212 262 314 -299 72 252 -65 290 67 -46 314 170 -120 261 132 -102 271 25 -226 69 258 -326 235 318 -58 275 17 -42 178 139 -73 200 198 -273 248 294 -259 62 59 -327 212 314 -118 116 50 -267 295 307 -288 320 236 -175 89 294 -189 149 191 -315 324 121 -89 134 300 -116 292 207 -328 260 92 -33 34 328 -251 168 228 -165 53 54 -159 125 126 -219 254 196 -316 127 329 -272 74 75 -256 283 243 -139 249 41 -150 130 263 -266 330 309 -42 179 178 -302 5 128 -309 144 145 -255 75 96 -143 244 142 -157 228 22 -316 329 279 -315 121 331 -111 138 36 -131 318 154 -206 332 205 -186 277 325 -315 317 88 -102 25 104 -131 154 155 -19 282 18 -161 236 27 -146 221 164 -315 203 324 -159 323 332 -32 161 188 -307 305 143 -317 126 127 -105 16 281 -198 200 151 -185 277 186 -329 326 318 -252 72 61 -42 264 179 -296 288 232 -43 264 42 -76 271 102 -166 180 216 -320 14 280 -307 330 266 -307 295 135 -214 227 268 -192 309 193 -91 310 191 -332 182 205 -92 44 45 -0 77 78 -317 127 316 -136 303 24 -162 141 222 -278 160 32 -29 98 165 -128 129 204 -114 213 214 -127 201 235 -6 113 100 -175 294 225 -93 94 304 -105 274 107 -215 117 206 -327 314 313 -263 238 264 -96 97 257 -84 83 333 -100 113 99 -309 208 209 -138 107 163 -73 172 200 -72 13 61 -321 328 71 -291 206 117 -199 130 150 -108 132 133 -56 179 312 -203 88 87 -249 139 251 -153 240 155 -205 319 303 -136 85 9 -61 13 119 -195 196 254 -177 205 176 -93 183 49 -305 255 256 -114 214 99 -144 147 145 -309 145 208 -296 60 288 -308 221 146 -160 236 161 -96 152 95 -52 101 226 -311 223 285 -280 4 302 -21 57 1 -97 283 257 -70 273 300 -156 225 261 -133 131 155 -288 236 232 -322 66 68 -223 217 218 -67 131 246 -35 164 37 -15 59 17 -269 245 158 -151 200 150 -289 103 104 -316 86 88 -237 327 313 -218 275 58 -247 67 246 -288 119 320 -126 323 159 -106 107 138 -269 158 167 -205 182 319 -174 175 224 -8 327 237 -52 53 128 -0 78 2 -333 83 112 -180 258 234 -264 238 239 -203 204 324 -157 22 39 -305 244 143 -81 123 106 -52 128 202 -51 183 201 -44 265 12 -20 166 216 -263 8 238 -159 229 51 -286 306 230 -313 46 47 -122 194 220 -107 274 163 -234 82 84 -22 23 39 -68 247 273 -284 251 228 -241 211 240 -210 275 218 -8 212 327 -98 27 280 -114 115 298 -295 63 64 -185 276 277 -47 56 312 -331 109 323 -19 84 333 -332 323 182 -287 293 215 -57 77 0 -297 286 230 -256 243 244 -100 10 11 -261 131 132 -79 123 81 -239 237 313 -125 51 201 -258 69 70 -276 231 278 -124 16 105 -19 20 216 -249 95 41 -171 172 73 -286 58 306 -34 260 328 -57 47 48 -91 265 44 -6 100 8 -75 198 96 -9 25 271 -301 164 163 -98 280 302 -194 223 220 -58 62 306 -76 262 271 -256 257 283 -201 183 235 -328 92 71 -172 222 141 -81 106 138 -317 331 323 -329 318 65 -110 211 241 -170 262 76 -111 63 81 -249 250 97 -8 100 212 -66 67 247 -284 228 157 -136 24 85 -23 113 6 -127 235 326 -134 70 300 -63 267 80 -170 314 262 -122 123 79 -48 170 77 -273 247 248 -184 297 185 -215 206 227 -291 229 159 -219 196 124 -235 153 154 -241 93 304 -321 71 299 -268 177 136 -120 132 108 -205 303 176 -265 91 242 -57 48 77 -81 138 111 -296 306 62 -112 90 174 -315 331 317 -45 12 13 -220 311 184 -167 140 162 -218 58 286 -130 7 263 -169 57 21 -331 121 109 -199 40 130 -131 290 318 -297 230 231 -297 285 286 -259 59 15 -311 285 297 -227 206 177 -291 332 206 -57 0 1 -245 251 284 -13 14 119 -323 109 182 -178 56 233 -23 38 39 -33 278 32 -10 268 137 -78 76 102 -281 17 274 -189 28 148 -95 152 41 -156 121 324 -325 321 299 -268 136 137 -287 292 293 -307 143 330 -197 252 259 -226 101 69 -260 310 91 -308 167 162 -53 302 128 -101 322 69 -325 299 195 -127 326 329 -276 297 231 -40 38 130 -192 79 80 -231 232 160 -176 303 136 -216 180 234 -279 329 65 -94 26 24 -223 193 217 -236 320 280 -123 124 105 -292 289 207 -134 82 234 -158 284 157 -318 290 65 -263 7 8 -37 222 172 -156 261 120 -211 155 240 -12 187 14 -282 19 333 -188 161 28 -69 322 68 -322 279 66 -71 92 45 -101 86 322 -187 3 4 -172 141 200 -123 105 106 -208 145 270 -182 241 319 -186 254 184 -308 147 167 -330 144 309 -184 254 219 -146 270 145 -37 164 221 -33 328 321 -193 210 217 -2 103 292 -31 333 112 -255 96 257 -195 299 252 -238 8 237 -150 263 43 -129 174 224 -138 164 35 -34 32 188 -116 181 50 -307 272 305 -124 196 16 -190 310 260 -208 301 210 -139 178 168 -192 266 309 -330 143 144 -307 266 267 -94 24 304 -196 197 259 -195 186 325 -300 273 294 -282 333 31 -34 190 260 -28 166 148 -191 149 173 -243 250 245 -1 213 298 -2 78 103 -189 148 149 -149 20 18 -296 62 60 -179 239 312 -63 295 267 -22 169 21 -159 332 291 -303 304 24 -215 116 117 -289 26 181 -161 27 28 -244 245 269 -5 55 129 -128 204 202 -278 231 160 -64 36 171 -210 301 275 -301 163 274 -21 1 298 -272 75 255 -220 223 311 diff --git a/EVE/test-macros/nasashuttle.3ds b/EVE/test-macros/nasashuttle.3ds deleted file mode 100644 index 5f712bae4d26e9db81a0132daf5e30d10786cfa6..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 219441 zcmeFa2UykEw>O*w<)EOV0s=Nb>{X?vR0C_vUgT!*33W7 zjuW`T9LL$=UufvImUf&mG*8amxeZ!wO-XE;bsgSgXrHeAy(-kL$2qSl232vc5Vp@h z=X!lB`q_y0@81{K6h$#V&H-BwPO^~-axpd%$F=%KYWhk}xuiQ6%y-uB8l2tfD|J&4{zE!uvX)kNUr5Natg<_UPo>?clvZ_?#{cU zSW^m{aLFrT#LzKbZ7{+yUNK$28DYD2?QBN~@&7PFr*B4B;=j-p|Ctf~u8q(U+je~h z_WEX2H*emw9Th~|QQ>^Ey%=hI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+EyK_u2s*fZ#A$QT8*s6Ruk(-tEtt@YHs~xwXj-Rt*q8o8>_9=&T4OUusT|u ztj<;!tA_VLVk9~Kgg^KR#vqsj!5j$YKrjb_IS|Z&U=IAhlLLlF)ob{=^ev!%S4Ki; zBdS-3VI+y-kO_>c-uku5L{y8wYao7uPgDxk0skp0aa0nm4a16B163eO{jMMUvW+PG zt_?%|>aT(Y4E%+%@%1Z>Qb)mmk%3RfsBFsq&wnas{_B64qH_H&&i{Qc)g|-)VZ2B; z4y-?MCu+u-Xn~Ud;)$Zf=06cFP~u-aQT#%t|2fg(|Kf?pk2_KPQY_EEHAfS~ooLa2 z@kA5GooJDN@kH?_n*TFL3;&BJnkeo>@hcSnwKSetDataSource(x); s->SetMainColor(36); - gReve->AddRenderElement(s); - gReve->DrawRenderElement(s); + gEve->AddElement(s); + gEve->DrawElement(s); } diff --git a/EVE/test-macros/tpc_gui.C b/EVE/test-macros/tpc_gui.C index cf484f86b7a..bf129b0f437 100644 --- a/EVE/test-macros/tpc_gui.C +++ b/EVE/test-macros/tpc_gui.C @@ -1,4 +1,4 @@ -// $Header$ +// $Header: /soft/cvsroot/AliRoot/EVE/test-macros/tpc_gui.C,v 1.8 2007/10/22 14:49:12 mtadel Exp $ // Function to spawn a gui for reading rootified raw-data from TPC sector test. // @@ -21,8 +21,8 @@ class TPCSector3D; #else -#include -#include +#include +#include #include #include #include @@ -54,7 +54,7 @@ void tpc_gui(const char *file=0, Int_t ievent=0) l->SetInitParams(40, 980, 10); // min-time, max-time, threshold // l->SetTPCEquipementMap("EquipmentIdMap.data"); - gReve->AddRenderElement(l); + gEve->AddElement(l); if(file != 0) { l->SetFile(file); diff --git a/EVE/test-macros/tpc_gui_hack.C b/EVE/test-macros/tpc_gui_hack.C index 3677b7687b1..362b0ec150c 100644 --- a/EVE/test-macros/tpc_gui_hack.C +++ b/EVE/test-macros/tpc_gui_hack.C @@ -1,4 +1,4 @@ -// $Header$ +// $Header: /soft/cvsroot/AliRoot/EVE/test-macros/tpc_gui_hack.C,v 1.5 2007/10/22 14:49:12 mtadel Exp $ // Function to spawn a gui for reading rootified raw-data from TPC sector test. @@ -14,8 +14,8 @@ class TPCSector3D; #else -#include -#include +#include +#include #include #include #include @@ -53,9 +53,9 @@ void tpc_gui_hack(const char *file=0, Int_t ievent=0) su = d->GetSectorData( 4, kTRUE); sl = d->GetSectorData(13, kTRUE); - gReve->AddRenderElement(l); - gReve->NotifyBrowser(l); - gReve->DrawRenderElement(l); + gEve->AddElement(l); + gEve->NotifyBrowser(l); + gEve->DrawElement(l); if(file != 0) { l->SetFile(file); diff --git a/EVE/test-macros/tpc_raw_test.C b/EVE/test-macros/tpc_raw_test.C index 8becb3145af..29948bae5d9 100644 --- a/EVE/test-macros/tpc_raw_test.C +++ b/EVE/test-macros/tpc_raw_test.C @@ -28,8 +28,8 @@ void tpc_raw_test() Alieve::TPCSector2D* s = new Alieve::TPCSector2D(); s->SetDataSource(x); s->SetMainColor(36); - gReve->AddRenderElement(s); - gReve->DrawRenderElement(s); + gEve->AddElement(s); + gEve->DrawElement(s); } diff --git a/EVE/test-macros/tpc_sector_raw_test.C b/EVE/test-macros/tpc_sector_raw_test.C index 8a93f77346f..1a578b2fe0e 100644 --- a/EVE/test-macros/tpc_sector_raw_test.C +++ b/EVE/test-macros/tpc_sector_raw_test.C @@ -1,4 +1,4 @@ -// $Header$ +// $Header: /soft/cvsroot/AliRoot/EVE/test-macros/tpc_sector_raw_test.C,v 1.10 2006/10/18 17:00:14 mtadel Exp $ // Functions to read rootified raw-data from TPC sector test. // @@ -51,8 +51,8 @@ void tpc_sector_raw_test(const char *file = "", Int_t ievent = 0) s->SetAutoTrans(kTRUE); // place on proper 3D coordinates s->SetDataSource(x); s->SetFrameColor(36); - gReve->AddRenderElement(s); - gReve->DrawRenderElement(s); + gEve->AddElement(s); + gEve->DrawElement(s); t = new TPCSector3D(); t->SetSectorID(default_sector); @@ -60,8 +60,8 @@ void tpc_sector_raw_test(const char *file = "", Int_t ievent = 0) t->SetDataSource(x); t->SetMaxTime(1023); t->SetDriftVel(2.273); - gReve->AddRenderElement(t); - gReve->DrawRenderElement(t); + gEve->AddElement(t); + gEve->DrawElement(t); next_event(); } @@ -89,7 +89,7 @@ void next_event() printf("Updating scene\n"); s->IncRTS(); t->IncRTS(); - gReve->Redraw3D(); + gEve->Redraw3D(); } void tpc_raw_pad_dump(Int_t s, Int_t r, Int_t p) diff --git a/EVE/test-macros/triangleset.C b/EVE/test-macros/triangleset.C deleted file mode 100644 index 461bc080162..00000000000 --- a/EVE/test-macros/triangleset.C +++ /dev/null @@ -1,51 +0,0 @@ -#include "TCanvas.h" -#include "TStyle.h" -#include "TFile.h" -#include "TStopwatch.h" -#include "TError.h" - -namespace Reve{ -class TTriangleSet; -} - -Reve::TriangleSet *ts1=0, *ts2=0, *ts3=0; - -void triangleset() -{ - { - ts1 = Reve::TriangleSet::ReadTrivialFile("broken_torus.tring"); - ts1->SetName("RandomColors"); - ts1->GenerateTriangleNormals(); - ts1->GenerateRandomColors(); - ts1->SetColor(0); - gReve->AddRenderElement(ts1); - } - { - ts2 = Reve::TriangleSet::ReadTrivialFile("broken_torus.tring"); - ts2->SetName("SmallBlue"); - ts2->GenerateTriangleNormals(); - ts2->SetColor(4); - TGeoHMatrix m; - m.RotateY(90); - Double_t scale[3] = { 0.8, 0.8, 1.2 }; - m.SetScale(scale); - ts2->SetTransMatrix(m); - gReve->AddRenderElement(ts2); - } - { - ts3 = Reve::TriangleSet::ReadTrivialFile("broken_torus.tring"); - ts3->SetName("Spectrum"); - ts3->GenerateTriangleNormals(); - gStyle->SetPalette(1, 0); - ts3->GenerateZNormalColors(50, -50, 50, kTRUE, kTRUE); - ts3->SetColor(0); - TGeoHMatrix m; - m.RotateZ(90); - Double_t scale[3] = { 1.3, 1.0, 1.6 }; - m.SetScale(scale); - ts3->SetTransMatrix(m); - gReve->AddRenderElement(ts3); - } - - gReve->Redraw3D(kTRUE); -} diff --git a/EVE/test-macros/view3ds.C b/EVE/test-macros/view3ds.C deleted file mode 100644 index a47f3d8f8a7..00000000000 --- a/EVE/test-macros/view3ds.C +++ /dev/null @@ -1,577 +0,0 @@ -#include "TCanvas.h" -#include "TStyle.h" -#include "TFile.h" -#include "TStopwatch.h" -#include "TError.h" - -#include -#include -#include -#include - -namespace Reve { - class TriangleSet; -} -Reve::TriangleSet *ts[2048]; - -// Believe3D Model file defines -#define MAGICNUMBER 0xB3D0 - -// types of 3DS Chunks -#define CHUNKMAIN 0x4D4D -#define CHUNKMAINVERSION 0x0002 -#define CHUNK3D 0x3D3D -#define CHUNK3DVERSION 0x3D3E -#define CHUNK3DOBJECT 0x4000 -#define CHUNK3DOBJECTMESH 0x4100 -#define CHUNK3DOBJECTMESHVERTICES 0x4110 -#define CHUNK3DOBJECTMESHFACES 0x4120 -#define CHUNK3DOBJECTMESHMATGROUP 0x4130 -#define CHUNK3DOBJECTMESHMAPPING 0x4140 - -#define CHUNK3DMATERIAL 0xAFFF -// Sub defines of MATERIAL -#define MATNAME 0xA000 -#define MATDIFFUSE 0xA020 -#define MATSPECULAR 0xA030 -#define MATTRANSPARENCY 0xA050 - -#define COLOR_F 0x0010 -#define COLOR_24 0x0011 -#define LIN_COLOR_24 0x0012 -#define LIN_COLOR_F 0x0013 -#define INT_PERCENTAGE 0x0030 -#define FLOAT_PERCENTAGE 0x0031 - -////////////////////////////////////// -//The tMaterialInfo Struct -////////////////////////////////////// -class Material { -public: - char name[256]; - UChar_t color[3]; - UShort_t transparency; - - Material() { - sprintf(name, ""); - color[0] = color[1] = color[2] = 0; - transparency = 0; - } - ~Material() { } -}; - - -// Chunk structure -typedef struct _Chunk { - UShort_t idnum; - ULong_t offset, len, endoffset; -} Chunk; - -// vertex structure -typedef struct _Vertex { - Float_t x, y, z; - Float_t u, v; -} Vertex; - -// face structure -typedef struct _Face { - ULong_t v1, v2, v3; -} Face; - -// model structure -class Model { -public: - char name[256]; - char matname[256]; - Vertex *vlist; - Face *flist; - ULong_t numverts, numfaces; - - Model() { - sprintf(name,""); - sprintf(matname,""); - vlist = 0; - flist = 0; - numverts = numfaces = 0; - } - ~Model() { - if (vlist != 0) delete [] vlist; - if (flist != 0) delete [] flist; - } -}; - -// chunk reading routines -Int_t ReadChunk(FILE*, Chunk*); - -// data reading routines -Int_t ReadMainChunk(FILE*); -Int_t Read3DChunk(FILE*, ULong_t); -Int_t ReadObjectChunk(FILE*, ULong_t); -Int_t ReadMeshChunk(FILE*, ULong_t, char*); -Int_t ReadVerticesChunk(FILE*); -Int_t ReadFacesChunk(FILE*); -Int_t ReadMappingChunk(FILE*); -Int_t ReadASCIIZ(FILE*, char*); -Int_t ReadMaterialChunk(FILE *, ULong_t); -Int_t ReadColor(FILE *, ULong_t); -Int_t ReadTransparency(FILE *, ULong_t); -Int_t ReadObjectMaterial(FILE *); -Int_t ConvertModel(); - -// global variables -Int_t nummodels = 0; -Model model = {"","",0,0,0,0}; - -Int_t nummaterials = 0; -Material *material[1024]; - -//______________________________________________________________________________ -Int_t Read3DSFile(const char *fname) -{ - // main function - - FILE *infile; - - infile = fopen(fname, "rb"); - if (infile == 0) { - printf("Error : Input File Could Not Be Opened!\n"); - return -1; - } - UShort_t magic = MAGICNUMBER; - if (ReadMainChunk(infile) != 0) { - printf("Error : Input File Could Not Be Read!\n"); - } - fclose(infile); - return 0; -} - -//______________________________________________________________________________ -Int_t ReadChunk(FILE *f, Chunk *c) -{ - // reads a chunk from an opened file - - if (feof(f)) return(-1); - c->idnum = 0; - c->offset = c->len = 0; - c->offset = (ULong_t) ftell(f); - fread(&c->idnum, sizeof(UShort_t), 1, f); - fread(&c->len, sizeof(ULong_t), 1, f); - c->endoffset = c->offset + c->len; - return(0); -} - -//______________________________________________________________________________ -Int_t ReadMainChunk(FILE *f) -{ - // handles the main body of the 3DS file - - Chunk chunk; - - ReadChunk(f, &chunk); - if (chunk.idnum != CHUNKMAIN) return(-1); - while ((ReadChunk(f, &chunk) == 0) && (!feof(f))) { - if (chunk.idnum == CHUNK3D) { - Read3DChunk(f, chunk.endoffset); - } - else { - //printf("Debug : Unknown Chunk [Main Chunk] [0x%x]\n", chunk.idnum); - fseek(f, chunk.offset + chunk.len, SEEK_SET); - } - } - return 0; -} - -//______________________________________________________________________________ -Int_t Read3DChunk(FILE *f, ULong_t len) -{ - // reads the 3D Edit Chunk - - Chunk chunk; - - while ((ReadChunk(f, &chunk) == 0) && (!feof(f))) { - if (chunk.idnum == CHUNK3DOBJECT) { - ReadObjectChunk(f, chunk.endoffset); - fseek(f, chunk.endoffset, SEEK_SET); - } - else if (chunk.idnum == CHUNK3DMATERIAL) { - ReadMaterialChunk(f, chunk.endoffset); - fseek(f, chunk.endoffset, SEEK_SET); - } - else { - if (chunk.endoffset < len) { - //printf("Debug : Unknown Chunk [3D Chunk] [0x%x]\n", chunk.idnum); - fseek(f, chunk.endoffset, SEEK_SET); - } - else { - break; - } - } - } - return 0; -} - -//______________________________________________________________________________ -Int_t ReadMaterialChunk(FILE *f, ULong_t len) -{ - // reads the Material sub-chunk of the 3D Edit Chunk - - Chunk chunk; - char name[256]; - char rgb[3]; - material[nummaterials] = new Material(); - while ((ReadChunk(f, &chunk) == 0) && (!feof(f))) { - if (chunk.idnum == MATNAME) { - ReadASCIIZ(f, name); - strcpy(material[nummaterials]->name, name); - fseek(f, chunk.endoffset, SEEK_SET); - } - else if (chunk.idnum == MATDIFFUSE) { - ReadColor(f, chunk.endoffset); - fseek(f, chunk.endoffset, SEEK_SET); - } - else if (chunk.idnum == MATTRANSPARENCY) { - ReadTransparency(f, chunk.endoffset); - fseek(f, chunk.endoffset, SEEK_SET); - } - else { - if (chunk.endoffset < len) { - //printf("Debug : Unknown Chunk [Object Chunk] [0x%x]\n", chunk.idnum); - fseek(f, chunk.endoffset, SEEK_SET); - } - else { - break; - } - } - } - nummaterials++; - return 0; -} - -//______________________________________________________________________________ -Int_t ReadColor(FILE *f, ULong_t len) -{ - // reads the Color property of the Material Chunk - - Chunk chunk; - float fr, fg, fb; - int irgb[3]; - while ((ReadChunk(f, &chunk) == 0) && (!feof(f))) { - if (chunk.idnum == LIN_COLOR_24) { - fread(&material[nummaterials]->color[0], sizeof(UChar_t), 1, f); - fread(&material[nummaterials]->color[1], sizeof(UChar_t), 1, f); - fread(&material[nummaterials]->color[2], sizeof(UChar_t), 1, f); - fseek(f, chunk.endoffset, SEEK_SET); - } - else if (chunk.idnum == COLOR_24) { - fread(&material[nummaterials]->color[0], sizeof(UChar_t), 1, f); - fread(&material[nummaterials]->color[1], sizeof(UChar_t), 1, f); - fread(&material[nummaterials]->color[2], sizeof(UChar_t), 1, f); - fseek(f, chunk.endoffset, SEEK_SET); - } - else if (chunk.idnum == LIN_COLOR_F) { - fread(&fr, sizeof(Float_t), 1, f); - fread(&fg, sizeof(Float_t), 1, f); - fread(&fb, sizeof(Float_t), 1, f); - fseek(f, chunk.endoffset, SEEK_SET); - } - else if (chunk.idnum == COLOR_F) { - fread(&fr, sizeof(Float_t), 1, f); - fread(&fg, sizeof(Float_t), 1, f); - fread(&fb, sizeof(Float_t), 1, f); - fseek(f, chunk.endoffset, SEEK_SET); - } - else { - if (chunk.endoffset < len) { - //printf("Debug : Unknown Chunk [Mesh Chunk] [0x%x]\n", chunk.idnum); - fseek(f, chunk.endoffset, SEEK_SET); - } - else { - break; - } - } - } - return 0; -} - -//______________________________________________________________________________ -Int_t ReadTransparency(FILE *f, ULong_t len) -{ - // reads the Transparency property of the Material Chunk - - Chunk chunk; - char byte[2]; - float ftransp; - UShort_t stransp; - while ((ReadChunk(f, &chunk) == 0) && (!feof(f))) { - if (chunk.idnum == INT_PERCENTAGE) { - fread(&stransp, sizeof(UShort_t), 1, f); - material[nummaterials]->transparency = stransp; - fseek(f, chunk.endoffset, SEEK_SET); - } - else if (chunk.idnum == FLOAT_PERCENTAGE) { - fread(&ftransp, sizeof(float), 1, f); - fseek(f, chunk.endoffset, SEEK_SET); - } - else { - if (chunk.endoffset < len) { - //printf("Debug : Unknown Chunk [Mesh Chunk] [0x%x]\n", chunk.idnum); - fseek(f, chunk.endoffset, SEEK_SET); - } - else { - break; - } - } - } - return 0; -} - -//______________________________________________________________________________ -Int_t ReadObjectMaterial(FILE *f) -{ - // reads the name of material associated to the current Chunk - - ReadASCIIZ(f, model.matname); - return 0; -} - -//______________________________________________________________________________ -Int_t ReadObjectChunk(FILE *f, ULong_t len) -{ - // reads the Object sub-chunk of the 3D Edit Chunk - - Chunk chunk; - char name[256]; - ReadASCIIZ(f, name); - while ((ReadChunk(f, &chunk) == 0) && (!feof(f))) { - if (chunk.idnum == CHUNK3DOBJECTMESH) { - ReadMeshChunk(f, chunk.endoffset, name); - } - else { - if (chunk.endoffset < len) { - //printf("Debug : Unknown Chunk [Object Chunk] [0x%x]\n", chunk.idnum); - fseek(f, chunk.endoffset, SEEK_SET); - } - else { - break; - } - } - } - return 0; -} - -//______________________________________________________________________________ -Int_t ReadMeshChunk(FILE *f, ULong_t len, char *objname) -{ - // reads the TriMesh sub-chunk of the Object Chunk - - Int_t i; - Chunk chunk; - model.vlist = 0; - model.flist = 0; - model.numverts = model.numfaces = 0; - sprintf(model.name, "%s", objname); - printf("Reading Mesh : %s\n", objname); - while ((ReadChunk(f, &chunk) == 0) && (!feof(f))) { - if (chunk.idnum == CHUNK3DOBJECTMESHVERTICES) { - ReadVerticesChunk(f); - } - else if (chunk.idnum == CHUNK3DOBJECTMESHFACES) { - ReadFacesChunk(f); - } - else if (chunk.idnum == CHUNK3DOBJECTMESHMAPPING) { - ReadMappingChunk(f); - } - else if (chunk.idnum == CHUNK3DOBJECTMESHMATGROUP) { - ReadObjectMaterial(f); - } - else { - if (chunk.endoffset < len) { - //printf("Debug : Unknown Chunk [Mesh Chunk] [0x%x]\n", chunk.idnum); - fseek(f, chunk.endoffset, SEEK_SET); - } - else { - break; - } - } - } - if (model.numverts != 0 && model.numfaces != 0 && - model.vlist != 0 && model.flist != 0) { - ConvertModel(); - } - if (model.vlist != 0) delete [] model.vlist; - if (model.flist != 0) delete [] model.flist; - model.vlist = 0; - model.flist = 0; - model.numverts = model.numfaces = 0; - sprintf(model.name,""); - nummodels++; - return 0; -} - -//______________________________________________________________________________ -Int_t ReadVerticesChunk(FILE *f) -{ - // reads Vertex data of the TriMesh Chunk - - Int_t i; - UShort_t numv = 0; - Float_t x, y, z; - - fread(&numv, sizeof(UShort_t), 1, f); - printf("Reading %i Vertices...", numv); - model.vlist = new Vertex[numv]; - if (model.vlist == 0) { - for (i = 0; i < numv; i++) { - fread(&x, sizeof(Float_t), 1, f); - fread(&y, sizeof(Float_t), 1, f); - fread(&z, sizeof(Float_t), 1, f); - } - printf("\nWarning : Insufficient Memory to Load Vertices!\n"); - return -1; - } - for (i = 0; i < numv; i++) { - fread(&model.vlist[i].x, sizeof(Float_t), 1, f); - fread(&model.vlist[i].y, sizeof(Float_t), 1, f); - fread(&model.vlist[i].z, sizeof(Float_t), 1, f); - } - model.numverts = (ULong_t) numv; - printf("Done!\n"); - return 0; -} - -//______________________________________________________________________________ -Int_t ReadFacesChunk(FILE *f) -{ - // reads Face data of the TriMesh Chunk - - Int_t i; - UShort_t numf = 0, v1, v2, v3, attr; - - fread(&numf, sizeof(UShort_t), 1, f); - printf("Reading %i Faces...", numf); - model.flist = new Face[numf]; - if (model.flist == 0) { - for (i = 0; i < numf; i++) { - fread(&v1, sizeof(UShort_t), 1, f); - fread(&v2, sizeof(UShort_t), 1, f); - fread(&v3, sizeof(UShort_t), 1, f); - fread(&attr, sizeof(UShort_t), 1, f); - } - printf("\nWarning : Insufficient Memory to Load Faces!\n"); - return -1; - } - for (i = 0; i < numf; i++) { - fread(&v1, sizeof(UShort_t), 1, f); - fread(&v2, sizeof(UShort_t), 1, f); - fread(&v3, sizeof(UShort_t), 1, f); - fread(&attr, sizeof(UShort_t), 1, f); - model.flist[i].v1 = (ULong_t)(v1); - model.flist[i].v2 = (ULong_t)(v2); - model.flist[i].v3 = (ULong_t)(v3); - } - model.numfaces = (ULong_t)(numf); - printf("Done!\n"); - return 0; -} - -//______________________________________________________________________________ -Int_t ReadMappingChunk(FILE *f) -{ - // reads Texture Mapping data of the TriMesh Chunk - - UShort_t numuv = 0, i; - Float_t u, v; - - fread(&numuv, sizeof(UShort_t), 1, f); - printf("Reading %i Texture Coordinates...", numuv); - if (numuv != model.numverts) { - for (i = 0; i < numuv; i++) { - fread(&u, sizeof(Float_t), 1, f); - fread(&v, sizeof(Float_t), 1, f); - } - printf("\nWarning : Number of Vertices and Mapping Data do not match!\n"); - return -1; - } - for (i = 0; i < numuv; i++) { - fread(&model.vlist[i].u, sizeof(Float_t), 1, f); - fread(&model.vlist[i].v, sizeof(Float_t), 1, f); - } - printf("Done!\n"); - return 0; -} - -//______________________________________________________________________________ -Int_t ReadASCIIZ(FILE *f, char *name) -{ - // reads a null-terminated string from the given file - - char c = -1; - Int_t index = 0; - - do { - fread(&c, sizeof(char), 1, f); - name[index] = c; - index++; - if (index == 255) { - name[index] = 0; - c = 0; - } - } while ((c != 0) && (!feof(f))); - return 0; -} - -//______________________________________________________________________________ -Int_t ConvertModel() -{ - // Convert from Model structure to Reve::TriangleSet - - Int_t i; - - ts[nummodels] = new Reve::TriangleSet(model.numverts, model.numfaces); - if (ts[nummodels] == 0) - return -1; - for (i=0; iSetVertex(i, model.vlist[i].x, model.vlist[i].y, - model.vlist[i].z); - } - for (i=0; iSetTriangle(i, model.flist[i].v1, model.flist[i].v2, - model.flist[i].v3); - } - ts[nummodels]->SetName(model.name); - ts[nummodels]->SetTransparency(0); - ts[nummodels]->SetColor(0); - for (i = 0; i < nummaterials; i++) { - if (strcmp(model.matname, material[i]->name) == 0) { - ts[nummodels]->SetTransparency(material[i]->transparency); - ts[nummodels]->SetColor(Color_t(TColor::GetColor(material[i]->color[0], - material[i]->color[1], material[i]->color[2]))); - break; - } - } - return 0; -} - -//______________________________________________________________________________ -void view3ds(const char *fname = "nasashuttle.3ds") //"eventhorizon.3ds") -{ - // main... - - Int_t i; - for (i=0;i<2048;i++) ts[i] = 0; - for (i=0;i<1024;i++) material[i] = 0; - model.vlist = 0; - model.flist = 0; - nummodels = 0; - if (Read3DSFile(fname) == 0) { - for (i=0;iGenerateTriangleNormals(); - gReve->AddRenderElement(ts[i]); - } - } - gReve->Redraw3D(kTRUE); - } - for (i = 0; i < nummaterials; i++) - if (material[i] != 0) delete material[i]; -} -- 2.39.3