Open Inventor Release 2023.2.3
 
Loading...
Searching...
No Matches
RemoteViz::Rendering::Monitoring Class Reference

RemoteViz More...

#include <RemoteViz/Rendering/Monitoring.h>

Public Types

enum  MetricType {
  NONE = 0x00 ,
  NETWORK_LATENCY = 0x1 ,
  DECODING_TIME = 0x2 ,
  RENDERING_TIME = 0x4 ,
  ENCODING_TIME = 0x8 ,
  NUM_CLIENTS = 0x10 ,
  NUM_CONNECTIONS = 0x20 ,
  NUM_RENDERAREAS = 0x40 ,
  ALL = 0xFFFF
}
 Types of metrics. More...
 

Public Member Functions

void addListener (std::shared_ptr< MetricsListener > listener)
 Adds a listener for metrics.
 
void removeListener (std::shared_ptr< MetricsListener > listener)
 Removes a listener for metrics.
 
unsigned int getNumListeners () const
 Return the number of listeners.
 
void enableMetrics (unsigned int mask)
 Enable metrics By default, all metrics are disabled.
 
bool isMetricEnabled (MetricType metric) const
 Check if a metric is enabled.
 

Detailed Description

RemoteViz

This class enables to manage metrics listeners that monitor states and performance of the service.

A Monitoring object is automatically created by RemoteViz. Use the Service::getMonitoring() method to get this object and (for example) add a listener.

See $OIVHOME/examples/source/RemoteViz/Monitoring

Definition at line 50 of file Monitoring.h.

Member Enumeration Documentation

◆ MetricType

Types of metrics.

Enumerator
NONE 

No metrics.

NETWORK_LATENCY 

Network latency: Reported every 1 second.

DECODING_TIME 

Decoding time: Reported each time a frame is sent to the client.

RENDERING_TIME 

Rendering time: Reported each time a frame is rendered.

ENCODING_TIME 

Encoding time: Reported each time a frame is sent to the client.

NUM_CLIENTS 

Number of clients: Reported when a client is added or removed.

NUM_CONNECTIONS 

Number of connections: Reported when a connection is added or removed.

NUM_RENDERAREAS 

Number of render areas: Reported when a render area is added or removed.

ALL 

All metrics.

Definition at line 63 of file Monitoring.h.

Member Function Documentation

◆ addListener()

void RemoteViz::Rendering::Monitoring::addListener ( std::shared_ptr< MetricsListener listener)

Adds a listener for metrics.

Parameters
listener: object that listens to the service metrics.

◆ enableMetrics()

void RemoteViz::Rendering::Monitoring::enableMetrics ( unsigned int  mask)

Enable metrics By default, all metrics are disabled.

Parameters
mask: binary mask of MetricType

◆ getNumListeners()

unsigned int RemoteViz::Rendering::Monitoring::getNumListeners ( ) const

Return the number of listeners.

◆ isMetricEnabled()

bool RemoteViz::Rendering::Monitoring::isMetricEnabled ( MetricType  metric) const

Check if a metric is enabled.

Parameters
metric: metric to check

Return true if the metric is enabled, false otherwise

◆ removeListener()

void RemoteViz::Rendering::Monitoring::removeListener ( std::shared_ptr< MetricsListener listener)

Removes a listener for metrics.

Parameters
listener: object that listens to the service metrics.

The documentation for this class was generated from the following file: