class TGLParametricPlot: public TGLPlotPainter


 A parametric surface is a surface defined by a parametric equation, involving
 two parameters (u, v):

 S(u, v) = (x(u, v), y(u, v), z(u, v)).
 For example, "limpet torus" surface can be defined as:
    x = cos(u) / (sqrt(2) + sin(v))
    y = sin(u) / (sqrt(2) + sin(v))
    z = 1 / (sqrt(2) + cos(v)),
 where -pi <= u <= pi, -pi <= v <= pi.


 TGLParametricEquation * eq =
    new TGLParametricEquation("Limpet_torus", "cos(u) / (sqrt(2.) + sin(v))",
                              "sin(u) / (sqrt(2.) + sin(v))",
                              "1 / (sqrt(2) + cos(v))");

 $ROOTSYS/tutorials/gl/glparametric.C contains more examples.

 Parametric equations can be specified:
    1. by string expressions, as with TF2, but with 'u' instead of 'x' and
       'v' instead of 'y'.
    2. by function - see ParametricEquation_t declaration.

Function Members (Methods)

public:
TGLParametricPlot(TGLParametricEquation* equation, TGLOrthoCamera* camera, TGLPaintDevice* dev = 0)
~TGLParametricPlot()
virtual voidAddOption(const TString& option)
static TClass*Class()
Bool_tTGLPlotPainter::CutAxisSelected() const
virtual char*GetPlotInfo(Int_t px, Int_t py)
virtual Bool_tInitGeometry()
voidTGLPlotPainter::InvalidateSelection()
virtual TClass*IsA() const
virtual voidTGLPlotPainter::Paint()
virtual voidPan(Int_t px, Int_t py)
virtual Bool_tTGLPlotPainter::PlotSelected(Int_t px, Int_t py)
virtual voidProcessEvent(Int_t event, Int_t px, Int_t py)
const TGLPlotBox&TGLPlotPainter::RefBackBox() const
virtual voidTGLPlotPainter::SetFrameColor(const TColor* frameColor)
voidTGLPlotPainter::SetGLDevice(TGLPaintDevice* dev)
voidTGLPlotPainter::SetPadColor(const TColor* color)
virtual voidShowMembers(TMemberInspector& insp, char* parent)
virtual voidStartPan(Int_t px, Int_t py)
virtual voidStreamer(TBuffer& b)
voidStreamerNVirtual(TBuffer& b)
protected:
virtual voidTGLPlotPainter::ClearBuffers() const
virtual voidTGLPlotPainter::DrawPaletteAxis() const
voidTGLPlotPainter::DrawSections() const
const TColor*TGLPlotPainter::GetPadColor() const
Bool_tTGLPlotPainter::MakeGLContextCurrent() const
voidTGLPlotPainter::MoveSection(Int_t px, Int_t py)
voidTGLPlotPainter::PrintPlot() const
private:
TGLParametricPlot(const TGLParametricPlot&)
virtual voidDrawPlot() const
virtual voidDrawSectionXOY() const
virtual voidDrawSectionXOZ() const
virtual voidDrawSectionYOZ() const
voidInitColors()
virtual voidInitGL() const
TGLParametricPlot&operator=(const TGLParametricPlot&)
voidSetSurfaceColor() const

Data Members

public:
enum EMeshSize { kLow
kHigh
};
enum TGLPlotPainter::ESelectionBase { kHighColorSelectionBase
kTrueColorSelectionBase
};
enum TGLPlotPainter::ECutAxisID { kXAxis
kYAxis
kZAxis
};
protected:
TGLPlotBoxTGLPlotPainter::fBackBox
TGLBoxCutTGLPlotPainter::fBoxCut
TGLOrthoCamera*TGLPlotPainter::fCamera
TGLPlotCoordinates*TGLPlotPainter::fCoord
Bool_tTGLPlotPainter::fDrawPalette
Bool_tTGLPlotPainter::fHighColor
TH1*TGLPlotPainter::fHist
TPointTGLPlotPainter::fMousePosition
Double_tTGLPlotPainter::fPadPhi
Double_tTGLPlotPainter::fPadTheta
Int_tTGLPlotPainter::fSelectedPart
TGLSelectionBufferTGLPlotPainter::fSelection
TGLPlotPainter::ESelectionBaseTGLPlotPainter::fSelectionBase
Bool_tTGLPlotPainter::fSelectionPass
Bool_tTGLPlotPainter::fUpdateSelection
TAxis*TGLPlotPainter::fXAxis
Double_tTGLPlotPainter::fXOYSectionPos
Double_tTGLPlotPainter::fXOZSectionPos
TAxis*TGLPlotPainter::fYAxis
Double_tTGLPlotPainter::fYOZSectionPos
TAxis*TGLPlotPainter::fZAxis
vector<Double_t>TGLPlotPainter::fZLevels
private:
Int_tfColorScheme
TGLParametricEquation*fEquation
TGL2DArray<TGLParametricPlot::Vertex_t>fMesh
Int_tfMeshSize
Bool_tfShowMesh

Class Charts

Inheritance Inherited Members Includes Libraries
Class Charts

Function documentation

TGLParametricPlot(TGLParametricEquation* equation, TGLOrthoCamera* camera, TGLPaintDevice* dev = 0)
Constructor.
Bool_t InitGeometry()
Build mesh. The surface is 'immutable':
the only reason to rebuild it - the change in size or
if one of equations contain reference to TF2 function, whose
parameters were changed.
void StartPan(Int_t px, Int_t py)
User clicks right mouse button (in a pad).
void Pan(Int_t px, Int_t py)
User's moving mouse cursor, with middle mouse button pressed (for pad).
Calculate 3d shift related to 2d mouse movement.
char * GetPlotInfo(Int_t px, Int_t py)
No object info yet.
void AddOption(const TString& option)
No additional options for parametric surfaces.
void ProcessEvent(Int_t event, Int_t px, Int_t py)
Change color/mesh size or switch on/off mesh/box cut.
Left double click - remove box cut.
void InitGL()
Initialize gl state.
void DrawPlot()
Draw parametric surface.
void InitColors()
Calculate colors for vertices,
using one of 20 color themes.
-1 simple 'metal' surface.
void DrawSectionXOZ()
No such sections.
void DrawSectionYOZ()
No such sections.
void DrawSectionXOY()
No such sections.
void SetSurfaceColor()
Set material properties.
TGLParametricPlot(TGLParametricEquation* equation, TGLOrthoCamera* camera, TGLPaintDevice* dev = 0)

Author: Timur Pocheptsov 26/01/2007
Last change: root/gl:$Id: TGLParametric.h 20882 2007-11-19 11:31:26Z rdm $
Last generated: 2008-06-25 08:41
Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *

This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.