# HG changeset patch # User Mychaela Falconia # Date 1720215295 0 # Node ID 668b84c52094537b60e9719d57dea9598a67b24d # Parent 1bb26347e253cd1534f6d8d2eeca63be930d5e32 twrtp_jibuf_create(): take quantum_ms & clock_khz arguments diff -r 1bb26347e253 -r 668b84c52094 include/twjit.h --- a/include/twjit.h Fri Jul 05 21:24:56 2024 +0000 +++ b/include/twjit.h Fri Jul 05 21:34:55 2024 +0000 @@ -109,7 +109,7 @@ /* twjit module API functions */ struct twrtp_jibuf_inst *twrtp_jibuf_create(void *ctx, uint16_t quantum_ms, - uint32_t quantum_ts_inc, + uint16_t clock_khz, struct twrtp_jibuf_config *config); void twrtp_jibuf_destroy(struct twrtp_jibuf_inst *twjit); diff -r 1bb26347e253 -r 668b84c52094 src/twjit.c --- a/src/twjit.c Fri Jul 05 21:24:56 2024 +0000 +++ b/src/twjit.c Fri Jul 05 21:34:55 2024 +0000 @@ -25,7 +25,7 @@ /* create and destroy functions */ struct twrtp_jibuf_inst * -twrtp_jibuf_create(void *ctx, uint16_t quantum_ms, uint32_t quantum_ts_inc, +twrtp_jibuf_create(void *ctx, uint16_t quantum_ms, uint16_t clock_khz, struct twrtp_jibuf_config *config) { struct twrtp_jibuf_inst *twjit; @@ -35,7 +35,7 @@ return NULL; twjit->ext_config = config; - twjit->ts_quantum = quantum_ts_inc; + twjit->ts_quantum = (uint32_t)quantum_ms * clock_khz; twjit->quanta_per_sec = 1000 / quantum_ms; twjit->state = TWJIT_STATE_EMPTY; INIT_LLIST_HEAD(&twjit->sb[0].queue);