Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
TGLAxis Class Reference

GL Axis.

To draw a 3D axis in a GL window. The labels are drawn using FTGL.

Definition at line 22 of file TGLAxis.h.

Public Member Functions

 TGLAxis ()
 Constructor.
 
virtual ~TGLAxis ()
 Destructor.
 
void DoLabels ()
 Do labels.
 
void Init ()
 Default initialization.
 
virtual TClassIsA () const
 
void PaintGLAxis (const Double_t p1[3], const Double_t p2[3], Double_t wmin, Double_t wmax, Int_t ndiv, Option_t *opt="")
 Paint GL Axis.
 
void PaintGLAxisBody ()
 Paint horizontal axis body at position (0,0,0)
 
void PaintGLAxisLabels ()
 Paint axis labels on the main tick marks.
 
void PaintGLAxisTickMarks ()
 Paint axis tick marks.
 
void SetGridLength (Double_t grid)
 
void SetLabelsAngles (Double_t a1, Double_t a2, Double_t a3)
 Set labels' angles.
 
void SetLabelsOffset (Double_t offset)
 
void SetLabelsSize (Double_t size)
 
void SetTickMarksLength (Double_t length)
 
void SetTickMarksOrientation (Int_t tmo)
 
virtual void Streamer (TBuffer &)
 
void StreamerNVirtual (TBuffer &ClassDef_StreamerNVirtual_b)
 
void TicksPositions (Option_t *opt="")
 Compute ticks positions.
 
void TicksPositionsNoOpt ()
 Compute ticks positions. Linear and not optimized.
 
void TicksPositionsOpt ()
 Compute ticks positions. Linear and optimized.
 
- Public Member Functions inherited from TAttLine
 TAttLine ()
 AttLine default constructor.
 
 TAttLine (Color_t lcolor, Style_t lstyle, Width_t lwidth)
 AttLine normal constructor.
 
virtual ~TAttLine ()
 AttLine destructor.
 
void Copy (TAttLine &attline) const
 Copy this line attributes to a new TAttLine.
 
Int_t DistancetoLine (Int_t px, Int_t py, Double_t xp1, Double_t yp1, Double_t xp2, Double_t yp2)
 Compute distance from point px,py to a line.
 
virtual Color_t GetLineColor () const
 Return the line color.
 
virtual Style_t GetLineStyle () const
 Return the line style.
 
virtual Width_t GetLineWidth () const
 Return the line width.
 
virtual void Modify ()
 Change current line attributes if necessary.
 
virtual void ResetAttLine (Option_t *option="")
 Reset this line attributes to default values.
 
virtual void SaveLineAttributes (std::ostream &out, const char *name, Int_t coldef=1, Int_t stydef=1, Int_t widdef=1)
 Save line attributes as C++ statement(s) on output stream out.
 
virtual void SetLineAttributes ()
 Invoke the DialogCanvas Line attributes.
 
virtual void SetLineColor (Color_t lcolor)
 Set the line color.
 
virtual void SetLineColorAlpha (Color_t lcolor, Float_t lalpha)
 Set a transparent line color.
 
virtual void SetLineStyle (Style_t lstyle)
 Set the line style.
 
virtual void SetLineWidth (Width_t lwidth)
 Set the line width.
 
void StreamerNVirtual (TBuffer &ClassDef_StreamerNVirtual_b)
 
- Public Member Functions inherited from TAttText
 TAttText ()
 AttText default constructor.
 
 TAttText (Int_t align, Float_t angle, Color_t color, Style_t font, Float_t tsize)
 AttText normal constructor.
 
virtual ~TAttText ()
 AttText destructor.
 
void Copy (TAttText &atttext) const
 Copy this text attributes to a new TAttText.
 
virtual Short_t GetTextAlign () const
 Return the text alignment.
 
virtual Float_t GetTextAngle () const
 Return the text angle.
 
virtual Color_t GetTextColor () const
 Return the text color.
 
virtual Font_t GetTextFont () const
 Return the text font.
 
virtual Float_t GetTextSize () const
 Return the text size.
 
virtual Float_t GetTextSizePercent (Float_t size)
 Return the text in percent of the pad size.
 
virtual void Modify ()
 Change current text attributes if necessary.
 
virtual void ResetAttText (Option_t *toption="")
 Reset this text attributes to default values.
 
virtual void SaveTextAttributes (std::ostream &out, const char *name, Int_t alidef=12, Float_t angdef=0, Int_t coldef=1, Int_t fondef=61, Float_t sizdef=1)
 Save text attributes as C++ statement(s) on output stream out.
 
virtual void SetTextAlign (Short_t align=11)
 Set the text alignment.
 
virtual void SetTextAngle (Float_t tangle=0)
 Set the text angle.
 
virtual void SetTextAttributes ()
 Invoke the DialogCanvas Text attributes.
 
virtual void SetTextColor (Color_t tcolor=1)
 Set the text color.
 
virtual void SetTextColorAlpha (Color_t tcolor, Float_t talpha)
 Set a transparent marker color.
 
virtual void SetTextFont (Font_t tfont=62)
 Set the text font.
 
virtual void SetTextSize (Float_t tsize=1)
 Set the text size.
 
virtual void SetTextSizePixels (Int_t npixels)
 Set the text size in pixel.
 
void StreamerNVirtual (TBuffer &ClassDef_StreamerNVirtual_b)
 

Static Public Member Functions

static TClassClass ()
 
static const char * Class_Name ()
 
static constexpr Version_t Class_Version ()
 
static const char * DeclFileName ()
 
- Static Public Member Functions inherited from TAttLine
static TClassClass ()
 
static const char * Class_Name ()
 
static constexpr Version_t Class_Version ()
 
static const char * DeclFileName ()
 
- Static Public Member Functions inherited from TAttText
static TClassClass ()
 
static const char * Class_Name ()
 
static constexpr Version_t Class_Version ()
 
static const char * DeclFileName ()
 

Private Member Functions

 TGLAxis (const TGLAxis &)
 
TGLAxisoperator= (const TGLAxis &)
 

Private Attributes

Double_t fAngle1
 
Double_t fAngle2
 
Double_t fAngle3
 
Double_t fAxisLength
 
Double_t fGridLength
 
TStringfLabels
 
Double_t fLabelsOffset
 
Double_t fLabelsSize
 
Int_t fNDiv
 
Int_t fNDiv1
 
Int_t fNDiv2
 
Int_t fNDiv3
 
Int_t fNTicks1
 
Int_t fNTicks2
 
TGLTextfText
 
Double_t fTickMarksLength
 
Int_t fTickMarksOrientation
 
Double_tfTicks1
 
Double_tfTicks2
 
Double_t fWmax
 
Double_t fWmin
 

Additional Inherited Members

- Protected Attributes inherited from TAttLine
Color_t fLineColor
 Line color.
 
Style_t fLineStyle
 Line style.
 
Width_t fLineWidth
 Line width.
 
- Protected Attributes inherited from TAttText
Short_t fTextAlign
 Text alignment.
 
Float_t fTextAngle
 Text angle.
 
Color_t fTextColor
 Text color.
 
Font_t fTextFont
 Text font.
 
Float_t fTextSize
 Text size.
 

#include <TGLAxis.h>

Inheritance diagram for TGLAxis:
[legend]

Constructor & Destructor Documentation

◆ TGLAxis() [1/2]

TGLAxis::TGLAxis ( const TGLAxis )
private

◆ TGLAxis() [2/2]

TGLAxis::TGLAxis ( )

Constructor.

Definition at line 35 of file TGLAxis.cxx.

◆ ~TGLAxis()

TGLAxis::~TGLAxis ( )
virtual

Destructor.

Definition at line 66 of file TGLAxis.cxx.

Member Function Documentation

◆ Class()

static TClass * TGLAxis::Class ( )
static
Returns
TClass describing this class

◆ Class_Name()

static const char * TGLAxis::Class_Name ( )
static
Returns
Name of this class

◆ Class_Version()

static constexpr Version_t TGLAxis::Class_Version ( )
inlinestaticconstexpr
Returns
Version of this class

Definition at line 71 of file TGLAxis.h.

◆ DeclFileName()

static const char * TGLAxis::DeclFileName ( )
inlinestatic
Returns
Name of the file containing the class declaration

Definition at line 71 of file TGLAxis.h.

◆ DoLabels()

void TGLAxis::DoLabels ( )

Do labels.

Definition at line 430 of file TGLAxis.cxx.

◆ Init()

void TGLAxis::Init ( )

Default initialization.

Definition at line 43 of file TGLAxis.cxx.

◆ IsA()

virtual TClass * TGLAxis::IsA ( ) const
inlinevirtual
Returns
TClass describing current object

Reimplemented from TAttLine.

Definition at line 71 of file TGLAxis.h.

◆ operator=()

TGLAxis & TGLAxis::operator= ( const TGLAxis )
private

◆ PaintGLAxis()

void TGLAxis::PaintGLAxis ( const Double_t  p1[3],
const Double_t  p2[3],
Double_t  wmin,
Double_t  wmax,
Int_t  ndiv,
Option_t opt = "" 
)

Paint GL Axis.

  • p1, p2 : Axis position in the 3D space.
  • wmin, wmax : Minimum and maximum values along the axis. wmin < wmax.
  • ndiv : Number of axis divisions. It is an integer in the form "ttsspp" where "tt" is the number of tertiary divisions, "ss" is the number of secondary divisions and "pp" the number of primary divisions.
  • opt : Options. "N" - By default the number of divisions is optimized to get a nice labeling. When option "N" is given, the number of divisions is not optimized.

Definition at line 88 of file TGLAxis.cxx.

◆ PaintGLAxisBody()

void TGLAxis::PaintGLAxisBody ( )

Paint horizontal axis body at position (0,0,0)

Definition at line 168 of file TGLAxis.cxx.

◆ PaintGLAxisLabels()

void TGLAxis::PaintGLAxisLabels ( )

Paint axis labels on the main tick marks.

Definition at line 255 of file TGLAxis.cxx.

◆ PaintGLAxisTickMarks()

void TGLAxis::PaintGLAxisTickMarks ( )

Paint axis tick marks.

Definition at line 185 of file TGLAxis.cxx.

◆ SetGridLength()

void TGLAxis::SetGridLength ( Double_t  grid)
inline

Definition at line 68 of file TGLAxis.h.

◆ SetLabelsAngles()

void TGLAxis::SetLabelsAngles ( Double_t  a1,
Double_t  a2,
Double_t  a3 
)

Set labels' angles.

Definition at line 446 of file TGLAxis.cxx.

◆ SetLabelsOffset()

void TGLAxis::SetLabelsOffset ( Double_t  offset)
inline

Definition at line 66 of file TGLAxis.h.

◆ SetLabelsSize()

void TGLAxis::SetLabelsSize ( Double_t  size)
inline

Definition at line 67 of file TGLAxis.h.

◆ SetTickMarksLength()

void TGLAxis::SetTickMarksLength ( Double_t  length)
inline

Definition at line 64 of file TGLAxis.h.

◆ SetTickMarksOrientation()

void TGLAxis::SetTickMarksOrientation ( Int_t  tmo)
inline

Definition at line 65 of file TGLAxis.h.

◆ Streamer()

virtual void TGLAxis::Streamer ( TBuffer )
virtual

Reimplemented from TAttLine.

◆ StreamerNVirtual()

void TGLAxis::StreamerNVirtual ( TBuffer ClassDef_StreamerNVirtual_b)
inline

Definition at line 71 of file TGLAxis.h.

◆ TicksPositions()

void TGLAxis::TicksPositions ( Option_t opt = "")

Compute ticks positions.

Definition at line 298 of file TGLAxis.cxx.

◆ TicksPositionsNoOpt()

void TGLAxis::TicksPositionsNoOpt ( )

Compute ticks positions. Linear and not optimized.

Definition at line 331 of file TGLAxis.cxx.

◆ TicksPositionsOpt()

void TGLAxis::TicksPositionsOpt ( )

Compute ticks positions. Linear and optimized.

Definition at line 363 of file TGLAxis.cxx.

Member Data Documentation

◆ fAngle1

Double_t TGLAxis::fAngle1
private

Definition at line 45 of file TGLAxis.h.

◆ fAngle2

Double_t TGLAxis::fAngle2
private

Definition at line 46 of file TGLAxis.h.

◆ fAngle3

Double_t TGLAxis::fAngle3
private

Definition at line 47 of file TGLAxis.h.

◆ fAxisLength

Double_t TGLAxis::fAxisLength
private

Definition at line 36 of file TGLAxis.h.

◆ fGridLength

Double_t TGLAxis::fGridLength
private

Definition at line 43 of file TGLAxis.h.

◆ fLabels

TString* TGLAxis::fLabels
private

Definition at line 35 of file TGLAxis.h.

◆ fLabelsOffset

Double_t TGLAxis::fLabelsOffset
private

Definition at line 41 of file TGLAxis.h.

◆ fLabelsSize

Double_t TGLAxis::fLabelsSize
private

Definition at line 42 of file TGLAxis.h.

◆ fNDiv

Int_t TGLAxis::fNDiv
private

Definition at line 27 of file TGLAxis.h.

◆ fNDiv1

Int_t TGLAxis::fNDiv1
private

Definition at line 28 of file TGLAxis.h.

◆ fNDiv2

Int_t TGLAxis::fNDiv2
private

Definition at line 29 of file TGLAxis.h.

◆ fNDiv3

Int_t TGLAxis::fNDiv3
private

Definition at line 30 of file TGLAxis.h.

◆ fNTicks1

Int_t TGLAxis::fNTicks1
private

Definition at line 31 of file TGLAxis.h.

◆ fNTicks2

Int_t TGLAxis::fNTicks2
private

Definition at line 32 of file TGLAxis.h.

◆ fText

TGLText* TGLAxis::fText
private

Definition at line 44 of file TGLAxis.h.

◆ fTickMarksLength

Double_t TGLAxis::fTickMarksLength
private

Definition at line 39 of file TGLAxis.h.

◆ fTickMarksOrientation

Int_t TGLAxis::fTickMarksOrientation
private

Definition at line 40 of file TGLAxis.h.

◆ fTicks1

Double_t* TGLAxis::fTicks1
private

Definition at line 33 of file TGLAxis.h.

◆ fTicks2

Double_t* TGLAxis::fTicks2
private

Definition at line 34 of file TGLAxis.h.

◆ fWmax

Double_t TGLAxis::fWmax
private

Definition at line 38 of file TGLAxis.h.

◆ fWmin

Double_t TGLAxis::fWmin
private

Definition at line 37 of file TGLAxis.h.

Libraries for TGLAxis:

The documentation for this class was generated from the following files: