Logo ROOT   6.16/01
Reference Guide
TTablePadView3D.cxx
Go to the documentation of this file.
1// @(#)root/table:$Id$
2// Author: Valery Fine(fine@vxcern.cern.ch) 30/05/97
3
4/*************************************************************************
5 * Copyright (C) 1995-2000, 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//////////////////////////////////////////////////////////////////////////
13// //
14// TTablePadView3D //
15// //
16// TTablePadView3D is a generic 3D viewer. //
17// For a concrete viewer see TGLViewer. //
18// //
19//////////////////////////////////////////////////////////////////////////
20
21#include "TTablePadView3D.h"
22#include "TVirtualPad.h"
23
24
25// ClassImp(TTablePadView3D); //3-D View of TPad
26
27////////////////////////////////////////////////////////////////////////////////
28/// Delete 3D viewer.
29
31{
32 if (fParent) {
33 /// fParent->ResetView3D();
34 SetPad();
35 }
36}
37
38
39// Getter's / Setter's methods for the data-members
40
41////////////////////////////////////////////////////////////////////////////////
42///get view range
43
45{
46 memcpy(min,fViewBoxMin,sizeof(fViewBoxMin));
47 memcpy(max,fViewBoxMax,sizeof(fViewBoxMax));
48}
49////////////////////////////////////////////////////////////////////////////////
50///set view range
51
53{
54 memcpy(fViewBoxMin,min,sizeof(fViewBoxMin));
55 memcpy(fViewBoxMax,max,sizeof(fViewBoxMax));
56}
57
58////////////////////////////////////////////////////////////////////////////////
59///get shift parameters
60
61void TTablePadView3D::GetShift(Double_t main_shift[3], Double_t extra_shift[3]) const
62{
63 memcpy(main_shift,fTranslate,sizeof(fTranslate));
64 memcpy(extra_shift,fExtraTranslate,sizeof(fExtraTranslate));
65}
66
67////////////////////////////////////////////////////////////////////////////////
68///set shift parameters
69
70void TTablePadView3D::SetShift(Double_t main_shift[3], Double_t extra_shift[3])
71{
72 memcpy(fTranslate,main_shift,sizeof(fTranslate));
73 memcpy(fExtraTranslate,extra_shift,sizeof(fExtraTranslate));
74}
75
76////////////////////////////////////////////////////////////////////////////////
77///get view angles
78
79void TTablePadView3D::GetAngles(Double_t main_angles[3], Double_t extra_angles[3]) const
80{
81 memcpy(main_angles,fAngles,sizeof(fAngles));
82 memcpy(extra_angles,fExtraAngles,sizeof(fExtraAngles));
83}
84
85////////////////////////////////////////////////////////////////////////////////
86///set view angles
87
88void TTablePadView3D::SetAngles(Double_t main_angles[3], Double_t extra_angles[3])
89{
90 memcpy(fAngles,main_angles,sizeof(fAngles));
91 memcpy(fExtraAngles,extra_angles,sizeof(fExtraAngles));
92}
93
94////////////////////////////////////////////////////////////////////////////////
95///get view angles factors
96
98{
99 memcpy(factors,fAnglFactor,sizeof(fAnglFactor));
100}
101////////////////////////////////////////////////////////////////////////////////
102///set view angles factors
103
105{
106 memcpy(fAnglFactor,factors,sizeof(fAnglFactor));
107}
108
109////////////////////////////////////////////////////////////////////////////////
110///set view scale
111
113{
114 fScale = scale;
115}
double Double_t
Definition: RtypesCore.h:55
float Float_t
Definition: RtypesCore.h:53
virtual void GetAnglesFactors(Double_t factors[3]) const
get view angles factors
virtual void SetScale(Float_t scale)
set view scale
Double_t fViewBoxMin[3]
Double_t fAngles[3]
virtual void SetShift(Double_t main_shift[3], Double_t extra_shift[3])
set shift parameters
Double_t fTranslate[3]
virtual void SetRange(Double_t min[3], Double_t max[3])
set view range
Double_t fAnglFactor[3]
virtual ~TTablePadView3D()
Delete 3D viewer.
Double_t fExtraTranslate[3]
TVirtualPad * fParent
virtual void SetAngles(Double_t main_angles[3], Double_t extra_angles[3])
set view angles
virtual void GetAngles(Double_t main_angles[3], Double_t extra_angles[3]) const
get view angles
virtual void GetRange(Double_t min[3], Double_t max[3]) const
get view range
virtual void SetAnglesFactors(Double_t factors[3])
set view angles factors
Double_t fExtraAngles[3]
virtual void GetShift(Double_t main_shift[3], Double_t extra_shift[3]) const
get shift parameters
Double_t fViewBoxMax[3]
void SetPad(TVirtualPad *pad=0)