home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.hitl.washington.edu
/
ftp.hitl.washington.edu.tar
/
ftp.hitl.washington.edu
/
pub
/
people
/
habib
/
kodak
/
frame_rate.h~
< prev
next >
Wrap
Text File
|
2000-04-18
|
824b
|
21 lines
#include <time.h>
#include <iostream.h>
class ClassFrameRate
{
public :
ClassFrameRate();
private :
int counter_time; // To calculate the frame rate or the time a function is taking, and if this time
int counter_time2;// is of the order of 0.1 seconds, we should calculate an average of at least 20
// passes through this function because the precision of clock is about 0.05
// seconds. Why? who the hell knows why...
clock_t start, finish; // to be used with clock() ex: start = clock(); which reads the clock.
clock_t start2, finish2;// to be used with clock() ex: start = clock(); which reads the clock.
public :
void PrintAverageFR (int marra) ; // Prints the Average Frame Rate of marra frames.
float GetElapsedTime (int marra, float time); // Guess...
};