NvCPUTimerScope Struct Reference

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

#include <NvCPUTimer.h>

List of all members.

Public Member Functions

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

Public Attributes

NvCPUTimerm_timer


Detailed Description

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

The following code:

     {
         NvCPUTimerScope myScope(myTimer);
         // ... my block of timed code
     }
Is equivalent to:
     {
         myTimer->start();
         // ... my block of timed code
         myTimer->stop();
     }

Constructor & Destructor Documentation

NvCPUTimerScope::NvCPUTimerScope ( NvCPUTimer 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: