Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
camera_restore.C
Go to the documentation of this file.
1/// \file
2/// \ingroup tutorial_eve
3///
4/// \macro_code
5///
6/// \author Matevz Tadel
7
8void camera_restore(const char *fname, int mode = 0)
9{
12}
13
14void writeCurrentCamera(const char *fname)
15{
17 TFile *f = TFile::Open(fname, "RECREATE");
18 c.Write();
19 f->Close();
20}
21
22void readCurrentCamera(const char *fname)
23{
25 TFile *f = TFile::Open(fname, "READ");
26 if (!f)
27 return;
28
29 if (f->GetKey(c.ClassName())) {
30 f->GetKey(c.ClassName())->Read(&c);
31 c.IncTimeStamp();
33 }
34}
#define f(i)
Definition RSha256.hxx:104
#define c(i)
Definition RSha256.hxx:101
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
R__EXTERN TEveManager * gEve
Option_t Option_t TPoint TPoint const char mode
TGLViewer * GetDefaultGLViewer() const
Get TGLViewer of the default TEveViewer.
static TEveManager * Create(Bool_t map_window=kTRUE, Option_t *opt="FIV")
If global TEveManager* gEve is not set initialize it.
A ROOT file is an on-disk file, usually with extension .root, that stores objects in a file-system-li...
Definition TFile.h:131
static TFile * Open(const char *name, Option_t *option="", const char *ftitle="", Int_t compress=ROOT::RCompressionSetting::EDefaults::kUseCompiledDefault, Int_t netopt=0)
Create / open a file.
Definition TFile.cxx:4131
Abstract base camera class - concrete classes for orthographic and perspective cameras derive from it...
Definition TGLCamera.h:44
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...
TGLCamera & CurrentCamera() const
Definition TGLViewer.h:268