Blender  V3.3
BLI_timer.h
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-or-later
2  * Copyright 2018 Blender Foundation. All rights reserved. */
3 
4 #pragma once
5 
6 #include "BLI_sys_types.h"
7 
12 #ifdef __cplusplus
13 extern "C" {
14 #endif
15 
21 typedef double (*BLI_timer_func)(uintptr_t uuid, void *user_data);
22 typedef void (*BLI_timer_data_free)(uintptr_t uuid, void *user_data);
23 
24 /* `func(...) < 0`: The timer will be removed.
25  * `func(...) >= 0`: The function will be called again in that many seconds. */
27  BLI_timer_func func,
28  void *user_data,
29  BLI_timer_data_free user_data_free,
30  double first_interval,
31  bool persistent);
32 
34 
37 
39 void BLI_timer_execute(void);
40 
41 void BLI_timer_free(void);
42 
43 /* This function is to be called next to BKE_CB_EVT_LOAD_PRE, to make sure the module
44  * is properly configured for the new file. */
45 void BLI_timer_on_file_load(void);
46 
47 #ifdef __cplusplus
48 }
49 #endif
bool BLI_timer_is_registered(uintptr_t uuid)
Definition: BLI_timer.c:72
void BLI_timer_register(uintptr_t uuid, BLI_timer_func func, void *user_data, BLI_timer_data_free user_data_free, double first_interval, bool persistent)
Definition: BLI_timer.c:33
void(* BLI_timer_data_free)(uintptr_t uuid, void *user_data)
Definition: BLI_timer.h:22
bool BLI_timer_unregister(uintptr_t uuid)
Definition: BLI_timer.c:60
void BLI_timer_free(void)
Definition: BLI_timer.c:123
double(* BLI_timer_func)(uintptr_t uuid, void *user_data)
Definition: BLI_timer.h:21
void BLI_timer_on_file_load(void)
Definition: BLI_timer.c:141
void BLI_timer_execute(void)
Definition: BLI_timer.c:117
typedef double(DMatrix)[4][4]
void * user_data
SyclQueue void void size_t num_bytes void
_W64 unsigned int uintptr_t
Definition: stdint.h:119