library: libRGL #include "TGLLegoPainter.h" |
Inheritance Chart: | |||||||||||||||
|
private:
TGLLegoPainter(const TGLLegoPainter&) Bool_t ClampZ(Double_t& zVal) const void ClearBuffers() TGLLegoPainter::Selection_t ColorToObject(const UChar_t* color) void Disable1DTexture() void DrawBackPlane(Int_t plane) const void DrawFrame() void DrawGrid(Int_t plane) const void DrawLegoCartesian() void DrawLegoCylindrical() void DrawLegoPolar() void DrawLegoSpherical() void DrawPlot() void DrawProfiles() void DrawProfileX() void DrawProfileY() void Enable1DTexture() void EncodeToColor(Int_t i, Int_t j) const Bool_t InitGeometryCartesian() Bool_t InitGeometryCylindrical() Bool_t InitGeometryPolar() Bool_t InitGeometrySpherical() void InitGL() Bool_t MakeGLContextCurrent() const void MoveDynamicProfile(Int_t px, Int_t py) TGLLegoPainter& operator=(const TGLLegoPainter&) void SetLegoColor() void SetSelectionMode() public:
TGLLegoPainter(TH1* hist, TGLAxisPainter* axisPainter, Int_t ctx = -1, EGLCoordType type = kGLCartesian, Bool_t logX = kFALSE, Bool_t logY = kFALSE, Bool_t logZ = kFALSE) ~TGLLegoPainter() virtual void AddOption(const TString& stringOption) static TClass* Class() virtual char* GetObjectInfo(Int_t px, Int_t py) virtual Bool_t InitGeometry() virtual TClass* IsA() const virtual void Paint() virtual void Pan(Int_t px, Int_t py) virtual void ProcessEvent(Int_t event, Int_t px, Int_t py) virtual void Rotate(Int_t px, Int_t py) virtual TObject* Select(Int_t px, Int_t py) virtual void SetCoordType(EGLCoordType type) virtual void SetFrameColor(TColor* frameColor) virtual void SetGLContext(Int_t ctx) virtual void SetLogX(Bool_t logX) virtual void SetLogY(Bool_t logY) virtual void SetLogZ(Bool_t logZ) virtual void SetPadColor(TColor* padColor) virtual void ShowMembers(TMemberInspector& insp, char* parent) virtual void StartPan(Int_t px, Int_t py) virtual void StartRotation(Int_t px, Int_t py) virtual void StopPan() virtual void StopRotation() virtual void Streamer(TBuffer& b) void StreamerNVirtual(TBuffer& b) virtual void ZoomIn() virtual void ZoomOut()
private:
TH1* fHist Int_t fGLContext EGLCoordType fCoordType pair<int,int> fBinsX pair<int,int> fBinsY pair<double,double> fRangeX pair<double,double> fRangeY pair<double,double> fRangeZ Double_t fMinZ TGLLegoPainter::ELegoType fLegoType TGLSelectionBuffer fSelection Bool_t fSelectionPass Bool_t fUpdateSelection pair<int,int> fSelectedBin TGLLegoPainter::ESelectionType fSelectionMode Int_t fSelectedPlane TColor* fPadColor TColor* fFrameColor Double_t fXOZProfilePos Double_t fYOZProfilePos Bool_t fIsMoving vector<Range_t> fXEdges vector<Range_t> fYEdges vector<pair<double,double>,allocator<pair<double,double> > > fCosSinTableX vector<pair<double,double>,allocator<pair<double,double> > > fCosSinTableY TString fBinInfo TGLAxisPainter* fAxisPainter vector<Double_t> fZLevels UInt_t fTextureName vector<UChar_t> fTexture TGLQuadric fQuadric Bool_t fDrawErrors static const Float_t fRedEmission static const Float_t fOrangeEmission static const Float_t fGreenEmission static const Float_t fNullEmission public:
static const TGLLegoPainter::ELegoType kColorSimple static const TGLLegoPainter::ELegoType kColorLevel static const TGLLegoPainter::ELegoType kCylindricBars static const TGLLegoPainter::ESelectionType kSelectionSimple static const TGLLegoPainter::ESelectionType kSelectionFull
This function is used by pad to show info in a status bar. It can be: -bin number and content (selected bin is highlighted) -TH name (back box planes are selected) During rotation or shifting, this functions should return immediately.
Find bin ranges for X and Y axes, axes ranges for X, Y and Z. Function returns false, if logarithmic scale for some axis was requested, but we cannot find correct range.
Find bin ranges for X and Y axes. Find range for Z axis. X is mapped to the polar angle, Y to polar radius. Z is Z.
Find bin ranges for X and Y axes. Find range for Z axis. X is mapped to the azimuth, Y is height. Z is radius.
Find bin ranges for X and Y axes. Find range for Z axis. X is mapped to the theta, Y is phi, Z is radius.
User's moving mouse cursor, with right mouse button pressed (for pad). Calculate 3d shift related to 2d mouse movement.
In a simple mode, all lego (with it's frame) is white (in a black color buffer)
Draws lego in a cartesian system. Draw back box (possibly, with dynamic profiles).
Draws lego in a polar system. No back box, no profiles. Bars are drawn as trapezoids.
Number of bins + 5 must be less then 2^24 (5 == 3 back planes + 2 dynamic profiles). 2 ^ 24 == r g b in a glColor3ub (ub for unsigned char). Number of bits supposed == 8.
Draw back box for lego. This box is not written into OpenGL's depth buffer, to avoid some visual artifacts.
Grid at XOZ or YOZ back plane Under win32 glPushAttrib does not help with GL_LINE_STIPPLE enable bit