31 TGeometry *geom =
new TGeometry(
"sample",
"sample");
42 TBRIK *world =
new TBRIK(
"world",
"world",
"void", bigdim, bigdim, bigdim);
45 TNode *worldnode =
new TNode(
"worldnode",
"world node", world);
46 worldnode->SetVisibility(0);
51 Float_t x[] = {-0.50, -1.20, 1.20, 0.50, 0.50, 1.20, -1.20, -0.50};
52 Float_t y[] = {-0.75, -2.00, -2.00, -0.75, 0.75, 2.00, 2.00, 0.75};
53 Float_t z[] = {-0.50, -1.50, -1.50, 1.50, 1.50, 0.50};
54 Float_t s[] = {0.50, 1.00, 1.50, 1.50, 1.00, 0.50};
56 Float_t convexscale[] = {7.0, -1.0, 1.5};
58 Int_t icolor[] = {1, 2, 3, 2, 2, 2, 4, 2, 6};
63 for (
Int_t zcase = 0; zcase < 3; zcase++) {
64 if (zcase == 1 && !domalformed)
66 for (
Int_t xycase = 0; xycase < 3; xycase++) {
67 if (xycase == 1 && !domalformed)
71 sprintf(
name,
"txtru%1d%1d%1d", xycase, zcase, zseg);
72 TXTRU *mytxtru =
new TXTRU(
name,
name,
"void", 8, 2);
75 Float_t xsign = (makecw) ? -1 : 1;
76 Float_t zsign = (reversez) ? -1 : 1;
79 for (i = 0; i < nxy; i++) {
82 if (i == 0 || i == 3 || i == 4 || i == 7)
83 xtmp *= convexscale[xycase];
86 mytxtru->DefineVertex(i, xtmp, ytmp);
89 for (i = 0, j = 0; i < zseg; i++) {
92 ztmp *= convexscale[zcase];
95 if (zseg > 2 && zcase != 2 && (i == 1 || i == 4))
97 mytxtru->DefineSection(j, ztmp, s[i]);
101 TNode *txtrunode =
new TNode(
name,
name, mytxtru);
102 txtrunode->SetLineColor(icolor[3 * zcase + xycase]);
103 Float_t pos_scale = (domalformed) ? 10 : 6;
106 txtrunode->SetPosition(
xpos,
ypos, 0.);
113 TCONE *zcone =
new TCONE(
"zcone",
"zcone",
"void", zhalf, 0., rmax, 0., 0.);
114 zcone->SetVisibility(extravis);
115 TNode *zconenode =
new TNode(
"zconenode",
"zconenode", zcone);
116 zconenode->SetLineColor(3);
119 TBRIK *zbrik =
new TBRIK(
"zbrik",
"zbrik",
"void", rmax, rmax, dzstub);
120 zbrik->SetVisibility(extravis);
121 TNode *zbriknode =
new TNode(
"zbriknode",
"zbriknode", zbrik);
122 zbriknode->SetPosition(0., 0., zhalf + dzstub);
123 zbriknode->SetLineColor(3);
139 for (i = 0; i < 3; i++)
140 center[i] = 0.5 * (max[i] + min[i]);
143 for (i = 0; i < 3; i++)
144 maxSide =
TMath::Max(maxSide, max[i] - center[i]);
146 for (i = 0; i < 3; i++) {
147 max[i] = center[i] + maxSide;
148 min[i] = center[i] - maxSide;
bool Bool_t
Boolean (0=false, 1=true) (bool)
int Int_t
Signed integer 4 bytes (int)
float Float_t
Float 4 bytes (float)
double Double_t
Double 8 bytes.
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void xpos
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void ypos
virtual void GetRange(Float_t *min, Float_t *max)=0
virtual void SetRange(const Double_t *min, const Double_t *max)=0
TVirtualPad is an abstract base class for the Pad and Canvas classes.
virtual void Modified(Bool_t flag=1)=0
virtual TView * GetView() const =0
Short_t Max(Short_t a, Short_t b)
Returns the largest of a and b.