diff --git a/src/call/call_jitter.cpp b/src/call/call_jitter.cpp index aba46c16..9b7da245 100644 --- a/src/call/call_jitter.cpp +++ b/src/call/call_jitter.cpp @@ -214,6 +214,12 @@ void call_jitter_progress(struct call_jitter* j, uint64_t epoch, uint64_t positi j->timeline.progress(epoch, position, at_us, now_us, measured != 0); } +void call_jitter_suspend_device(struct call_jitter* j, uint64_t epoch) { + if (!j) return; + std::lock_guard lock(j->mtx); + j->timeline.suspend_device(epoch); +} + void call_jitter_clock(struct call_jitter* j, int64_t now_us, struct call_clock_snapshot* out) { if (!j || !out) return; std::lock_guard lock(j->mtx); diff --git a/src/call/call_jitter.h b/src/call/call_jitter.h index 23020a5e..8e494a87 100644 --- a/src/call/call_jitter.h +++ b/src/call/call_jitter.h @@ -43,6 +43,7 @@ int call_jitter_pull(struct call_jitter* j, int16_t* out, int max_samples); /* Playback worker: учесть локальную тишину/тон после pull и прогресс устройства. */ void call_jitter_silence(struct call_jitter* j, unsigned samples); void call_jitter_progress(struct call_jitter* j, uint64_t epoch, uint64_t position, int64_t at_us, int64_t now_us, int measured); +void call_jitter_suspend_device(struct call_jitter* j, uint64_t epoch); /* Любой поток: снимок часов, включая epoch при valid=0. */ void call_jitter_clock(struct call_jitter* j, int64_t now_us, struct call_clock_snapshot* out); void call_jitter_get_stats(struct call_jitter* j, int* depth_ms, int* tempo_x100,