Rene Brun
//_____________________________________________________________________________
void ATLFDisplay::DrawAllViews()
{
// Draw front,top,side and 30 deg views
m_DrawAllViews = kTRUE;
m_Pad->cd();
m_Pad->SetFillColor(15);
m_Pad->Clear();
m_Pad->Divide(2,2);
// draw 30 deg view
m_Pad->cd(1);
DrawView(30, 30);
DrawTitle();
// draw front view
m_Pad->cd(2);
DrawView(0, -90);
DrawTitle("Front");
// draw top view
m_Pad->cd(3);
DrawView(90, -90);
DrawTitle("Top");
// draw side view
m_Pad->cd(4);
DrawView(90, 0);
DrawTitle("Side");
m_Pad->cd(2);
}
//_____________________________________________________________________________
void ATLFDisplay::DrawView(Float_t theta, Float_t phi)
{
// Draw a view of ATLAS
gPad->SetFillColor(1);
// Display ATLAS outline
gPad->Clear();
Int_t iret;
TView *view = new TView(1);
view->SetRange(-m_Rin, -m_Rin, -m_Zin, m_Rin, m_Rin, m_Zin);
m_Nodin->Draw("same");
// add itself to the list
AppendPad();
//Loop on all makers to add their products to the pad
TIter next(gATLFast->Makers());
ATLFMaker *maker;
while ((maker = (ATLFMaker*)next())) {
maker->Draw();
}
view->SetView(phi, theta, 0, iret);
}
Rutger van der Eijk wrote:
>
> Hi rooters,
>
> When a TNode is drawn in a TPad the z-axis is always orientated 'up' (i.e.
> to the top of my screen). However I would like the z-axis to be horizontal
> (i.e. along a beam-axis). Is there an option to change this 'default'
> orientation?
>
> (I could define a mother volume around the TNode and have the child TNode
> orientated such that Z becomes horizontal. However I don't want this
> because I want to use the same event display to draw sub-parts of the
> detector (i.e. child TNodes, child/child TNodes etc...), which would mean
> defining these extra TNodes for every sub node...)
>
> Thanks,
>
> Rutger van der Eijk