]> git.uio.no Git - u/mrichter/AliRoot.git/blame - STRUCT/AliFRAMEv0.cxx
Updated a bit with:
[u/mrichter/AliRoot.git] / STRUCT / AliFRAMEv0.cxx
CommitLineData
4c039060 1/**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3 * *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
6 * *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
15
16/*
17$Log$
13391c3e 18Revision 1.14 2000/10/02 21:28:15 fca
19Removal of useless dependecies via forward declarations
20
94de3818 21Revision 1.13 2000/06/11 12:34:49 morsch
22Coding rule violations corrected
23
b43eb0dc 24Revision 1.12 2000/02/23 16:25:24 fca
25AliVMC and AliGeant3 classes introduced
26ReadEuclid moved from AliRun to AliModule
27
b13db077 28Revision 1.11 1999/11/01 20:42:42 fca
29FRAME version 1 is now the symmetric one.
30
ba25f477 31Revision 1.10 1999/10/06 20:56:55 fca
32Introducing new frame 1099
33
90a46d5c 34Revision 1.9 1999/09/29 09:24:30 fca
35Introduction of the Copyright and cvs Log
36
4c039060 37*/
38
fe4da5cc 39////////////////////////////////////////////////
40// space frame class /
41////////////////////////////////////////////////
42
fe4da5cc 43#include "AliFRAMEv0.h"
44#include "AliRun.h"
94de3818 45#include "AliMC.h"
fe4da5cc 46#include "TSystem.h"
47
48ClassImp(AliFRAMEv0)
49
50//_____________________________________________________________________________
b8032157 51AliFRAMEv0::AliFRAMEv0()
fe4da5cc 52{
b43eb0dc 53// Constructor
fe4da5cc 54}
55
56//_____________________________________________________________________________
57AliFRAMEv0::AliFRAMEv0(const char *name, const char *title)
58 : AliFRAME(name,title)
59{
b43eb0dc 60// Constructor
dda5e866 61 printf("Create FRAMEv0 object\n");
90a46d5c 62 fEuclidGeometry="$(ALICE_ROOT)/Euclid/frame1099h.euc";
dda5e866 63 fEuclidMaterial="$(ALICE_ROOT)/Euclid/frame.tme";
fe4da5cc 64}
65
66
67//___________________________________________
68void AliFRAMEv0::CreateGeometry()
69{
fe4da5cc 70//Begin_Html
71/*
1439f98e 72<img src="picts/frame.gif">
fe4da5cc 73*/
74//End_Html
75
76
77//Begin_Html
78/*
1439f98e 79<img src="picts/tree_frame.gif">
fe4da5cc 80*/
81//End_Html
82
fe4da5cc 83 char *filetmp;
fe4da5cc 84 char topvol[5];
fe4da5cc 85
86//
87// The Space frame
dda5e866 88 filetmp = gSystem->ExpandPathName(fEuclidGeometry.Data());
fe4da5cc 89 FILE *file = fopen(filetmp,"r");
90 delete [] filetmp;
91 if(file) {
92 fclose(file);
dda5e866 93 printf(" Reading FRAME geometry\n");
b13db077 94 ReadEuclid(fEuclidGeometry.Data(),topvol);
fe4da5cc 95 } else {
dda5e866 96 Warning("CreateGeometry","The Euclid file %s does not exist!\n",
97 fEuclidGeometry.Data());
fe4da5cc 98 exit(1);
99 }
100//
101// --- Place the FRAME ghost volume (B010) in its mother volume (ALIC)
102// and make it invisible
103//
104// AliMatrix(idrotm[2001],90.,0.,90.,90.,180.,0.);
fe4da5cc 105
dda5e866 106 gMC->Gspos(topvol,1,"ALIC",0,0,0,0,"ONLY");
107
108 gMC->Gsatt(topvol, "SEEN", 0);
fe4da5cc 109}
110
111
fe4da5cc 112//___________________________________________
113void AliFRAMEv0::CreateMaterials()
114{
13391c3e 115// Create Geant materials
116//
fe4da5cc 117 char *filetmp;
dda5e866 118 printf("Create FRAMEv0 materials\n");
119 filetmp = gSystem->ExpandPathName(fEuclidMaterial.Data());
fe4da5cc 120 FILE *file = fopen(filetmp,"r");
121 delete [] filetmp;
122 if(file) {
123 fclose(file);
b13db077 124 ReadEuclidMedia(fEuclidMaterial.Data());
fe4da5cc 125 } else {
dda5e866 126 Warning("CreateMaterials","The material file %s does not exist!\n",
127 fEuclidMaterial.Data());
fe4da5cc 128 exit(1);
129 }
130}
131
ba25f477 132//_____________________________________________________________________________
133void AliFRAMEv0::Init()
134{
135 //
136 // Initialise the module after the geometry has been defined
137 //
138
139 printf("**************************************"
140 " FRAME "
141 "**************************************\n");
142 printf("\n Version 0 of FRAME initialised, "
143 "with openings for PHOS and RICH\n\n");
144 printf("**************************************"
145 " FRAME "
146 "**************************************\n");
147
148}
fe4da5cc 149
150
151
152
153
154
155
156
157
158
159
160
161