pipewire/src/pipewire
Janne Grunau be1677f569 stream: Fix pw_time.delay calculation for rate.num > 1
Pipewire uses a rate of 256/7680 with the integrated camera of Apple
silicon Macbooks. To calculate pw_time.delay correctly in this case it
has to be divided by time->rate.num. Without this division the delay
contribution of the `((latency->min_ns + latency->max_ns) / 2)` term
ends up as 255 which are 8.5 seconds.
pipewiresrc reports the delay as latency in the gstreamer pipeline which
results in rendering a frame every 8.5 seconds.
I suspect the non-normalized rate of 256/7680 is another bug in
pipewire. The rate for an UVC webcam is reported as 1/30. Both
Video4Linux2 devices report a discrete frame interval of 0.033s (30fps).

Fixes #4957

(cherry picked from commit f03021edd1)
2025-12-15 09:54:16 +01:00
..
extensions Add missing includes to metadata.h 2025-02-25 12:49:46 +00:00
array.h add per type API defines 2024-11-26 11:58:51 +01:00
buffers.c mem: MAPPABLE -> UNMAPPABLE 2024-04-10 13:11:54 +02:00
buffers.h buffers: add new ASYNC flag 2023-03-30 15:03:29 +02:00
client.h doc: copy docs from the _methods struct 2024-11-26 13:21:04 +01:00
conf.c conf: remove client-rt.conf 2025-01-14 12:40:05 +01:00
conf.h pulse-server: add condition support in pulse.cmd 2024-10-23 09:08:50 +02:00
context.c timer-queue: add a new timer queue helper 2025-10-13 11:25:37 -07:00
context.h timer-queue: add a new timer queue helper 2025-10-13 11:25:37 -07:00
control.c mem: MAPPABLE -> UNMAPPABLE 2024-04-10 13:11:54 +02:00
control.h docs: Multiple clarifications to documentation 2024-01-12 11:55:28 +01:00
core.c core: inherit the default.clock.quantum-limit from the server 2025-01-09 11:38:07 +01:00
core.h core: Remove redundant declaration 2024-11-27 17:33:11 +01:00
data-loop.c keys: add and use some loop keys 2024-04-23 11:49:12 +02:00
data-loop.h data-loop: add functions to get name and class 2024-04-22 11:00:22 +02:00
device.h doc: copy docs from the _methods struct 2024-11-26 13:21:04 +01:00
factory.h doc: copy docs from the _methods struct 2024-11-26 13:21:04 +01:00
filter.c filter: removed QUEUED flag and add DEQUEUED flag 2025-09-10 10:19:35 +02:00
filter.h stream: set errno to the current error 2025-03-04 13:22:51 +01:00
global.c global: avoid recursive destroy calls 2024-09-04 18:05:29 +02:00
global.h perm: add permission mask to global 2023-07-28 10:22:12 +02:00
i18n.h treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
impl-client.c make per object IMPL 2024-11-26 11:35:50 +01:00
impl-client.h doc: link \page and \group by \see 2023-11-04 15:22:18 +02:00
impl-core.c Ensure all globals have PW_KEY_OBJECT_SERIAL prop 2024-02-09 14:45:05 +00:00
impl-core.h treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
impl-device.c make per object IMPL 2024-11-26 11:35:50 +01:00
impl-device.h treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
impl-factory.c make per object IMPL 2024-11-26 11:35:50 +01:00
impl-factory.h treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
impl-link.c impl-link: improve debug log 2025-04-02 15:33:54 +02:00
impl-link.h treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
impl-metadata.c pipewire: remove cleanup.h 2024-05-16 17:35:58 +02:00
impl-metadata.h treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
impl-module.c make per object IMPL 2024-11-26 11:35:50 +01:00
impl-module.h docs: Multiple clarifications to documentation 2024-01-12 11:55:28 +01:00
impl-node.c impl-node: only do unprepare once 2025-09-15 10:33:14 +02:00
impl-node.h impl-node: don't report xrun when pending <= 0 2024-04-04 22:01:01 +02:00
impl-port.c make per object IMPL 2024-11-26 11:35:50 +01:00
impl-port.h Port: Add tag param 2023-08-29 14:22:13 +02:00
impl.h treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
introspect.c pipewire: introspect: do not leave spa_param_infos uninitialized 2023-06-01 16:57:42 +00:00
keys.h protocol: improve manager socket handling 2025-01-29 12:59:45 +01:00
link.h doc: copy docs from the _methods struct 2024-11-26 13:21:04 +01:00
log.c timer-queue: add a new timer queue helper 2025-10-13 11:25:37 -07:00
log.h log: add pw_log_topic_custom_enabled() 2024-01-04 17:40:57 +01:00
loop.c make per object IMPL 2024-11-26 11:35:50 +01:00
loop.h loop: remove return from function returning void 2025-03-14 10:15:42 +01:00
main-loop.c loop: clarify the pw_main_loop_run returned value 2024-06-04 15:34:59 +00:00
main-loop.h loop: clarify the pw_main_loop_run returned value 2024-06-04 15:34:59 +00:00
map.h add per type API defines 2024-11-26 11:58:51 +01:00
mem.c pipewire: mem: pw_memblock_map(): fix pointer when reusing mapping 2025-09-10 10:29:53 +02:00
mem.h pipewire: mem: forward declare spa_hook 2025-09-10 10:29:34 +02:00
meson.build timer-queue: add a new timer queue helper 2025-10-13 11:25:37 -07:00
module.h doc: copy docs from the _methods struct 2024-11-26 13:21:04 +01:00
node.h doc: copy docs from the _methods struct 2024-11-26 13:21:04 +01:00
permission.h perm: add a new L permissions 2023-07-28 11:01:43 +02:00
pipewire.c pipewire: use local real time timestamps in logging 2025-01-13 13:48:22 +00:00
pipewire.h timer-queue: add a new timer queue helper 2025-10-13 11:25:37 -07:00
port.h doc: copy docs from the _methods struct 2024-11-26 13:21:04 +01:00
private.h timer-queue: add a new timer queue helper 2025-10-13 11:25:37 -07:00
properties.c add per type API defines 2024-11-26 11:58:51 +01:00
properties.h add per type API defines 2024-11-26 11:58:51 +01:00
protocol.c treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
protocol.h protocol-native: add security context API 2024-03-13 12:53:04 +01:00
proxy.c proxy: invalidate proxy id when removed from map 2024-10-24 13:46:09 +00:00
proxy.h doc: link \page and \group by \see 2023-11-04 15:22:18 +02:00
resource.c core: add bound_props event 2023-03-21 17:22:27 +01:00
resource.h treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
settings.c spa: add spa_json_begin_array/object and relaxed versions 2024-09-16 09:50:33 +02:00
stream.c stream: Fix pw_time.delay calculation for rate.num > 1 2025-12-15 09:54:16 +01:00
stream.h stream: set errno to the current error 2025-03-04 13:22:51 +01:00
thread-loop.c loop: move the loop name to pw_loop 2024-04-22 15:18:26 +02:00
thread-loop.h thread-loop: clarify some docs about locking 2025-01-20 10:04:09 +01:00
thread.c pipewire: thread: fix strerror() argument 2024-12-14 23:28:43 +01:00
thread.h make per object IMPL 2024-11-26 11:35:50 +01:00
timer-queue.c timer-queue: delete next timer event when it got fired 2025-10-13 11:26:43 -07:00
timer-queue.h timer-queue: add a new timer queue helper 2025-10-13 11:25:37 -07:00
type.h treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
utils.c spa: add spa_json_begin_array/object and relaxed versions 2024-09-16 09:50:33 +02:00
utils.h pipewire: remove cleanup.h 2024-05-16 17:35:58 +02:00
version.h.in pipewire: add missing stdbool.h include to version.h.in 2023-07-24 12:48:33 +02:00
work-queue.c Fix typos 2024-05-22 09:19:34 +02:00
work-queue.h treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00