NvGPUTimerScope Struct Reference

A helper class that allows for simple "code block" implicit timer start/stops. More...

#include <NvTimers.h>

List of all members.

Public Member Functions

 NvGPUTimerScope (NvGPUTimer *timer)
 Constructor - starts the given timer.
 ~NvGPUTimerScope ()
 Destructor - stops the timer that was passed to the constructor.

Public Attributes

NvGPUTimerm_timer


Detailed Description

A helper class that allows for simple "code block" implicit timer start/stops.

The following code:

     {
         NvGPUTimerScope myScope(myTimer);
         // ... my block of timed code
     }

Is equivalent to:

     {
         myTimer->start();
         // ... my block of timed code
         myTimer->stop();
     }

Constructor & Destructor Documentation

NvGPUTimerScope::NvGPUTimerScope ( NvGPUTimer timer  )  [inline]

Constructor - starts the given timer.

Parameters:
[in] timer the timer to be used


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