Definition at line 48 of file REveManager.hxx.
Classes | |
| class | ChangeGuard |
| struct | Conn |
| struct | Logger |
| class | MIR |
| class | RExceptionHandler |
| class | ServerState |
Public Member Functions | |
| REveManager () | |
| virtual | ~REveManager () |
| Destructor. | |
| void | AddElement (REveElement *element, REveElement *parent=nullptr) |
| Add an element. | |
| void | AddGlobalElement (REveElement *element, REveElement *parent=nullptr) |
| Add a global element, i.e. | |
| void | AddLocation (const std::string &name, const std::string &path) |
| Register new directory to THttpServer. | |
| void | AllowMultipleRemoteConnections (bool loopBack=true, bool useAuthKey=true) |
| Utility function to allow remote RWebWindow connections. | |
| bool | AnySceneChanged () const |
| Is there anything stamped and not yet streamed? | |
| void | AssignElementId (REveElement *element) |
| Assign a unique ElementId to given element. | |
| void | BeginChange () |
| void | BrowseElement (ElementId_t id) |
| Activate EVE browser (summary view) for specified element id. | |
| void | ClearAllSelections () |
| Clear all selection objects. | |
| void | ClearROOTClassSaved () |
| Work-around uber ugly hack used in SavePrimitive and co. | |
| bool | ClientConnectionsFree () const |
| void | ConnectEveViewer (REveViewer *) |
| void | DisableRedraw () |
| void | DisconnectEveViewer (REveViewer *) |
| void | DoRedraw3D () |
| Perform 3D redraw of scenes and viewers whose contents has changed. | |
| void | EnableRedraw () |
| void | EndChange () |
| Stop accepting changes and stream them. | |
| REveElement * | FindElementById (ElementId_t id) const |
| Lookup ElementId in element map and return corresponding REveElement*. | |
| REveElement * | FindVizDBEntry (const TString &tag) |
| Find a visualization-parameter database entry corresponding to tag. | |
| void | FullRedraw3D (Bool_t resetCameras=kFALSE, Bool_t dropLogicals=kFALSE) |
| Perform 3D redraw of all scenes and viewers. | |
| REveElement * | GetCameras () const |
| TGeoManager * | GetDefaultGeometry () |
| Get the default geometry. | |
| REveViewer * | GetDefaultViewer () const |
| Get the default viewer. | |
| REveScene * | GetEventScene () const |
| RExceptionHandler * | GetExcHandler () const |
| TGeoManager * | GetGeometry (const TString &filename) |
| Get geometry with given filename. | |
| TGeoManager * | GetGeometryByAlias (const TString &alias) |
| Get geometry with given alias. | |
| REveScene * | GetGlobalScene () const |
| REveSelection * | GetHighlight () const |
| bool | GetHttpPublic () |
| Bool_t | GetKeepEmptyCont () const |
| REveSceneList * | GetScenes () const |
| REveSelection * | GetSelection () const |
| void | GetServerStatus (REveServerStatus &) |
| REveViewerList * | GetViewers () const |
| Bool_t | GetVizDBReplace () const |
| Bool_t | GetVizDBUpdate () const |
| std::shared_ptr< ROOT::RWebWindow > | GetWebWindow () const |
| REveScene * | GetWorld () const |
| void | GrabImages (std::string_view event_id, std::string_view url="", int scale=1, const std::vector< std::string > &viewers={}) |
| Ask every connected client to grab its GL viewers and POST each image to an image collector. | |
| Bool_t | InsertVizDBEntry (const TString &tag, REveElement *model) |
| Insert a new visualization-parameter database entry with the default parameters for replace and update, as specified by members fVizDBReplace(default=kTRUE) and fVizDBUpdate(default=kTRUE). | |
| Bool_t | InsertVizDBEntry (const TString &tag, REveElement *model, Bool_t replace, Bool_t update) |
| Insert a new visualization-parameter database entry. | |
| bool | IsRCore () const |
| void | LoadVizDB (const TString &filename) |
| Load visualization-parameter database from file filename. | |
| void | LoadVizDB (const TString &filename, Bool_t replace, Bool_t update) |
| Load visualization-parameter database from file filename. | |
| void | PreDeleteElement (REveElement *element) |
| Called from REveElement prior to its destruction so the framework components (like object editor) can unreference it. | |
| void | Redraw3D (Bool_t resetCameras=kFALSE, Bool_t dropLogicals=kFALSE) |
| void | RegisterGeometryAlias (const TString &alias, const TString &filename) |
| Register 'name' as an alias for geometry file 'filename'. | |
| void | RegisterRedraw3D () |
| void | RemoveElement (REveElement *element, REveElement *parent) |
| Remove element from parent. | |
| void | SaveVizDB (const TString &filename) |
| Save visualization-parameter database to file filename. | |
| void | SceneSubscriberProcessingChanges (unsigned cinnId) |
| void | SceneSubscriberWaitingResponse (unsigned cinnId) |
| void | ScheduleMIR (const std::string &cmd, ElementId_t i, const std::string &ctype, unsigned connid) |
| void | Send (unsigned connid, const std::string &data) |
| void | SendBinary (unsigned connid, const void *data, std::size_t len) |
| void | SendToAllConnections (const std::string &data) |
| void | SetClientVersion (const std::string &version) |
| Set client version, used as prefix in scripts URL When changed, web browser will reload all related JS files while full URL will be different Default is empty value - no extra string in URL Version should be string like "1.2" or "ver1.subv2" and not contain any special symbols. | |
| void | SetDefaultHtmlPage (const std::string &path) |
| Set content of default window HTML page. | |
| void | SetHttpPublic (bool) |
| Restrict functionality for this server when open to public. | |
| void | SetKeepEmptyCont (Bool_t k) |
| void | SetVizDBReplace (Bool_t r) |
| void | SetVizDBUpdate (Bool_t u) |
| void | Show (const RWebDisplayArgs &args="") |
| Show eve manager in specified browser. | |
| REveScene * | SpawnNewScene (const char *name, const char *title="") |
| Create a new scene. | |
| REveViewer * | SpawnNewViewer (const char *name, const char *title="") |
| Create a new GL viewer. | |
Static Public Member Functions | |
| static REveManager * | Create () |
| If global REveManager* REX::gEve is not set initialize it. | |
| static void | ErrorHandler (Int_t level, Bool_t abort, const char *location, const char *msg) |
| static void | ExecuteInMainThread (std::function< void()> func) |
| static void | QuitRoot () |
| static void | Terminate () |
| Properly terminate global REveManager. | |
Public Attributes | |
| bool | fPendingSceneChanges {false} |
| Changes are stamped but not yet streamed, because the clients had not acknowledged the previous scene changes when EndChange() ran. | |
Protected Member Functions | |
| void | ExecuteMIR (std::shared_ptr< MIR > mir) |
| void | MIRExecThread () |
| void | SendMotionChanges () |
| Send transformation-only changes on the motion channel: the same websocket, outside the BeginChanges/EndChanges cycle, with no acknowledgement. | |
| void | SendSceneChanges () |
| void | StreamSceneChangesToJson () |
| void | StreamToNewConnection (unsigned connid) |
| Register new connection and stream the world and the mandatory scenes to it. | |
| void | WindowConnect (unsigned connid) |
| Process new connection from web window. | |
| void | WindowData (unsigned connid, const std::string &arg) |
| Process data from web window. | |
| void | WindowDisconnect (unsigned connid) |
| Process disconnect of web window. | |
Private Member Functions | |
| REveManager (const REveManager &)=delete | |
| REveManager & | operator= (const REveManager &)=delete |
#include <ROOT/REveManager.hxx>
|
privatedelete |
| REveManager::REveManager | ( | ) |
Definition at line 121 of file REveManager.cxx.
|
virtual |
Destructor.
Definition at line 235 of file REveManager.cxx.
| void REveManager::AddElement | ( | REveElement * | element, |
| REveElement * | parent = nullptr ) |
Add an element.
If parent is not specified it is added into current event (which is created if does not exist).
Definition at line 325 of file REveManager.cxx.
| void REveManager::AddGlobalElement | ( | REveElement * | element, |
| REveElement * | parent = nullptr ) |
Add a global element, i.e.
one that does not change on each event, like geometry or projection manager. If parent is not specified it is added to a global scene.
Definition at line 339 of file REveManager.cxx.
| void REveManager::AddLocation | ( | const std::string & | name, |
| const std::string & | path ) |
Register new directory to THttpServer.
Definition at line 730 of file REveManager.cxx.
| void REveManager::AllowMultipleRemoteConnections | ( | bool | loopBack = true, |
| bool | requireAuthKey = true ) |
Utility function to allow remote RWebWindow connections.
Disable loopback when use remote client. Authentification key has to be disabled in the case of multiple connections. The default arguments prevent remote connections for the security reasons.
Definition at line 701 of file REveManager.cxx.
| bool REveManager::AnySceneChanged | ( | ) | const |
Is there anything stamped and not yet streamed?
Definition at line 1344 of file REveManager.cxx.
| void REveManager::AssignElementId | ( | REveElement * | element | ) |
Assign a unique ElementId to given element.
Definition at line 368 of file REveManager.cxx.
| void REveManager::BeginChange | ( | ) |
Definition at line 1399 of file REveManager.cxx.
| void REveManager::BrowseElement | ( | ElementId_t | id | ) |
Activate EVE browser (summary view) for specified element id.
Definition at line 393 of file REveManager.cxx.
| void REveManager::ClearAllSelections | ( | ) |
Clear all selection objects.
Can make things easier for EVE when going to the next event. Still, destruction os selected object should still work correctly as long as it is executed within a change cycle.
Definition at line 314 of file REveManager.cxx.
| void REveManager::ClearROOTClassSaved | ( | ) |
Work-around uber ugly hack used in SavePrimitive and co.
Definition at line 721 of file REveManager.cxx.
| bool REveManager::ClientConnectionsFree | ( | ) | const |
Definition at line 1359 of file REveManager.cxx.
| void REveManager::ConnectEveViewer | ( | REveViewer * | view | ) |
Definition at line 1313 of file REveManager.cxx.
|
static |
If global REveManager* REX::gEve is not set initialize it.
Returns REX::gEve.
Definition at line 758 of file REveManager.cxx.
|
inline |
Definition at line 221 of file REveManager.hxx.
| void REveManager::DisconnectEveViewer | ( | REveViewer * | view | ) |
Definition at line 1304 of file REveManager.cxx.
| void REveManager::DoRedraw3D | ( | ) |
Perform 3D redraw of scenes and viewers whose contents has changed.
Definition at line 296 of file REveManager.cxx.
|
inline |
Definition at line 222 of file REveManager.hxx.
| void REveManager::EndChange | ( | ) |
Stop accepting changes and stream them.
If the clients have not yet acknowledged the previous changes, keep the stamps and let the last acknowledgement in WindowData() flush them. Stamps coalesce per element. Motion changes are sent in either case. Changes made by a MIR are not held back.
Definition at line 1420 of file REveManager.cxx.
|
static |
Definition at line 1483 of file REveManager.cxx.
|
static |
Definition at line 782 of file REveManager.cxx.
|
protected |
Definition at line 1070 of file REveManager.cxx.
| REveElement * REveManager::FindElementById | ( | ElementId_t | id | ) | const |
Lookup ElementId in element map and return corresponding REveElement*.
Returns nullptr if the id is not found
Definition at line 359 of file REveManager.cxx.
| REveElement * REveManager::FindVizDBEntry | ( | const TString & | tag | ) |
Find a visualization-parameter database entry corresponding to tag.
If the entry is not found 0 is returned.
Definition at line 533 of file REveManager.cxx.
Perform 3D redraw of all scenes and viewers.
Definition at line 304 of file REveManager.cxx.
|
inline |
Definition at line 190 of file REveManager.hxx.
| TGeoManager * REveManager::GetDefaultGeometry | ( | ) |
Get the default geometry.
It should be registered via RegisterGeometryName("Default", <URL>).
Definition at line 681 of file REveManager.cxx.
| REveViewer * REveManager::GetDefaultViewer | ( | ) | const |
Get the default viewer.
Definition at line 690 of file REveManager.cxx.
|
inline |
Definition at line 193 of file REveManager.hxx.
|
inline |
Definition at line 183 of file REveManager.hxx.
| TGeoManager * REveManager::GetGeometry | ( | const TString & | filename | ) |
Get geometry with given filename.
This is cached internally so the second time this function is called with the same argument the same geo-manager is returned. gGeoManager is set to the return value.
Definition at line 613 of file REveManager.cxx.
| TGeoManager * REveManager::GetGeometryByAlias | ( | const TString & | alias | ) |
Get geometry with given alias.
The alias must be registered via RegisterGeometryAlias().
Definition at line 667 of file REveManager.cxx.
|
inline |
Definition at line 192 of file REveManager.hxx.
|
inline |
Definition at line 186 of file REveManager.hxx.
|
inline |
Definition at line 304 of file REveManager.hxx.
|
inline |
Definition at line 234 of file REveManager.hxx.
|
inline |
Definition at line 188 of file REveManager.hxx.
|
inline |
Definition at line 185 of file REveManager.hxx.
| void REveManager::GetServerStatus | ( | REveServerStatus & | st | ) |
Definition at line 1451 of file REveManager.cxx.
|
inline |
Definition at line 189 of file REveManager.hxx.
|
inline |
Definition at line 257 of file REveManager.hxx.
|
inline |
Definition at line 258 of file REveManager.hxx.
|
inline |
Definition at line 289 of file REveManager.hxx.
|
inline |
Definition at line 195 of file REveManager.hxx.
| void REveManager::GrabImages | ( | std::string_view | event_id, |
| std::string_view | url = "", | ||
| int | scale = 1, | ||
| const std::vector< std::string > & | viewers = {} ) |
Ask every connected client to grab its GL viewers and POST each image to an image collector.
Each client posts the views it shows, all tagged with the same event_id.
The body is application/octet-stream, width*height*4 bytes of RGBA8 with straight alpha and no background, so it composites onto any backdrop. Headers X-Width, X-Height, X-Event-ID and X-View-Type describe it; X-Flip-Y is 1 when the rows are in WebGL bottom-up order. RenderCore's util/image-gator.js is a reference receiver. The default collector is on loopback; a remote one needs TLS and authentication.
| event_id | tag recorded with the image, e.g. run/lumi/event |
| url | collector endpoint; empty takes rootrc WebEve.ImageGatorUrl, which defaults to http://localhost:3000/capture |
| scale | multiplier on the viewer viewport; 1 is what the operator sees |
| viewers | restrict to these viewer names; empty means all of them |
Definition at line 420 of file REveManager.cxx.
| Bool_t REveManager::InsertVizDBEntry | ( | const TString & | tag, |
| REveElement * | model ) |
Insert a new visualization-parameter database entry with the default parameters for replace and update, as specified by members fVizDBReplace(default=kTRUE) and fVizDBUpdate(default=kTRUE).
See docs of the above function.
Definition at line 524 of file REveManager.cxx.
| Bool_t REveManager::InsertVizDBEntry | ( | const TString & | tag, |
| REveElement * | model, | ||
| Bool_t | replace, | ||
| Bool_t | update ) |
Insert a new visualization-parameter database entry.
Returns true if the element is inserted successfully. If entry with the same key already exists the behaviour depends on the 'replace' flag:
If insert is successful, the ownership of the model-element is transferred to the manager.
Definition at line 485 of file REveManager.cxx.
|
inline |
Definition at line 302 of file REveManager.hxx.
| void REveManager::LoadVizDB | ( | const TString & | filename | ) |
Load visualization-parameter database from file filename.
State of data-members fVizDBReplace and fVizDBUpdate determine how the registered entries are handled.
Definition at line 562 of file REveManager.cxx.
Load visualization-parameter database from file filename.
The replace, update arguments replace the values of fVizDBReplace and fVizDBUpdate members for the duration of the macro execution.
Definition at line 544 of file REveManager.cxx.
|
protected |
Definition at line 1235 of file REveManager.cxx.
|
privatedelete |
| void REveManager::PreDeleteElement | ( | REveElement * | element | ) |
Called from REveElement prior to its destruction so the framework components (like object editor) can unreference it.
Definition at line 443 of file REveManager.cxx.
|
static |
Definition at line 805 of file REveManager.cxx.
|
inline |
Definition at line 224 of file REveManager.hxx.
Register 'name' as an alias for geometry file 'filename'.
The old aliases are silently overwritten. After that the geometry can be retrieved also by calling: REX::gEve->GetGeometryByName(name);
Definition at line 713 of file REveManager.cxx.
| void REveManager::RegisterRedraw3D | ( | ) |
Definition at line 287 of file REveManager.cxx.
| void REveManager::RemoveElement | ( | REveElement * | element, |
| REveElement * | parent ) |
Remove element from parent.
Definition at line 350 of file REveManager.cxx.
| void REveManager::SaveVizDB | ( | const TString & | filename | ) |
Save visualization-parameter database to file filename.
Definition at line 571 of file REveManager.cxx.
| void ROOT::Experimental::REveManager::SceneSubscriberProcessingChanges | ( | unsigned | cinnId | ) |
| void REveManager::SceneSubscriberWaitingResponse | ( | unsigned | cinnId | ) |
Definition at line 1370 of file REveManager.cxx.
| void REveManager::ScheduleMIR | ( | const std::string & | cmd, |
| ElementId_t | i, | ||
| const std::string & | ctype, | ||
| unsigned | connid ) |
Definition at line 1055 of file REveManager.cxx.
| void REveManager::Send | ( | unsigned | connid, |
| const std::string & | data ) |
Definition at line 1331 of file REveManager.cxx.
| void REveManager::SendBinary | ( | unsigned | connid, |
| const void * | data, | ||
| std::size_t | len ) |
Definition at line 1336 of file REveManager.cxx.
|
protected |
Send transformation-only changes on the motion channel: the same websocket, outside the BeginChanges/EndChanges cycle, with no acknowledgement.
A connection for which RWebWindow::CanSend(id, true) is false skips the message. Each message is absolute state, but a client that skips the last one keeps the old state until the element changes again.
Definition at line 1159 of file REveManager.cxx.
|
protected |
Definition at line 1189 of file REveManager.cxx.
| void REveManager::SendToAllConnections | ( | const std::string & | data | ) |
Definition at line 1324 of file REveManager.cxx.
| void REveManager::SetClientVersion | ( | const std::string & | version | ) |
Set client version, used as prefix in scripts URL When changed, web browser will reload all related JS files while full URL will be different Default is empty value - no extra string in URL Version should be string like "1.2" or "ver1.subv2" and not contain any special symbols.
Definition at line 749 of file REveManager.cxx.
| void REveManager::SetDefaultHtmlPage | ( | const std::string & | path | ) |
Set content of default window HTML page.
Definition at line 739 of file REveManager.cxx.
| void REveManager::SetHttpPublic | ( | bool | x | ) |
Restrict functionality for this server when open to public.
Definition at line 1529 of file REveManager.cxx.
|
inline |
Definition at line 235 of file REveManager.hxx.
|
inline |
Definition at line 259 of file REveManager.hxx.
|
inline |
Definition at line 260 of file REveManager.hxx.
| void REveManager::Show | ( | const RWebDisplayArgs & | args = "" | ) |
Show eve manager in specified browser.
If rootrc variable WebEve.DisableShow is set, HTTP server will be started and access URL printed on stdout.
Definition at line 1387 of file REveManager.cxx.
| REveScene * REveManager::SpawnNewScene | ( | const char * | name, |
| const char * | title = "" ) |
Create a new scene.
Definition at line 280 of file REveManager.cxx.
| REveViewer * REveManager::SpawnNewViewer | ( | const char * | name, |
| const char * | title = "" ) |
Create a new GL viewer.
Definition at line 270 of file REveManager.cxx.
|
protected |
Definition at line 1141 of file REveManager.cxx.
|
protected |
Register new connection and stream the world and the mandatory scenes to it.
Definition at line 864 of file REveManager.cxx.
|
static |
Properly terminate global REveManager.
Definition at line 773 of file REveManager.cxx.
|
protected |
Process new connection from web window.
This is called in a web-server thread, which can have a small stack (the builtin civetweb uses 100 KB unless configured otherwise). Streaming the scenes can need much more: the first IsA() of an element class makes cling load declarations, which recurses deeply. If the current thread's stack is small, the streaming runs in a thread with the default stack size instead, and this thread waits for it.
Definition at line 825 of file REveManager.cxx.
|
protected |
Process data from web window.
Definition at line 970 of file REveManager.cxx.
|
protected |
Process disconnect of web window.
Definition at line 920 of file REveManager.cxx.
|
protected |
Definition at line 132 of file REveManager.hxx.
|
protected |
Definition at line 152 of file REveManager.hxx.
Definition at line 137 of file REveManager.hxx.
|
protected |
Definition at line 141 of file REveManager.hxx.
|
protected |
Definition at line 135 of file REveManager.hxx.
|
protected |
!< exception handler
Definition at line 119 of file REveManager.hxx.
|
protected |
Definition at line 125 of file REveManager.hxx.
|
protected |
Definition at line 126 of file REveManager.hxx.
|
protected |
Definition at line 134 of file REveManager.hxx.
|
protected |
Definition at line 149 of file REveManager.hxx.
|
protected |
Definition at line 165 of file REveManager.hxx.
|
protected |
Definition at line 162 of file REveManager.hxx.
Definition at line 138 of file REveManager.hxx.
|
protected |
Definition at line 142 of file REveManager.hxx.
|
protected |
Definition at line 160 of file REveManager.hxx.
|
protected |
Definition at line 144 of file REveManager.hxx.
|
protected |
Definition at line 158 of file REveManager.hxx.
|
protected |
Definition at line 156 of file REveManager.hxx.
|
protected |
Definition at line 153 of file REveManager.hxx.
|
protected |
Definition at line 143 of file REveManager.hxx.
| bool ROOT::Experimental::REveManager::fPendingSceneChanges {false} |
Changes are stamped but not yet streamed, because the clients had not acknowledged the previous scene changes when EndChange() ran.
Flushed by the last acknowledgement. Guarded by fServerState.fMutex.
Definition at line 219 of file REveManager.hxx.
Definition at line 136 of file REveManager.hxx.
|
protected |
Definition at line 131 of file REveManager.hxx.
|
protected |
Definition at line 148 of file REveManager.hxx.
|
protected |
Definition at line 147 of file REveManager.hxx.
|
protected |
Definition at line 157 of file REveManager.hxx.
|
protected |
Definition at line 161 of file REveManager.hxx.
|
protected |
Definition at line 130 of file REveManager.hxx.
|
protected |
Definition at line 121 of file REveManager.hxx.
Definition at line 122 of file REveManager.hxx.
Definition at line 123 of file REveManager.hxx.
|
protected |
Definition at line 151 of file REveManager.hxx.
|
protected |
Definition at line 128 of file REveManager.hxx.