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

3 component (x/y/z) vector class.

This is part of collection of utility classes for GL in TGLUtil.h/cxx These provide const and non-const accessors Arr() / CArr() to a GL compatible internal field - so can be used directly with OpenGL C API calls. They are not intended to be fully featured just provide minimum required.

Definition at line 247 of file TGLUtil.h.

Public Member Functions

 TGLVector3 ()=default
 TGLVector3 (const Double_t *src)
 Construct a vector with components (src[0], src[1], src[2]).
 TGLVector3 (Double_t x, Double_t y, Double_t z)
 Construct a vector with components (x,y,z).
Double_tArr ()
const Double_tCArr () const
void Dump () const
 Output vertex component values to std::cout.
void Fill (Double_t val)
TClassIsA () const
Double_t Mag () const
void Maximum (const TGLVertex3 &other)
void Minimum (const TGLVertex3 &other)
void Negate ()
void Normalise ()
TGLVertex3operator*= (Double_t f)
const TGLVertex3operator+= (const TGLVector3 &val)
TGLVector3 operator- () const
const TGLVertex3operator-= (const TGLVector3 &val)
TGLVector3operator/= (Double_t val)
TGLVector3operator= (const TGLVertex3 &v)
Bool_t operator== (const TGLVertex3 &rhs) const
Double_toperator[] (Int_t index)
const Double_toperator[] (Int_t index) const
void Set (const Double_t *xyz)
void Set (const TGLVertex3 &other)
void Set (Double_t x, Double_t y, Double_t z)
void Shift (Double_t xDelta, Double_t yDelta, Double_t zDelta)
 Offset a vertex by components (xDelta, yDelta, zDelta).
void Shift (TGLVector3 &shift)
 Offset a vertex by vector 'shift'.
void Streamer (TBuffer &)
void StreamerNVirtual (TBuffer &ClassDef_StreamerNVirtual_b)
Double_tX ()
Double_t X () const
Double_tY ()
Double_t Y () const
Double_tZ ()
Double_t Z () const

Static Public Member Functions

static TClassClass ()
static const char * Class_Name ()
static constexpr Version_t Class_Version ()
static const char * DeclFileName ()

Protected Member Functions

Bool_t ValidIndex (UInt_t index) const

Protected Attributes

Double_t fVals [3]

#include <TGLUtil.h>

Inheritance diagram for TGLVector3:
TGLVertex3

Constructor & Destructor Documentation

◆ TGLVector3() [1/3]

TGLVector3::TGLVector3 ( )
default

◆ TGLVector3() [2/3]

TGLVector3::TGLVector3 ( Double_t x,
Double_t y,
Double_t z )

Construct a vector with components (x,y,z).

Definition at line 149 of file TGLUtil.cxx.

◆ TGLVector3() [3/3]

TGLVector3::TGLVector3 ( const Double_t * src)

Construct a vector with components (src[0], src[1], src[2]).

Definition at line 157 of file TGLUtil.cxx.

Member Function Documentation

◆ Arr()

Double_t * TGLVertex3::Arr ( )
inlineinherited

Definition at line 127 of file TGLUtil.h.

◆ CArr()

const Double_t * TGLVertex3::CArr ( ) const
inlineinherited

Definition at line 126 of file TGLUtil.h.

◆ Class()

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

◆ Class_Name()

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

◆ Class_Version()

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

Definition at line 263 of file TGLUtil.h.

◆ DeclFileName()

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

Definition at line 263 of file TGLUtil.h.

◆ Dump()

void TGLVertex3::Dump ( ) const
inherited

Output vertex component values to std::cout.

Definition at line 129 of file TGLUtil.cxx.

◆ Fill()

void TGLVertex3::Fill ( Double_t val)
inlineinherited

Definition at line 204 of file TGLUtil.h.

◆ IsA()

TClass * TGLVector3::IsA ( ) const
inline
Returns
TClass describing current object

Definition at line 263 of file TGLUtil.h.

◆ Mag()

Double_t TGLVector3::Mag ( ) const
inline

Definition at line 298 of file TGLUtil.h.

◆ Maximum()

void TGLVertex3::Maximum ( const TGLVertex3 & other)
inherited

Definition at line 119 of file TGLUtil.cxx.

◆ Minimum()

void TGLVertex3::Minimum ( const TGLVertex3 & other)
inherited

Definition at line 110 of file TGLUtil.cxx.

◆ Negate()

void TGLVertex3::Negate ( )
inlineinherited

Definition at line 141 of file TGLUtil.h.

◆ Normalise()

void TGLVector3::Normalise ( )
inline

Definition at line 304 of file TGLUtil.h.

◆ operator*=()

TGLVertex3 & TGLVertex3::operator*= ( Double_t f)
inlineinherited

Definition at line 173 of file TGLUtil.h.

◆ operator+=()

const TGLVertex3 & TGLVertex3::operator+= ( const TGLVector3 & val)
inlineinherited

Definition at line 276 of file TGLUtil.h.

◆ operator-()

TGLVector3 TGLVector3::operator- ( ) const
inline

Definition at line 292 of file TGLUtil.h.

◆ operator-=()

const TGLVertex3 & TGLVertex3::operator-= ( const TGLVector3 & val)
inlineinherited

Definition at line 268 of file TGLUtil.h.

◆ operator/=()

TGLVector3 & TGLVector3::operator/= ( Double_t val)
inline

Definition at line 283 of file TGLUtil.h.

◆ operator=()

TGLVector3 & TGLVector3::operator= ( const TGLVertex3 & v)
inline

Definition at line 254 of file TGLUtil.h.

◆ operator==()

Bool_t TGLVertex3::operator== ( const TGLVertex3 & rhs) const
inlineinherited

Definition at line 149 of file TGLUtil.h.

◆ operator[]() [1/2]

Double_t & TGLVertex3::operator[] ( Int_t index)
inlineinherited

Definition at line 182 of file TGLUtil.h.

◆ operator[]() [2/2]

const Double_t & TGLVertex3::operator[] ( Int_t index) const
inlineinherited

Definition at line 193 of file TGLUtil.h.

◆ Set() [1/3]

void TGLVertex3::Set ( const Double_t * xyz)
inlineinherited

Definition at line 218 of file TGLUtil.h.

◆ Set() [2/3]

void TGLVertex3::Set ( const TGLVertex3 & other)
inlineinherited

Definition at line 226 of file TGLUtil.h.

◆ Set() [3/3]

void TGLVertex3::Set ( Double_t x,
Double_t y,
Double_t z )
inlineinherited

Definition at line 210 of file TGLUtil.h.

◆ Shift() [1/2]

void TGLVertex3::Shift ( Double_t xDelta,
Double_t yDelta,
Double_t zDelta )
inherited

Offset a vertex by components (xDelta, yDelta, zDelta).

Definition at line 101 of file TGLUtil.cxx.

◆ Shift() [2/2]

void TGLVertex3::Shift ( TGLVector3 & shift)
inherited

Offset a vertex by vector 'shift'.

Definition at line 91 of file TGLUtil.cxx.

◆ Streamer()

void TGLVector3::Streamer ( TBuffer & )

◆ StreamerNVirtual()

void TGLVector3::StreamerNVirtual ( TBuffer & ClassDef_StreamerNVirtual_b)
inline

Definition at line 263 of file TGLUtil.h.

◆ ValidIndex()

Bool_t TGLVertex3::ValidIndex ( UInt_t index) const
inlineprotectedinherited

Definition at line 87 of file TGLUtil.h.

◆ X() [1/2]

Double_t & TGLVertex3::X ( )
inlineinherited

Definition at line 120 of file TGLUtil.h.

◆ X() [2/2]

Double_t TGLVertex3::X ( ) const
inlineinherited

Definition at line 119 of file TGLUtil.h.

◆ Y() [1/2]

Double_t & TGLVertex3::Y ( )
inlineinherited

Definition at line 122 of file TGLUtil.h.

◆ Y() [2/2]

Double_t TGLVertex3::Y ( ) const
inlineinherited

Definition at line 121 of file TGLUtil.h.

◆ Z() [1/2]

Double_t & TGLVertex3::Z ( )
inlineinherited

Definition at line 124 of file TGLUtil.h.

◆ Z() [2/2]

Double_t TGLVertex3::Z ( ) const
inlineinherited

Definition at line 123 of file TGLUtil.h.

Member Data Documentation

◆ fVals

Double_t TGLVertex3::fVals[3]
protectedinherited

Definition at line 88 of file TGLUtil.h.


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