Demonstrates usage of TEveBox class.
{
b->SetMainTransparency(0);
#define RND_BOX(x) r.Uniform(-(x), (x))
b->SetVertex(0,
x -
a + RND_BOX(
d),
y -
a + RND_BOX(
d), z -
a + RND_BOX(
d));
b->SetVertex(1,
x -
a + RND_BOX(
d),
y +
a + RND_BOX(
d), z -
a + RND_BOX(
d));
b->SetVertex(2,
x +
a + RND_BOX(
d),
y +
a + RND_BOX(
d), z -
a + RND_BOX(
d));
b->SetVertex(3,
x +
a + RND_BOX(
d),
y -
a + RND_BOX(
d), z -
a + RND_BOX(
d));
b->SetVertex(4,
x -
a + RND_BOX(
d),
y -
a + RND_BOX(
d), z +
a + RND_BOX(
d));
b->SetVertex(5,
x -
a + RND_BOX(
d),
y +
a + RND_BOX(
d), z +
a + RND_BOX(
d));
b->SetVertex(6,
x +
a + RND_BOX(
d),
y +
a + RND_BOX(
d), z +
a + RND_BOX(
d));
b->SetVertex(7,
x +
a + RND_BOX(
d),
y -
a + RND_BOX(
d), z +
a + RND_BOX(
d));
#undef RND_BOX
}
R__EXTERN TEveManager * gEve
R__EXTERN TRandom * gRandom
3D box with arbitrary vertices (cuboid).
void AddElement(TEveElement *element, TEveElement *parent=0)
Add an element.
static TEveManager * Create(Bool_t map_window=kTRUE, Option_t *opt="FIV")
If global TEveManager* gEve is not set initialize it.
void Redraw3D(Bool_t resetCameras=kFALSE, Bool_t dropLogicals=kFALSE)
This is the base class for the ROOT Random number generators.
void box(Int_t pat, Double_t x1, Double_t y1, Double_t x2, Double_t y2)
- Author
- Matevz Tadel
Definition in file box.C.