VTK
dox
Rendering
OpenGL2
vtkOpenGLRenderTimer.h
Go to the documentation of this file.
1
/*=========================================================================
2
3
Program: Visualization Toolkit
4
Module: vtkOpenGLRenderTimer.h
5
6
Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7
All rights reserved.
8
See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9
10
This software is distributed WITHOUT ANY WARRANTY; without even
11
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12
PURPOSE. See the above copyright notice for more information.
13
14
=========================================================================*/
15
30
#ifndef vtkOpenGLRenderTimer_h
31
#define vtkOpenGLRenderTimer_h
32
33
#include "vtkRenderingOpenGL2Module.h"
// For export macro
34
#include "
vtkType.h
"
// For vtkTypeUint64, etc
35
36
class
VTKRENDERINGOPENGL2_EXPORT
vtkOpenGLRenderTimer
37
{
38
public
:
39
vtkOpenGLRenderTimer
();
40
~
vtkOpenGLRenderTimer
();
41
45
void
Reset();
46
50
void
Start();
51
55
void
Stop();
56
60
bool
Started();
61
65
bool
Stopped();
66
70
bool
Ready();
71
73
76
float
GetElapsedSeconds();
77
float
GetElapsedMilliseconds();
78
vtkTypeUInt64 GetElapsedNanoseconds();
80
82
107
void
ReusableStart();
108
void
ReusableStop();
109
float
GetReusableElapsedSeconds();
111
116
void
ReleaseGraphicsResources();
117
118
protected
:
119
bool
StartReady
;
120
bool
EndReady
;
121
122
vtkTypeUInt32
StartQuery
;
123
vtkTypeUInt32
EndQuery
;
124
125
vtkTypeUInt64
StartTime
;
126
vtkTypeUInt64
EndTime
;
127
128
bool
ReusableStarted
;
129
bool
ReusableEnded
;
130
131
private
:
132
vtkOpenGLRenderTimer
(
const
vtkOpenGLRenderTimer
&) VTK_DELETE_FUNCTION;
133
void
operator=(
const
vtkOpenGLRenderTimer
&) VTK_DELETE_FUNCTION;
134
};
135
136
#endif // vtkOpenGLRenderTimer_h
137
138
// VTK-HeaderTest-Exclude: vtkOpenGLRenderTimer.h
vtkOpenGLRenderTimer::StartReady
bool StartReady
Definition:
vtkOpenGLRenderTimer.h:119
vtkOpenGLRenderTimer::ReusableEnded
bool ReusableEnded
Definition:
vtkOpenGLRenderTimer.h:129
vtkOpenGLRenderTimer::EndQuery
vtkTypeUInt32 EndQuery
Definition:
vtkOpenGLRenderTimer.h:123
vtkOpenGLRenderTimer::ReusableStarted
bool ReusableStarted
Definition:
vtkOpenGLRenderTimer.h:128
vtkOpenGLRenderTimer::StartQuery
vtkTypeUInt32 StartQuery
Definition:
vtkOpenGLRenderTimer.h:122
vtkOpenGLRenderTimer::EndReady
bool EndReady
Definition:
vtkOpenGLRenderTimer.h:120
vtkType.h
vtkOpenGLRenderTimer::EndTime
vtkTypeUInt64 EndTime
Definition:
vtkOpenGLRenderTimer.h:126
vtkOpenGLRenderTimer::StartTime
vtkTypeUInt64 StartTime
Definition:
vtkOpenGLRenderTimer.h:125
vtkOpenGLRenderTimer
Asynchronously measures GPU execution time.
Definition:
vtkOpenGLRenderTimer.h:36
Generated by
1.8.13