Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-30 10:11:45

0001 /*
0002   Copyright @ 1999 ImageMagick Studio LLC, a non-profit organization
0003   dedicated to making software imaging solutions freely available.
0004   
0005   You may not use this file except in compliance with the License.  You may
0006   obtain a copy of the License at
0007   
0008     https://imagemagick.org/script/license.php
0009   
0010   Unless required by applicable law or agreed to in writing, software
0011   distributed under the License is distributed on an "AS IS" BASIS,
0012   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
0013   See the License for the specific language governing permissions and
0014   limitations under the License.
0015 
0016   MagickCore timer methods.
0017 */
0018 #ifndef MAGICKCORE_TIMER_H
0019 #define MAGICKCORE_TIMER_H
0020 
0021 #if defined(__cplusplus) || defined(c_plusplus)
0022 extern "C" {
0023 #endif
0024 
0025 typedef enum
0026 {
0027   UndefinedTimerState,
0028   StoppedTimerState,
0029   RunningTimerState
0030 } TimerState;
0031 
0032 typedef struct _Timer
0033 {
0034   double
0035     start,
0036     stop,
0037     total;
0038 } Timer;
0039 
0040 typedef struct _TimerInfo
0041 { 
0042   Timer
0043     user,
0044     elapsed;
0045   
0046   TimerState
0047     state;
0048   
0049   size_t
0050     signature;
0051 } TimerInfo;
0052 
0053 extern MagickExport double
0054   GetElapsedTime(TimerInfo *),
0055   GetUserTime(TimerInfo *);
0056 
0057 extern MagickExport MagickBooleanType
0058   ContinueTimer(TimerInfo *);
0059 
0060 extern MagickExport ssize_t
0061   FormatMagickTime(const time_t,const size_t,char *);
0062 
0063 extern MagickExport TimerInfo
0064   *AcquireTimerInfo(void),
0065   *DestroyTimerInfo(TimerInfo *);
0066 
0067 extern MagickExport void
0068   GetTimerInfo(TimerInfo *),
0069   ResetTimer(TimerInfo *),
0070   StartTimer(TimerInfo *,const MagickBooleanType);
0071 
0072 #if defined(__cplusplus) || defined(c_plusplus)
0073 }
0074 #endif
0075 
0076 #endif