Crates.io | singletonThread |
lib.rs | singletonThread |
version | 1.1.0 |
source | src |
created_at | 2024-01-24 13:14:07.115943 |
updated_at | 2024-08-18 13:42:24.932934 |
description | thread in a singleton |
homepage | |
repository | https://github.com/hyultis/singletonThread |
max_upload_size | |
id | 1112157 |
size | 22,006 |
A library using a FnMut you defined and run it on a thread that follow a singleton pattern :
Some tool allow you to define how you want to rerun the thread :
setDuration() or setDuration_FPS() : define a minimum time between to run. (default 17ms / 60fps)
thread_launch() : try to rerun the thread, do nothing if the thread is already running
setLoop() : loop the thread
You can check the test as example, here : https://github.com/hyultis/singletonThread/blob/master/tests/tests.rs
Licensed under either of
at your option.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 licence, shall be dual licensed as above, without any additional terms or conditions.