Tanoda
Leap.Unity.Graphing.RealtimeGraph Class Reference
Inheritance diagram for Leap.Unity.Graphing.RealtimeGraph:

Classes

class  Graph
 
struct  GraphKey
 

Public Types

enum  GraphUnits { Miliseconds , Framerate }
 
enum  GraphMode { Inclusive , Exclusive }
 

Public Member Functions

void BeginSample (GraphKey key)
 
void BeginSample (string sampleName, GraphUnits units)
 
void EndSample ()
 
void AddSample (string sampleName, GraphUnits units, long ticks)
 
void AddSample (string sampleName, GraphUnits units, float ms)
 
void SwtichGraph (string graphName)
 
void TogglePaused ()
 

Protected Member Functions

virtual void OnValidate ()
 
virtual void Awake ()
 
virtual void Start ()
 
virtual void OnEnable ()
 
virtual void OnDisable ()
 
virtual void Update ()
 
virtual void FixedUpdate ()
 
Graph getGraph (string name, GraphUnits units)
 
void addCallback (Button button, string name)
 
void replayKeys ()
 

Static Protected Member Functions

static float ticksToMs (long ticks)
 

Protected Attributes

string _defaultGraph = "Framerate"
 
string[] _unitySamplerNames = new string[0]
 
GraphMode _graphMode = GraphMode.Exclusive
 
int _historyLength = 128
 
int _updatePeriod = 10
 
int _samplesPerFrame = 1
 
float _framerateLineSpacing = 60
 
float _deltaLineSpacing = 10
 
float _maxSmoothingDelay = 0.1f
 
float _valueSmoothingDelay = 1
 
LeapServiceProvider _provider
 
Renderer _graphRenderer
 
Text titleLabel
 
TextMesh valueMesh
 
GameObject customGraphPrefab
 
System.Diagnostics.Stopwatch _stopwatch = new System.Diagnostics.Stopwatch()
 
int _sampleIndex = 0
 
int _updateCount = 0
 
bool _paused = false
 
Texture2D _texture
 
Color32[] _colors
 
SmoothedFloat _smoothedValue
 
SmoothedFloat _smoothedMax
 
Graph _currentGraph
 
Dictionary< string, Graph_graphs
 
Stack< Graph_currentGraphStack = new Stack<Graph>()
 
Deque< GraphKey_keyBuffer = new Deque<GraphKey>()
 
List< Recorder_unityRecorders = new List<Recorder>()
 
long _preCullTicks
 
long _renderTicks
 
long _fixedTicks = -1
 

Properties

static RealtimeGraph Instance [get]
 
float UpdatePeriodFloat [set]
 
float BatchSizeFloat [set]
 
float GraphModeFloat [set]
 

Detailed Description

Definition at line 19 of file RealtimeGraph.cs.

Member Enumeration Documentation

◆ GraphMode

Enumerator
Inclusive 
Exclusive 

Definition at line 48 of file RealtimeGraph.cs.

◆ GraphUnits

Enumerator
Miliseconds 
Framerate 

Definition at line 43 of file RealtimeGraph.cs.

Member Function Documentation

◆ addCallback()

void Leap.Unity.Graphing.RealtimeGraph.addCallback ( Button  button,
string  name 
)
protected

Definition at line 402 of file RealtimeGraph.cs.

◆ AddSample() [1/2]

void Leap.Unity.Graphing.RealtimeGraph.AddSample ( string  sampleName,
GraphUnits  units,
float  ms 
)

Definition at line 160 of file RealtimeGraph.cs.

◆ AddSample() [2/2]

void Leap.Unity.Graphing.RealtimeGraph.AddSample ( string  sampleName,
GraphUnits  units,
long  ticks 
)

Definition at line 155 of file RealtimeGraph.cs.

◆ Awake()

virtual void Leap.Unity.Graphing.RealtimeGraph.Awake ( )
protectedvirtual

Definition at line 179 of file RealtimeGraph.cs.

◆ BeginSample() [1/2]

void Leap.Unity.Graphing.RealtimeGraph.BeginSample ( GraphKey  key)

Definition at line 141 of file RealtimeGraph.cs.

◆ BeginSample() [2/2]

void Leap.Unity.Graphing.RealtimeGraph.BeginSample ( string  sampleName,
GraphUnits  units 
)

Definition at line 146 of file RealtimeGraph.cs.

◆ EndSample()

void Leap.Unity.Graphing.RealtimeGraph.EndSample ( )

Definition at line 151 of file RealtimeGraph.cs.

◆ FixedUpdate()

virtual void Leap.Unity.Graphing.RealtimeGraph.FixedUpdate ( )
protectedvirtual

Definition at line 282 of file RealtimeGraph.cs.

◆ getGraph()

Graph Leap.Unity.Graphing.RealtimeGraph.getGraph ( string  name,
GraphUnits  units 
)
protected

Definition at line 378 of file RealtimeGraph.cs.

◆ OnDisable()

virtual void Leap.Unity.Graphing.RealtimeGraph.OnDisable ( )
protectedvirtual

Definition at line 214 of file RealtimeGraph.cs.

◆ OnEnable()

virtual void Leap.Unity.Graphing.RealtimeGraph.OnEnable ( )
protectedvirtual

Definition at line 207 of file RealtimeGraph.cs.

◆ OnValidate()

virtual void Leap.Unity.Graphing.RealtimeGraph.OnValidate ( )
protectedvirtual

Definition at line 174 of file RealtimeGraph.cs.

◆ replayKeys()

void Leap.Unity.Graphing.RealtimeGraph.replayKeys ( )
protected

Definition at line 406 of file RealtimeGraph.cs.

◆ Start()

virtual void Leap.Unity.Graphing.RealtimeGraph.Start ( )
protectedvirtual

Definition at line 189 of file RealtimeGraph.cs.

◆ SwtichGraph()

void Leap.Unity.Graphing.RealtimeGraph.SwtichGraph ( string  graphName)

Definition at line 165 of file RealtimeGraph.cs.

◆ ticksToMs()

static float Leap.Unity.Graphing.RealtimeGraph.ticksToMs ( long  ticks)
staticprotected

Definition at line 321 of file RealtimeGraph.cs.

◆ TogglePaused()

void Leap.Unity.Graphing.RealtimeGraph.TogglePaused ( )

Definition at line 170 of file RealtimeGraph.cs.

◆ Update()

virtual void Leap.Unity.Graphing.RealtimeGraph.Update ( )
protectedvirtual

Definition at line 219 of file RealtimeGraph.cs.

Member Data Documentation

◆ _colors

Color32 [] Leap.Unity.Graphing.RealtimeGraph._colors
protected

Definition at line 125 of file RealtimeGraph.cs.

◆ _currentGraph

Graph Leap.Unity.Graphing.RealtimeGraph._currentGraph
protected

Definition at line 130 of file RealtimeGraph.cs.

◆ _currentGraphStack

Stack<Graph> Leap.Unity.Graphing.RealtimeGraph._currentGraphStack = new Stack<Graph>()
protected

Definition at line 132 of file RealtimeGraph.cs.

◆ _defaultGraph

string Leap.Unity.Graphing.RealtimeGraph._defaultGraph = "Framerate"
protected

Definition at line 54 of file RealtimeGraph.cs.

◆ _deltaLineSpacing

float Leap.Unity.Graphing.RealtimeGraph._deltaLineSpacing = 10
protected

Definition at line 75 of file RealtimeGraph.cs.

◆ _fixedTicks

long Leap.Unity.Graphing.RealtimeGraph._fixedTicks = -1
protected

Definition at line 139 of file RealtimeGraph.cs.

◆ _framerateLineSpacing

float Leap.Unity.Graphing.RealtimeGraph._framerateLineSpacing = 60
protected

Definition at line 72 of file RealtimeGraph.cs.

◆ _graphMode

GraphMode Leap.Unity.Graphing.RealtimeGraph._graphMode = GraphMode.Exclusive
protected

Definition at line 60 of file RealtimeGraph.cs.

◆ _graphRenderer

Renderer Leap.Unity.Graphing.RealtimeGraph._graphRenderer
protected

Definition at line 88 of file RealtimeGraph.cs.

◆ _graphs

Dictionary<string, Graph> Leap.Unity.Graphing.RealtimeGraph._graphs
protected

Definition at line 131 of file RealtimeGraph.cs.

◆ _historyLength

int Leap.Unity.Graphing.RealtimeGraph._historyLength = 128
protected

Definition at line 63 of file RealtimeGraph.cs.

◆ _keyBuffer

Deque<GraphKey> Leap.Unity.Graphing.RealtimeGraph._keyBuffer = new Deque<GraphKey>()
protected

Definition at line 134 of file RealtimeGraph.cs.

◆ _maxSmoothingDelay

float Leap.Unity.Graphing.RealtimeGraph._maxSmoothingDelay = 0.1f
protected

Definition at line 78 of file RealtimeGraph.cs.

◆ _paused

bool Leap.Unity.Graphing.RealtimeGraph._paused = false
protected

Definition at line 122 of file RealtimeGraph.cs.

◆ _preCullTicks

long Leap.Unity.Graphing.RealtimeGraph._preCullTicks
protected

Definition at line 139 of file RealtimeGraph.cs.

◆ _provider

LeapServiceProvider Leap.Unity.Graphing.RealtimeGraph._provider
protected

Definition at line 85 of file RealtimeGraph.cs.

◆ _renderTicks

long Leap.Unity.Graphing.RealtimeGraph._renderTicks
protected

Definition at line 139 of file RealtimeGraph.cs.

◆ _sampleIndex

int Leap.Unity.Graphing.RealtimeGraph._sampleIndex = 0
protected

Definition at line 119 of file RealtimeGraph.cs.

◆ _samplesPerFrame

int Leap.Unity.Graphing.RealtimeGraph._samplesPerFrame = 1
protected

Definition at line 69 of file RealtimeGraph.cs.

◆ _smoothedMax

SmoothedFloat Leap.Unity.Graphing.RealtimeGraph._smoothedMax
protected

Definition at line 128 of file RealtimeGraph.cs.

◆ _smoothedValue

SmoothedFloat Leap.Unity.Graphing.RealtimeGraph._smoothedValue
protected

Definition at line 127 of file RealtimeGraph.cs.

◆ _stopwatch

System.Diagnostics.Stopwatch Leap.Unity.Graphing.RealtimeGraph._stopwatch = new System.Diagnostics.Stopwatch()
protected

Definition at line 117 of file RealtimeGraph.cs.

◆ _texture

Texture2D Leap.Unity.Graphing.RealtimeGraph._texture
protected

Definition at line 124 of file RealtimeGraph.cs.

◆ _unityRecorders

List<Recorder> Leap.Unity.Graphing.RealtimeGraph._unityRecorders = new List<Recorder>()
protected

Definition at line 136 of file RealtimeGraph.cs.

◆ _unitySamplerNames

string [] Leap.Unity.Graphing.RealtimeGraph._unitySamplerNames = new string[0]
protected

Definition at line 57 of file RealtimeGraph.cs.

◆ _updateCount

int Leap.Unity.Graphing.RealtimeGraph._updateCount = 0
protected

Definition at line 120 of file RealtimeGraph.cs.

◆ _updatePeriod

int Leap.Unity.Graphing.RealtimeGraph._updatePeriod = 10
protected

Definition at line 66 of file RealtimeGraph.cs.

◆ _valueSmoothingDelay

float Leap.Unity.Graphing.RealtimeGraph._valueSmoothingDelay = 1
protected

Definition at line 81 of file RealtimeGraph.cs.

◆ customGraphPrefab

GameObject Leap.Unity.Graphing.RealtimeGraph.customGraphPrefab
protected

Definition at line 97 of file RealtimeGraph.cs.

◆ titleLabel

Text Leap.Unity.Graphing.RealtimeGraph.titleLabel
protected

Definition at line 91 of file RealtimeGraph.cs.

◆ valueMesh

TextMesh Leap.Unity.Graphing.RealtimeGraph.valueMesh
protected

Definition at line 94 of file RealtimeGraph.cs.

Property Documentation

◆ BatchSizeFloat

float Leap.Unity.Graphing.RealtimeGraph.BatchSizeFloat
set

Definition at line 105 of file RealtimeGraph.cs.

◆ GraphModeFloat

float Leap.Unity.Graphing.RealtimeGraph.GraphModeFloat
set

Definition at line 111 of file RealtimeGraph.cs.

◆ Instance

RealtimeGraph Leap.Unity.Graphing.RealtimeGraph.Instance
staticget

Definition at line 22 of file RealtimeGraph.cs.

◆ UpdatePeriodFloat

float Leap.Unity.Graphing.RealtimeGraph.UpdatePeriodFloat
set

Definition at line 99 of file RealtimeGraph.cs.


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