56DIRECT SCENE INTERACTIONS\n\n\
58 \tw --- wireframe mode\n\
59 \te --- switch between dark / light color-set\n\
60 \tr --- filled polygons mode\n\
61 \tt --- outline mode\n\
64 \ta --- switch on/off arc-ball camera rotation control\n\
65 \tArrow Keys --- PAN (TRUCK) across scene\n\
66 \tHome --- reset current camera\n\
67 \tCtrl-Home --- switch external/automatic camera center\n\
69 LEFT mouse button -- ROTATE (ORBIT) the scene by holding the mouse button and moving\n\
70 the mouse (perspective camera, needs to be enabled in menu for orthographic cameras).\n\
71 By default, the scene will be rotated about its center. To select arbitrary center\n\
72 bring up the viewer-editor (e.g., shift-click into empty background) and use\n\
73 'Camera center' controls in the 'Guides' tab.\n\
75 MIDDLE mouse button or arrow keys -- PAN (TRUCK) the camera.\n\
77 RIGHT mouse button action depends on camera type:\n\
78 orthographic -- zoom,\n\
79 perspective -- move camera forwards / backwards\n\
81 By pressing Ctrl and Shift keys the mouse precision can be changed:\n\
82 Shift -- 10 times less precise\n\
83 Ctrl -- 10 times more precise\n\
84 Ctrl Shift -- 100 times more precise\n\
86 Mouse wheel action depends on camera type:\n\
87 orthographic -- zoom,\n\
88 perspective -- change field-of-view (focal length)\n\
90 To invert direction of mouse and key actions from scene-centric\n\
91 to viewer-centric, set in your .rootrc file:\n\
92 OpenGL.EventHandler.ViewerCentricControls: 1\n\
94 Double click will show GUI editor of the viewer (if assigned).\n\
96 RESET the camera via the button in viewer-editor or Home key.\n\
98 SELECT a shape with Shift+Left mouse button click.\n\
100 SELECT the viewer with Shift+Left mouse button click on a free space.\n\
102 MOVE a selected shape using Shift+Mid mouse drag.\n\
104 Invoke the CONTEXT menu with Shift+Right mouse click.\n\n"
105 "Secondary selection and direct render object interaction is initiated\n\
106 by Alt+Left mouse click (Mod1, actually). Only few classes support this option.\n\
107 When 'Alt' is taken by window manager, try Alt-Ctrl-Left.\n\
111 The \"Camera\" menu is used to select the different projections from \n\
112 the 3D world onto the 2D viewport. There are three perspective cameras:\n\
114 \tPerspective (Floor XOZ)\n\
115 \tPerspective (Floor YOZ)\n\
116 \tPerspective (Floor XOY)\n\
118 In each case the floor plane (defined by two axes) is kept level.\n\
120 There are also four orthographic cameras:\n\
122 \tOrthographic (XOY)\n\
123 \tOrthographic (XOZ)\n\
124 \tOrthographic (ZOY)\n\
125 \tOrthographic (ZOX)\n\
127 In each case the first axis is placed horizontal, the second vertical e.g.\n\
128 XOY means X horizontal, Y vertical.\n\n";
131SHAPES COLOR AND MATERIAL\n\
133 The selected shape's color can be modified in the Shapes-Color tabs.\n\
134 Shape's color is specified by the percentage of red, green, blue light\n\
135 it reflects. A surface can reflect DIFFUSE, AMBIENT and SPECULAR light.\n\
136 A surface can also emit light. The EMISSIVE parameter allows to define it.\n\
137 The surface SHININESS can also be modified.\n\
141 The selected shape's location and geometry can be modified in the Shapes-Geom\n\
142 tabs by entering desired values in respective number entry controls.\n\
146 In the Scene-Clipping tabs select a 'Clip Type': None, Plane, Box\n\
148 For 'Plane' and 'Box' the lower pane shows the relevant parameters:\n\
150\tPlane: Equation coefficients of form aX + bY + cZ + d = 0\n\
151\tBox: Center X/Y/Z and Length X/Y/Z\n\n"
152 "For Box checking the 'Show / Edit' checkbox shows the clip box (in light blue)\n\
153 in viewer. It also attaches the current manipulator to the box - enabling\n\
154 direct editing in viewer.\n\
158 A widget attached to the selected object - allowing direct manipulation\n\
159 of the object with respect to its local axes.\n\
161 There are three modes, toggled with keys while manipulator is active, that is,\n\
162 mouse pointer is above it (switches color to yellow):\n\
163 \tMode\t\tWidget Component Style\t\tKey\n\
164 \t----\t\t----------------------\t\t---\n\
165 \tTranslation\tLocal axes with arrows\t\tv\n\
166 \tScale\t\tLocal axes with boxes\t\tx\n\
167 \tRotate\t\tLocal axes rings\t\tc\n\
169 Each widget has three axis components - red (X), green (Y) and blue (Z).\n\
170 The component turns yellow, indicating an active state, when the mouse is moved\n\
171 over it. Left click and drag on the active component to adjust the objects\n\
172 translation, scale or rotation.\n\
173 Some objects do not support all manipulations (e.g. clipping planes cannot be \n\
174 scaled). If a manipulation is not permitted the component it drawn in grey and \n\
175 cannot be selected/dragged.\n";
198 "Animated GIF",
"*.gif+",
231 fFrame->SetWindowName(
"ROOT's GL viewer");
232 fFrame->SetClassHints(
"GLViewer",
"GLViewer");
337 Error(
"CreateGLWidget",
"Widget already exists.");
360 Error(
"DestroyGLWidget",
"Widget does not exist.");
433 fMenuBut->SetBackgroundColor(0x80A0C0);
543 fMenuBar->Connect(
"ProcessedEvent(Event_t*)",
"TGLSAViewer",
this,
"HandleMenuBarHiding(Event_t*)");
544 fMenuBut->Connect(
"ProcessedEvent(Event_t*)",
"TGLSAViewer",
this,
"HandleMenuBarHiding(Event_t*)");
551 fMenuHidingTimer->Connect(
"Timeout()",
"TGLSAViewer",
this,
"MenuHidingTimeout()");
566 fMenuBar->Disconnect(
"ProcessedEvent(Event_t*)",
this,
"HandleMenuBarHiding(Event_t*)");
567 fMenuBut->Disconnect(
"ProcessedEvent(Event_t*)",
this,
"HandleMenuBarHiding(Event_t*)");
597 (ev->
fX < 0 || ev->
fX >= (
Int_t)
f->GetWidth() ||
598 ev->
fY < 0 || ev->
fY >= (
Int_t)
f->GetHeight()))
600 if (
fMenuBar->GetCurrent() ==
nullptr)
603 fMenuBar->GetCurrent()->Connect(
"ProcessedEvent(Event_t*)",
"TGLSAViewer",
this,
"HandleMenuBarHiding(Event_t*)");
612 f->Disconnect(
"ProcessedEvent(Event_t*)",
this);
769 while (*fin !=
nullptr)
const Mask_t kFocusChangeMask
const Mask_t kExposureMask
const Mask_t kKeyPressMask
const Mask_t kPointerMotionMask
const Mask_t kLeaveWindowMask
const Mask_t kStructureNotifyMask
const Mask_t kEnterWindowMask
R__EXTERN const char gHelpAbout[]
R__EXTERN TApplication * gApplication
const char * gGLSaveAsTypes[]
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t Atom_t Atom_t Time_t format
R__EXTERN void * gTQSender
R__EXTERN TSystem * gSystem
The base class for composite widgets (menu bars, list boxes, etc.).
virtual void AddFrame(TGFrame *f, TGLayoutHints *l=nullptr)
Add frame to the composite frame using the specified layout hints.
This class creates a file selection dialog.
char * fFilename
selected file name
Int_t fFileTypeIdx
selected file type, index in fFileTypes
const char ** fFileTypes
file types used to filter selectable files
char * fIniDir
on input: initial directory, on output: new directory
Bool_t fOverwrite
if true overwrite the file with existing name on save
void SetIniDir(const char *inidir)
Set directory name.
A subclasses of TGWindow, and is used as base class for some simple widgets (buttons,...
TObject * GetExternal() const
Concrete physical shape - a GL drawable.
const TGLLogicalShape * GetLogical() const
Standalone GL Viewer GUI main frame.
The top level standalone GL-viewer - created via plugin manager.
void Show()
Show the viewer.
static void SetMenuHidingTimeout(Long_t timeout)
Set global timeout for menu-hiding in mili-seconds.
void ToggleOrthoDolly()
Toggle state of the 'Ortho allow dolly' menu entry.
static const Int_t fgInitH
Bool_t ProcessFrameMessage(Long_t msg, Long_t parm1, Long_t)
Process GUI message capture by the main GUI frame (TGLSAFrame).
void EnableMenuBarHiding()
Enable hiding of menu bar.
TGLSAViewer(const TGLSAViewer &)
TGCompositeFrame * fRightVerticalFrame
void ResetMenuHidingTimer(Bool_t show_menu)
Reset the timer for menu-bar hiding.
void CreateMenus()
File/Camera/Help menus.
void ToggleOrthoRotate()
Toggle state of the 'Ortho allow rotate' menu entry.
void CreateFrames()
Internal frames creation.
void SelectionChanged() override
Update GUI components for embedded viewer selection change.
void CreateGLWidget() override
Create a GLwidget, it is an error if it is already created.
void DeleteMenuBar()
Delete the menu bar.
void HandleMenuBarHiding(Event_t *ev)
Maybe switch menu-bar / menu-button.
static const char * fgHelpText2
TTimer * fMenuHidingTimer
void MenuHidingTimeout()
Action for menu-hiding timeout.
static Long_t fgMenuHidingTimeout
void DestroyGLWidget() override
Destroy the GLwidget, it is an error if it does not exist.
void Close()
Close the viewer - destructed.
void DisableMenuBarHiding()
Disable hiding of menu bar.
static const Int_t fgInitX
static const Int_t fgInitW
TGPopupMenu * fFileSaveMenu
void ToggleEditObject()
Toggle state of the 'Edit Object' menu entry.
TGCompositeFrame * GetFrame() const
Return the main-frame.
TGPopupMenu * fCameraMenu
~TGLSAViewer() override
Destroy standalone viewer object.
TGCompositeFrame * fLeftVerticalFrame
void DisableCloseMenuEntries()
Deactivate menu entries for closing the GL window and exiting ROOT.
static const char * fgHelpText1
static const Int_t fgInitY
Bool_t fMenuHidingShowMenu
TGLOrthoCamera fOrthoXOYCamera
TGLOrthoCamera fOrthoXnOZCamera
TGEventHandler * fEventHandler
select record from last overlay select
TGLOrthoCamera fOrthoZnOYCamera
void RequestDraw(Short_t LOD=TGLRnrCtx::kLODMed)
Post request for redraw of viewer at level of detail 'LOD' Request is directed via cross thread gVirt...
TGLOrthoCamera fOrthoZOYCamera
TGLPShapeObj * fPShapeWrap
GED editor.
void SetCurrentCamera(ECameraType camera)
Set current active camera - 'cameraType' one of: kCameraPerspX, kCameraPerspY, kCameraPerspZ,...
Bool_t SavePicture()
Save current image using the default file name which can be set via SetPictureFileName() and defaults...
TGLOrthoCamera fOrthoXOZCamera
TGedEditor * fGedEditor
event handler
friend class TGLEventHandler
const TGLPhysicalShape * GetSelected() const
Return selected physical shape.
TGLOrthoCamera fOrthoXnOYCamera
TGLViewer(const TGLViewer &)=delete
This class describes layout hints used by the layout classes.
void SetFrame(TGFrame *frame, Bool_t left) override
Set frame to be resized.
A composite frame that layout their children in vertical way.
ROOT GUI Window base class.
virtual void Error(const char *method, const char *msgfmt,...) const
Issue error message.
TObject()
TObject constructor.
static const TString & GetBinDir()
Get the binary directory in the installation. Static utility function.
A TRootHelpDialog is used to display help text (or any text in a dialog window).
void Popup()
Show help dialog.
void AddText(const char *helpText)
Add help text from helpText buffer to already existing text in TGTextView.
Bool_t EndsWith(const char *pat, ECaseCompare cmp=kExact) const
Return true if string ends with the specified string.
Ssiz_t Index(const char *pat, Ssiz_t i=0, ECaseCompare cmp=kExact) const
Handles synchronous and a-synchronous timer events.
static void SingleShot(Int_t milliSec, const char *receiver_class, void *receiver, const char *method)
This static function calls a slot after a given time interval.
TVirtualPad is an abstract base class for the Pad and Canvas classes.
EGEventType fType
of event (see EGEventType)
Int_t fY
pointer x, y coordinates in event window