mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-09 13:30:06 -05:00
jack-tunnel: convert JACK time to MONOTONIC
JACK current_msec can be in MONOTONIC_RAW or MONOTONIC, depending on how JACK was compiled (but it's likely MONOTONIC_RAW). PipeWire requires the nsec field to be in MONOTONIC so take some time snapshots from both clocks and apply a translation. Also make sure we only get the nsec time from streams that exist. See #3886
This commit is contained in:
parent
f4e391dd41
commit
f2f60ee0ec
4 changed files with 50 additions and 2 deletions
|
|
@ -21,6 +21,7 @@ struct weakjack {
|
|||
jack_nframes_t (*cycle_wait) (jack_client_t* client);
|
||||
void (*cycle_signal) (jack_client_t* client, int status);
|
||||
|
||||
jack_time_t (*get_time) (void);
|
||||
jack_nframes_t (*frame_time) (const jack_client_t *);
|
||||
int (*get_cycle_times) (const jack_client_t *client,
|
||||
jack_nframes_t *current_frames,
|
||||
|
|
@ -111,6 +112,7 @@ static inline int weakjack_load_by_path(struct weakjack *jack, const char *path)
|
|||
spa_zero(*jack);
|
||||
LOAD_SYM(cycle_wait);
|
||||
LOAD_SYM(cycle_signal);
|
||||
LOAD_SYM(get_time);
|
||||
LOAD_SYM(frame_time);
|
||||
LOAD_SYM(get_cycle_times);
|
||||
LOAD_SYM(transport_query);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue