VG3_time_delta()
[added in version 1.5]
Return the time-difference in milliseconds since last call.
SYNTAX
long
VG3_time_delta(long *tlast)
FUNCTION PARAMETERS
tlast | Address to last time of call, will be updated |
RETURN VALUE
Returns the time-difference.
DESCRIPTION
Return the time-difference in milliseconds since last call.
At first call the parameter tlast should have the value 0.
At the next calls the parameter tlast must just be passed,
and the time in milliseconds since the last call will be returned.
EXAMPLE
long tlast, tdiff; /* initialize tlast */ tlast = 0; /* check how long function1() needs */ VG3_time_delta(&tlast); function1(); tdiff = VG3_time_delta(&tlast); /* do something else */ /* check how long function2() needs */ VG3_time_delta(&tlast); function2(); tdiff = VG3_time_delta(&tlast);
SEE ALSO