71 glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
72 glDisable(GL_CULL_FACE);
107 glEnable(GL_CULL_FACE);
131 TGLVector3 constrainedShift = widgetAxis *
Dot(shift, widgetAxis);
virtual void Draw(const TGLCamera &camera) const
Draw translation manipulator - tubes with arrow heads, in local axes of attached shape, in red(X), green(Y) and blue(Z), with white center sphere.
Abstract base class for viewer manipulators, which allow direct in viewer manipulation of a (TGlPhysi...
const UChar_t * ColorFor(UInt_t widget) const
Returns color to be used for given widget.
Abstract base camera class - concrete classes for orthographic and perspective cameras derive from it...
void Translate(const TGLVector3 &vect)
static void DrawLine(const TGLLine3 &line, ELineHeadShape head, Double_t size, const UChar_t rgba[4])
Draw thick line (tube) defined by 'line', with head at end shape 'head' - box/arrow/none, (head) size 'size', color 'rgba'.
const TGLBoundingBox & BoundingBox() const
TGLVector3 ViewportDeltaToWorld(const TGLVertex3 &worldRef, Double_t viewportXDelta, Double_t viewportYDelta, TGLMatrix *modviewMat=0) const
Apply a 2D viewport delta (shift) to the projection of worldRef onto viewport, returning the resultan...
TGLVertex3 Center() const
static const UChar_t fgGrey[4]
virtual Bool_t HandleMotion(const Event_t &event, const TGLCamera &camera)
Handle mouse motion over manipulator - if active (selected widget) translate physical along selected ...
UInt_t fSelectedWidget
manipulated shape
void box(Int_t pat, Double_t x1, Double_t y1, Double_t x2, Double_t y2)
virtual ~TGLTransManip()
Destroy the translation manipulator.
Concrete physical shape - a GL drawable.
static void DrawSphere(const TGLVertex3 &position, Double_t radius, const UChar_t rgba[4])
Draw sphere, centered on vertex 'position', with radius 'radius', color 'rgba'.
ClassImp(TGLTransManip) TGLTransManip
Construct translation manipulator not bound to any physical shape.
3 component (x/y/z) vector class.
TPoint fLastMouse
first (start) mouse position (in WINDOW coords)
void CalcDrawScale(const TGLBoundingBox &box, const TGLCamera &camera, Double_t &base, TGLVector3 axis[3]) const
Calculates base and axis scale factor (in world units) for drawing manipulators with reasonable size ...
Bool_t fActive
active width (axis) component
static const UChar_t fgWhite[4]
TGLPhysicalShape * fShape
Double_t Dot(const TGLVector3 &v1, const TGLVector3 &v2)
const TGLVector3 & Axis(UInt_t i, Bool_t normalised=kTRUE) const
Concrete class describing an orientated (free) or axis aligned box of 8 vertices. ...
Translation manipulator - attaches to physical shape and draws local axes widgets with arrow heads...