A Survey of Gaussian Convolution Algorithms
|
Portable types, math constants, and timing. More...
Portable types, math constants, and timing.
Copyright (c) 2010-2013, Pascal Getreuer All rights reserved.
This program is free software: you can redistribute it and/or modify it under, at your option, the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version, or the terms of the simplified BSD license.
You should have received a copy of these licenses along with this program. If not, see http://www.gnu.org/licenses/ and http://www.opensource.org/licenses/bsd-license.html.
Definition in file basic.c.
Go to the source code of this file.
Functions | |
unsigned long | millisecond_timer () |
Millisecond-precision timer function. More... | |
unsigned long millisecond_timer | ( | ) |
Millisecond-precision timer function.
This routine implements a timer with millisecond precision. In order to obtain timing at high resolution, platform-specific functions are needed:
Otherwise as a fallback, time.h time is used, and in this case millisecond_timer() has only second accuracy. Preprocessor symbols are checked in attempt to detect whether the platform is POSIX or Windows and defines millisecond_timer() accordingly. A particular implementation can be forced by defining USE_GETSYSTEMTIME, USE_GETTIMEOFDAY, or USE_TIME.