library: libRGL #include "TGLOrthoCamera.h" |
TGLOrthoCamera
class description - header file - source file - inheritance tree (.pdf)
private:
void Init()
public:
TGLOrthoCamera(TGLOrthoCamera::EType type)
virtual ~TGLOrthoCamera()
virtual void Apply(const TGLBoundingBox& sceneBox, const TGLRect* pickRect = 0) const
static TClass* Class()
void Configure(Double_t left, Double_t right, Double_t top, Double_t bottom)
virtual Bool_t Dolly(Int_t delta, Bool_t mod1, Bool_t mod2)
virtual TClass* IsA() const
virtual void Reset()
virtual Bool_t Rotate(Int_t xDelta, Int_t yDelta)
virtual void Setup(const TGLBoundingBox& box)
virtual void ShowMembers(TMemberInspector& insp, char* parent)
virtual void Streamer(TBuffer& b)
void StreamerNVirtual(TBuffer& b)
virtual Bool_t Truck(Int_t x, Int_t y, Int_t xDelta, Int_t yDelta)
virtual Bool_t Zoom(Int_t delta, Bool_t mod1, Bool_t mod2)
private:
TGLOrthoCamera::EType fType ! type (EType) - one of kXOY, kXOZ, kZOY
Double_t fZoomMin ! minimum zoom factor
Double_t fZoomDefault ! default zoom factor
Double_t fZoomMax ! maximum zoom factor
TGLBoundingBox fVolume !
Double_t fZoom ! current zoom
TGLVector3 fTruck ! current truck vector
TGLMatrix fMatrix ! orthographic orientation matrix
static UInt_t fgZoomDeltaSens
public:
static const TGLOrthoCamera::EType kXOY
static const TGLOrthoCamera::EType kXOZ
static const TGLOrthoCamera::EType kZOY
TGLOrthoCamera
Orthographic projection camera. Currently limited to three types
defined at construction time - kXOY, kXOZ, kZOY - where this refers
to the viewport plane axis - e.g. kXOY has X axis horizontal, Y
vertical - i.e. looking down Z axis with Y vertical.
The plane types restriction could easily be removed to supported
arbitary ortho projections along any axis/orientation with free
rotations about them.
TGLOrthoCamera(EType type)
Construct orthographic camera with 'type' defining fixed view direction
& orientation (in world frame):
kXOY : X Horz. / Y Vert (looking towards +Z, Y up)
kXOZ : X Horz. / Z Vert (looking towards +Y, Z up)
kZOY : Z Horz. / Y Vert (looking towards +X, Y up)
void Setup(const TGLBoundingBox & box)
Setup camera limits suitible to view the world volume defined by 'box'
and call Reset() to initialise camera.
void Reset()
Reset the camera to defaults - trucking, zooming to reframe the world volume
established in Setup(). Note: limits defined in Setup() are not adjusted.
Bool_t Dolly(Int_t delta, Bool_t mod1, Bool_t mod2)
Dolly the camera - 'move camera along eye line, retaining lens focal length'.
Arguments are:
'delta' - mouse viewport delta (pixels) - +ive dolly in, -ive dolly out
'mod1' / 'mod2' - sensitivity modifiers - see TGLCamera::AdjustAndClampVal()
For an orthographic camera dollying and zooming are identical and both equate
logically to a rescaling of the viewport limits - without center shift.
There is no perspective foreshortening or lens 'focal length'.
Returns kTRUE is redraw required (camera change), kFALSE otherwise.
Bool_t Truck(Int_t x, Int_t y, Int_t xDelta, Int_t yDelta)
Truck the camera - 'move camera parallel to film plane'. The film
plane is defined by the EyePoint() / EyeDirection() pair. Define motion
using center point (x/y) and delta (xDelta/yDelta) - the mouse motion.
Returns kTRUE is redraw required (camera change), kFALSE otherwise.
Note: Trucking is often mistakenly refered to as 'pan' or 'panning'.
Panning is swivelling the camera on it's own axis - the eye point.
Author: Richard Maunder 25/05/2005
Last update: root/gl:$Name: $:$Id: TGLOrthoCamera.cxx,v 1.13 2006/01/26 11:59:41 brun Exp $
Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
ROOT page - Class index - Class Hierarchy - Top of the page
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.