From b437600c820f489049c022d2c4697226cf8d68fc Mon Sep 17 00:00:00 2001 From: Vito Caputo Date: Thu, 9 Jun 2022 22:40:06 -0700 Subject: til: add ticks to til_module_context_t Also wire this up to the til_module_context_new() helper and all its callers. This is in preparation for modules doing more correct delta-T derived animation. --- src/til_module_context.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/til_module_context.c') diff --git a/src/til_module_context.c b/src/til_module_context.c index a029f37..59f3f9d 100644 --- a/src/til_module_context.c +++ b/src/til_module_context.c @@ -23,7 +23,7 @@ * as the callers are generally using it in place of calloc(), and assign it to a * container struct of some other type but having an embedded til_module_context_t. */ -void * til_module_context_new(size_t size, unsigned seed, unsigned n_cpus) +void * til_module_context_new(size_t size, unsigned seed, unsigned ticks, unsigned n_cpus) { til_module_context_t *module_context; @@ -35,6 +35,7 @@ void * til_module_context_new(size_t size, unsigned seed, unsigned n_cpus) return NULL; module_context->seed = seed; + module_context->ticks = ticks; module_context->n_cpus = n_cpus; return module_context; -- cgit v1.2.1