00001 //*-- Author : Valery Fine 29/06/99 (E-mail: fine@bnl.gov) 00002 // $Id: St_geom_Maker.h,v 1.8 2003/09/10 19:47:47 perev Exp $ 00003 // $Log: St_geom_Maker.h,v $ 00004 // Revision 1.8 2003/09/10 19:47:47 perev 00005 // ansi corrs 00006 // 00007 // Revision 1.7 2001/06/01 03:04:25 perev 00008 // overloaded GetDataSet -> FindDataSet 00009 // 00010 // Revision 1.6 2000/03/28 19:28:09 fine 00011 // Adjusted to ROOT 2.24 00012 // 00013 // Revision 1.5 1999/07/15 13:58:10 perev 00014 // cleanup 00015 // 00016 // Revision 1.4 1999/07/13 00:52:49 fine 00017 // Some corrections 00018 // 00019 // Revision 1.3 1999/07/02 20:01:22 fine 00020 // The name of the maker is the geom file name 00021 // 00022 // Revision 1.2 1999/06/30 16:27:43 fine 00023 // Comments make up 00024 // 00025 // Revision 1.1 1999/06/29 20:50:34 fine 00026 // Maker to provide a St_node geom structure for others 00027 // 00028 00029 #ifndef STAR_St_geom_Maker 00030 #define STAR_St_geom_Maker 00031 00033 // // 00034 // St_geom_Maker class for Makers // 00035 // // 00036 // This maker is to initialize the STAR GEANT geometry description. // 00037 // "Geometry description" is an instance of the St_Node class derived // 00038 // from St_DataSet class. // 00039 // // 00040 // This means one can apply St_DataSetIter and TBrowser to navigate it // 00041 // One can get a pointer to the top level St_Node object named "HALL" // 00042 // via // 00043 // St_Node *hallNode = (St_Node *)StMaker::GetDataSet("HALL") method // 00044 // // 00045 // It is assumed the St_geom_Maker object was instantiated and // 00046 // initialized by the the top level StChain object // 00047 // (see $STAR/StRoot/macros/graphics/PadBrowser.C macro as a pattern // 00048 // // 00049 // To get the ROOT Browser and graphics view of the full structure // 00050 // one try: // 00051 // ____________________________________________________________________ // 00052 // // 00053 // root [0] gSystem->Load("St_base"); 00054 // root [1] gSystem->Load("StChain"); 00055 // root [2] gSystem->Load("St_geom_Maker"); 00056 // root [3] St_geom_Maker geomMaker; 00057 // root [4] geomMaker.Init(); 00058 // 00059 // root [5] TBrowser b("HALL",geomMaker.GetDataSet("HALL")); 00060 // begin_html <P ALIGN=CENTER> <IMG SRC="gif/geomMakerBrowse.gif" ></P> end_html 00061 // root [6] ((St_Node *)geomMaker.GetDataSet("HALL"))->Draw(); 00062 // begin_html <P ALIGN=CENTER> <IMG SRC="gif/geomMakerPad.gif" ></P> end_html 00063 // root [7] // One can add two extra lines to get "Control Panel" 00064 // root [8] .x PadControlPanel.C 00065 // begin_html <P ALIGN=CENTER> <IMG SRC="gif/PadControlPanel.gif" ></P> end_html 00066 // root [9] // Plot 3D axice as follows: 00067 // root [10] St_PolyLine3D::Axis(); 00068 // ____________________________________________________________________ // 00069 // 00070 // Submit any problem with this code via begin_html <A HREF="http://www.rhic.bnl.gov/STAR/html/comp_l/sofi/bugs/send-pr.html"><B><I>"STAR Problem Report Form"</I></B></A> end_html 00071 // // 00073 00074 #ifndef StMaker_H 00075 #include "StMaker.h" 00076 #endif 00077 #include "St_DataSet.h" 00078 00079 class St_geom_Maker : public StMaker { 00080 private: 00081 // static Char_t m_VersionCVS = "$Id: St_geom_Maker.h,v 1.8 2003/09/10 19:47:47 perev Exp $"; 00082 00083 protected: 00084 virtual St_DataSet *FindDataSet (const char* logInput, 00085 const StMaker *uppMk=0, 00086 const StMaker *dowMk=0) const ; 00087 public: 00088 St_geom_Maker(const char *name="star.root"); 00089 virtual ~St_geom_Maker(); 00090 virtual Int_t Init(); 00091 virtual Int_t Make(); 00092 virtual void SetGeomFileName(const Char_t *fileName){SetName(fileName);} 00093 virtual const Char_t *GetGeomFileName(){ return GetName();} 00094 // virtual void Set_mode (Int_t m = 2){m_mode = m;} // *MENU* 00095 virtual const char *GetCVS() const 00096 {static const char cvs[]="Tag $Name: $ $Id: St_geom_Maker.h,v 1.8 2003/09/10 19:47:47 perev Exp $ built "__DATE__" "__TIME__ ; return cvs;} 00097 00098 ClassDef(St_geom_Maker,0) //StAF chain virtual base class for Makers 00099 }; 00100 00101 #endif
1.5.9