#pragma once typedef float play_fn(void *, double time, float in); #define struct_init(ptr) _struct_init((void **)ptr, sizeof(*ptr)) static inline int _struct_init(void **ptr, size_t size) { if (*ptr) return 0; if ((*ptr = calloc(size, 1))) return 0; return 1; } extern play_fn play;