Logo ROOT  
Reference Guide
TEveProjectionAxes.cxx
Go to the documentation of this file.
1 // @(#)root/eve:$Id$
2 // Author: Matevz Tadel 2007
3 
4 /*************************************************************************
5 * Copyright (C) 1995-2007, Rene Brun and Fons Rademakers. *
6 * All rights reserved. *
7 * *
8 * For the licensing terms see $ROOTSYS/LICENSE. *
9 * For the list of contributors see $ROOTSYS/README/CREDITS. *
10 *************************************************************************/
11 
12 #include "TEveProjectionAxes.h"
13 #include "TEveProjectionManager.h"
14 
15 
16 /** \class TEveProjectionAxes
17 \ingroup TEve
18 Axes for non-linear projections. Show scale of TEveProjectionManager
19 children. With different step mode tick-marks can positioned
20 equidistant or placed with value monotonically increasing from lower left corner
21 of bounding box.
22 */
23 
25 
26 ////////////////////////////////////////////////////////////////////////////////
27 /// Constructor.
28 
30  TEveElement(),
31  TNamed("TEveProjectionAxes", ""),
32  fManager(m),
33 
34  fUseColorSet(useCS),
35 
36  fLabMode(kValue),
37  fAxesMode(kAll),
38 
39  fDrawCenter(kFALSE),
40  fDrawOrigin(kFALSE)
41 {
43  fManager->AddDependent(this);
44 
45  // Axis attributes.
46  fNdivisions = 1010;
47  fLabelSize = 0.015;
48  fLabelColor = kGray+1;
49  fAxisColor = kGray+1;
50  fTickLength = 0.015;
51  fLabelOffset = 0.01;
52 }
53 
54 ////////////////////////////////////////////////////////////////////////////////
55 /// Destructor.
56 
58 {
60 }
61 
62 ////////////////////////////////////////////////////////////////////////////////
63 /// Paint this object. Only direct rendering is supported.
64 
66 {
67  PaintStandard(this);
68 }
69 
70 ////////////////////////////////////////////////////////////////////////////////
71 /// Virtual from TAttBBox; fill bounding-box information.
72 
74 {
75  static const TEveException eH("TEveProjectionManager::ComputeBBox ");
76 
77  BBoxZero();
78  if(fManager == 0 || fManager->GetBBox() == 0)
79  return;
80 
81  for (Int_t i=0; i<6; ++i)
82  fBBox[i] = fManager->GetBBox()[i];
83 
84  AssertBBoxExtents(0.1);
85 }
86 
87 ////////////////////////////////////////////////////////////////////////////////
88 /// Return TEveProjectionAxes icon.
89 
91 {
93 }
m
auto * m
Definition: textangle.C:8
TEveElement::fCanEditMainTrans
Bool_t fCanEditMainTrans
Definition: TEveElement.h:96
TAttAxis::fNdivisions
Int_t fNdivisions
Number of divisions(10000*n3 + 100*n2 + n1)
Definition: TAttAxis.h:20
TEveElement::PaintStandard
virtual void PaintStandard(TObject *id)
Paint object – a generic implementation for EVE elements.
Definition: TEveElement.cxx:1034
TEveElement
Base class for TEveUtil visualization elements, providing hierarchy management, rendering control and...
Definition: TEveElement.h:36
TGPicture
Definition: TGPicture.h:36
Option_t
const char Option_t
Definition: RtypesCore.h:66
TEveProjectionAxes::fManager
TEveProjectionManager * fManager
Definition: TEveProjectionAxes.h:41
TEveProjectionManager::AddDependent
void AddDependent(TEveElement *el)
Add el as dependent element.
Definition: TEveProjectionManager.cxx:72
TAttAxis::fAxisColor
Color_t fAxisColor
Color of the line axis.
Definition: TAttAxis.h:21
ClassImp
#define ClassImp(name)
Definition: Rtypes.h:364
TEveElement::fgListTreeIcons
static const TGPicture * fgListTreeIcons[9]
Definition: TEveElement.h:65
TAttBBox::BBoxZero
void BBoxZero(Float_t epsilon=0, Float_t x=0, Float_t y=0, Float_t z=0)
Create cube of volume (2*epsilon)^3 at (x,y,z).
Definition: TAttBBox.cxx:42
TAttAxis::fTickLength
Float_t fTickLength
Length of tick marks.
Definition: TAttAxis.h:26
TAttBBox::AssertBBoxExtents
void AssertBBoxExtents(Float_t epsilon=0.005)
Assert extents of all sides of the bounding-box are at least epsilon.
Definition: TAttBBox.cxx:62
TAttBBox::fBBox
Float_t * fBBox
Definition: TAttBBox.h:20
bool
TEveProjectionAxes::ComputeBBox
virtual void ComputeBBox()
Virtual from TAttBBox; fill bounding-box information.
Definition: TEveProjectionAxes.cxx:73
TEveProjectionManager.h
TEveProjectionManager
Manager class for steering of projections and managing projected objects.
Definition: TEveProjectionManager.h:22
TNamed
The TNamed class is the base class for all named ROOT classes.
Definition: TNamed.h:29
kFALSE
const Bool_t kFALSE
Definition: RtypesCore.h:92
TEveProjectionAxes::Paint
virtual void Paint(Option_t *option="")
Paint this object. Only direct rendering is supported.
Definition: TEveProjectionAxes.cxx:65
TEveProjectionAxes::GetListTreeIcon
virtual const TGPicture * GetListTreeIcon(Bool_t open=kFALSE)
Return TEveProjectionAxes icon.
Definition: TEveProjectionAxes.cxx:90
TEveProjectionAxes.h
TEveProjectionAxes::~TEveProjectionAxes
virtual ~TEveProjectionAxes()
Destructor.
Definition: TEveProjectionAxes.cxx:57
TAttBBox::GetBBox
Float_t * GetBBox()
Definition: TAttBBox.h:44
TEveException
Exception class thrown by TEve classes and macros.
Definition: TEveUtil.h:102
TEveProjectionAxes
Axes for non-linear projections.
Definition: TEveProjectionAxes.h:29
TAttAxis::fLabelSize
Float_t fLabelSize
Size of labels.
Definition: TAttAxis.h:25
TEveProjectionAxes::TEveProjectionAxes
TEveProjectionAxes(const TEveProjectionAxes &)
kGray
@ kGray
Definition: Rtypes.h:65
CPyCppyy::Utility::kValue
@ kValue
Definition: Utility.h:36
TAttAxis::fLabelColor
Color_t fLabelColor
Color of labels.
Definition: TAttAxis.h:22
TEveProjectionManager::RemoveDependent
void RemoveDependent(TEveElement *el)
Remove el as dependent element.
Definition: TEveProjectionManager.cxx:80
TAttAxis::fLabelOffset
Float_t fLabelOffset
Offset of labels.
Definition: TAttAxis.h:24
int