Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
TGLScaleManip.h
Go to the documentation of this file.
1// @(#)root/gl:$Id$
2// Author: Richard Maunder 16/09/2005
3
4/*************************************************************************
5 * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. *
6 * All rights reserved. *
7 * *
8 * For the licensing terms see $ROOTSYS/LICENSE. *
9 * For the list of contributors see $ROOTSYS/README/CREDITS. *
10 *************************************************************************/
11
12#ifndef ROOT_TGLScaleManip
13#define ROOT_TGLScaleManip
14
15#include "TGLManip.h"
16
17
18//////////////////////////////////////////////////////////////////////////
19// //
20// TGLScaleManip //
21// //
22// Scale manipulator - attaches to physical shape and draws local axes //
23// widgets with box heads. User can mouse over (turns yellow) and L //
24// click/drag to scale along this axis. //
25// Widgets use standard 3D package axes colours: X red, Y green, Z blue.//
26//////////////////////////////////////////////////////////////////////////
27
28class TGLScaleManip : public TGLManip
29{
30private:
31 TGLVector3 fStartScale; //! initial scaling factors
32
33 void LimitScale(Double_t & factor) const;
34
35public:
38 ~TGLScaleManip() override;
39
40 void Draw(const TGLCamera & camera) const override;
41 Bool_t HandleButton(const Event_t & event, const TGLCamera & camera) override;
42 Bool_t HandleMotion(const Event_t & event, const TGLCamera & camera) override;
43
44 ClassDefOverride(TGLScaleManip,0) // GL scaling manipulator widget
45};
46
47#endif
#define ClassDefOverride(name, id)
Definition Rtypes.h:346
Abstract base camera class - concrete classes for orthographic and perspective cameras derive from it...
Definition TGLCamera.h:44
Abstract base class for viewer manipulators, which allow direct in viewer manipulation of a (TGlPhysi...
Definition TGLManip.h:29
Concrete physical shape - a GL drawable.
Scale manipulator - attaches to physical shape and draws local axes widgets with box heads.
TGLVector3 fStartScale
~TGLScaleManip() override
Destroy the scale manipulator.
void LimitScale(Double_t &factor) const
initial scaling factors
Bool_t HandleMotion(const Event_t &event, const TGLCamera &camera) override
Handle mouse motion over manipulator - if active (selected widget) scale physical along selected widg...
TGLScaleManip()
Construct scale manipulator not bound to any physical shape.
Bool_t HandleButton(const Event_t &event, const TGLCamera &camera) override
Handle mouse button event over manipulator - returns kTRUE if redraw required kFALSE otherwise.
3 component (x/y/z) vector class.
Definition TGLUtil.h:248
Event structure.
Definition GuiTypes.h:174
th1 Draw()