Changes of Revision 41
pipewire-aptx.changes
Changed
x
1
2
-------------------------------------------------------------------
3
+Wed Jan 24 22:21:37 UTC 2024 - Mariusz Fik <fisiu@opensuse.org>
4
+
5
+- Update to version 1.0.1
6
+
7
+-------------------------------------------------------------------
8
Mon Nov 27 08:46:54 UTC 2023 - Bjørn Lie <zaitor@opensuse.org>
9
10
- Update to version 1.0.0
11
pipewire-aptx.spec
Changed
16
1
2
%define soversion 0_2
3
4
Name: pipewire-aptx
5
-Version: 1.0.0
6
+Version: 1.0.1
7
Release: 0
8
Summary: PipeWire Bluetooth aptX codec plugin
9
License: MIT
10
URL: https://gitlab.freedesktop.org/pipewire/pipewire
11
-Source: %{url}/-/archive/%{version}/pipewire-%{version}.tar.gz
12
+Source: %{url}/-/archive/%{version}/pipewire-%{version}.tar.bz2
13
14
BuildRequires: c++_compiler
15
BuildRequires: c_compiler
16
pipewire-1.0.0.tar.gz/NEWS -> pipewire-1.0.1.tar.bz2/NEWS
Changed
69
1
2
+# PipeWire 1.0.1 (2024-01-11)
3
+
4
+This is a bugfix release that is API and ABI compatible with previous
5
+1.0.x releases.
6
+
7
+## Highlights
8
+ - Work around the buggy ALSA backend in libcanberra by forcing the pulse
9
+ backend in module-x11-bell.
10
+ - Fix a race in the device info updates in pulse-server.
11
+ - Fix timing and rate matching in ALSA sequencer.
12
+ - Improve timing information in JACK and from the ALSA driver.
13
+ - More small fixes and improvements.
14
+
15
+
16
+## PipeWire
17
+ - Fix a build issue when examples where disabled.
18
+ - Avoid some compiler warnings.
19
+ - Avoid some bitfield data races. (#3706)
20
+
21
+## Modules
22
+ - Bump the PTP driver priority. (#3217)
23
+ - Support the previous "allowed" permission in the access module.
24
+ - Fix filename leak in module-filter-chain.
25
+ - Work around the buggy ALSA backend in libcanberra by forcing the pulse
26
+ backend in module-x11-bell. (#3688)
27
+ - Fix a race in the device info updates in pulse-server.
28
+ - Fix compatibility in RAOP. (#3698)
29
+
30
+## SPA
31
+ - Handle ALSA picth control errors correctly
32
+ - Clamp buffer-frames correctly. (#3000)
33
+ - Fix timing and rate matching in ALSA sequencer. (#3657)
34
+ - Revert a commit that could result in current time in the future in the
35
+ timing updates.
36
+ - Improve adapter state checks.
37
+ - Remove the timer from the ALSA pcm.
38
+ - Fix timeout in freewheel driver.
39
+
40
+## Pulse-server
41
+ - Also handle active ports for monitor sources.
42
+ - Fix zeroconf-publish format properties.
43
+
44
+## JACK
45
+ - Improve timing and transport calculations.
46
+ - Handle -ENOENT from the core and don't error out.
47
+
48
+## GStreamer
49
+ - Handle node port removal in the device provider. (#3708)
50
+ - Improve error handling while connecting.
51
+ - Fix dts_offset.
52
+
53
+Older versions:
54
+
55
+
56
# PipeWire 1.0.0 (2023-11-26)
57
58
The PipeWire project is immensely proud to announce the 1.0 release
59
60
- Manpages are now made with Doxygen.
61
- Add docs for pulse-modules
62
63
-Older versions:
64
-
65
-
66
# PipeWire 0.3.85 (2023-11-16)
67
68
This is the fifth (and last) 1.0 release candidate that is API and ABI
69
pipewire-1.0.0.tar.gz/meson.build -> pipewire-1.0.1.tar.bz2/meson.build
Changed
8
1
2
project('pipewire', 'c' ,
3
- version : '1.0.0',
4
+ version : '1.0.1',
5
license : 'MIT', 'LGPL-2.1-or-later', 'GPL-2.0-only' ,
6
meson_version : '>= 0.61.1',
7
default_options : 'warning_level=3',
8
pipewire-1.0.0.tar.gz/meson_options.txt -> pipewire-1.0.1.tar.bz2/meson_options.txt
Changed
37
1
2
option('jack-devel',
3
description: 'Install jack development files',
4
type: 'boolean',
5
- value: 'false')
6
+ value: false)
7
option('libjack-path',
8
description: 'Where to install the libjack.so library',
9
type: 'string')
10
11
option('legacy-rtkit',
12
description: 'Build legacy rtkit module',
13
type: 'boolean',
14
- value: 'true')
15
+ value: true)
16
option('avb',
17
description: 'Enable AVB code',
18
type: 'feature',
19
20
option('pam-defaults-install',
21
description: 'Install limits.d file modifying defaults for all PAM users. Only for old kernels/systemd!',
22
type: 'boolean',
23
- value: 'false')
24
+ value: false)
25
option('pam-memlock-default',
26
description : 'The default memlock value for any PAM user in kilobytes. Multiples of 64 recommended.',
27
type : 'integer',
28
29
option('rlimits-install',
30
description: 'Install PAM limits.d file. Voids all following rlimits-* options, if false',
31
type: 'boolean',
32
- value: 'true')
33
+ value: true)
34
option('rlimits-match',
35
description : 'PAM match rule for the generated limits.d file. @<name> denotes matching a group.',
36
type : 'string',
37
pipewire-1.0.0.tar.gz/pipewire-jack/src/pipewire-jack.c -> pipewire-1.0.1.tar.bz2/pipewire-jack/src/pipewire-jack.c
Changed
88
1
2
id, seq, res, spa_strerror(res), message);
3
4
if (id == PW_ID_CORE) {
5
+ /* This happens when we did something on a proxy that
6
+ * was destroyed on the server already */
7
+ if (res == -ENOENT)
8
+ return;
9
+
10
client->last_res = res;
11
if (res == -EPIPE && !client->destroyed) {
12
queue_notify(client, NOTIFY_TYPE_SHUTDOWN,
13
14
exit_unlock:
15
pw_thread_loop_unlock(client->context.loop);
16
exit:
17
+ pw_log_info("%p: error %d", client, *status);
18
jack_client_close((jack_client_t *) client);
19
return NULL;
20
disabled:
21
22
{
23
struct client *c = (struct client *) client;
24
struct frame_times times;
25
- uint64_t diff;
26
+ int64_t diff;
27
28
return_val_if_fail(c != NULL, 0);
29
30
31
32
get_frame_times(c, ×);
33
34
+ if (times.sample_rate == 0 || times.rate_diff == 0.0)
35
+ return -1;
36
+
37
*current_frames = times.frames;
38
- *current_usecs = times.nsec / SPA_NSEC_PER_USEC;
39
*next_usecs = times.next_nsec / SPA_NSEC_PER_USEC;
40
- if (times.sample_rate == 0 || times.rate_diff == 0.0)
41
- *period_usecs = (times.next_nsec - times.nsec) / SPA_NSEC_PER_USEC;
42
- else
43
- *period_usecs = times.buffer_frames *
44
+ *period_usecs = times.buffer_frames *
45
(float)SPA_USEC_PER_SEC / (times.sample_rate * times.rate_diff);
46
+ *current_usecs = *next_usecs - (jack_time_t)*period_usecs;
47
48
pw_log_trace("%p: %d %"PRIu64" %"PRIu64" %f", c, *current_frames,
49
*current_usecs, *next_usecs, *period_usecs);
50
51
52
get_frame_times(c, ×);
53
54
- if (times.buffer_frames == 0)
55
+ if (times.buffer_frames == 0 || times.sample_rate == 0 || times.rate_diff == 0.0)
56
return 0;
57
58
uint32_t nf = (uint32_t)times.frames;
59
- uint64_t w = times.nsec/SPA_NSEC_PER_USEC;
60
uint64_t nw = times.next_nsec/SPA_NSEC_PER_USEC;
61
+ uint64_t dp = (uint64_t)(times.buffer_frames *
62
+ (float)SPA_USEC_PER_SEC / (times.sample_rate * times.rate_diff));
63
+ uint64_t w = nw - dp;
64
int32_t df = frames - nf;
65
- int64_t dp = nw - w;
66
return w + (int64_t)rint((double) df * (double) dp / times.buffer_frames);
67
}
68
69
70
71
get_frame_times(c, ×);
72
73
- if (times.buffer_frames == 0)
74
+ if (times.sample_rate == 0 || times.rate_diff == 0.0)
75
return 0;
76
77
uint32_t nf = (uint32_t)times.frames;
78
- uint64_t w = times.nsec/SPA_NSEC_PER_USEC;
79
uint64_t nw = times.next_nsec/SPA_NSEC_PER_USEC;
80
+ uint64_t dp = (uint64_t)(times.buffer_frames *
81
+ (float)SPA_USEC_PER_SEC / (times.sample_rate * times.rate_diff));
82
+ uint64_t w = nw - dp;
83
int64_t du = usecs - w;
84
- int64_t dp = nw - w;
85
return nf + (int32_t)rint((double)du / (double)dp * times.buffer_frames);
86
}
87
88
pipewire-1.0.0.tar.gz/spa/examples/meson.build -> pipewire-1.0.1.tar.bz2/spa/examples/meson.build
Changed
12
1
2
'local-v4l2',
3
4
5
+if not get_option('examples').allowed()
6
+ subdir_done()
7
+endif
8
+
9
spa_examples_extra_deps = {
10
'local-v4l2': sdl_dep,
11
'local-libcamera': sdl_dep, libcamera_dep,
12
pipewire-1.0.0.tar.gz/spa/include/spa/param/video/multiview.h -> pipewire-1.0.1.tar.bz2/spa/include/spa/param/video/multiview.h
Changed
27
1
2
* sequence. This method only applies to
3
* raw video buffers at the moment.
4
* Specific view identification is via
5
- * \ref spa_video_multiview_meta on raw
6
- * video buffers. */
7
+ * metadata on raw video buffers. */
8
SPA_VIDEO_MULTIVIEW_MODE_SEPARATED, /**< Multiple views are provided as separate
9
* \ref spa_data framebuffers attached
10
* to each \ref spa_buffer, described
11
- * by the \ref spa_video_multiview_meta */
12
+ * by the metadata */
13
/* future expansion for annotated modes */
14
};
15
16
17
SPA_VIDEO_MULTIVIEW_FLAGS_MIXED_MONO = (1 << 15), /**< The video stream contains both
18
* mono and multiview portions,
19
* signalled on each buffer by the
20
- * absence or presence of the
21
- * \ref SPA_VIDEO_BUFFER_FLAG_MULTIPLE_VIEW
22
- * buffer flag. */
23
+ * absence or presence of a buffer flag. */
24
};
25
26
27
pipewire-1.0.0.tar.gz/spa/meson.build -> pipewire-1.0.1.tar.bz2/spa/meson.build
Changed
9
1
2
3
subdir('tools')
4
subdir('tests')
5
-if get_option('examples').allowed()
6
- subdir('examples')
7
-endif
8
+subdir('examples')
9
pipewire-1.0.0.tar.gz/spa/plugins/alsa/acp/acp.c -> pipewire-1.0.1.tar.bz2/spa/plugins/alsa/acp/acp.c
Changed
11
1
2
{
3
pa_cvolume r;
4
5
- dev->real_volume = *v;
6
+ if (v != &dev->real_volume)
7
+ dev->real_volume = *v;
8
9
if (!dev->mixer_handle)
10
return;
11
pipewire-1.0.0.tar.gz/spa/plugins/alsa/alsa-pcm.c -> pipewire-1.0.1.tar.bz2/spa/plugins/alsa/alsa-pcm.c
Changed
108
1
2
3
while (spa_json_get_string(&it1, v, sizeof(v)) > 0 &&
4
i < SPA_N_ELEMENTS(state->bound_ctls)) {
5
- strncpy(state->bound_ctlsi.name, v, sizeof(state->bound_ctlsi.name));
6
+ snprintf(state->bound_ctlsi.name,
7
+ sizeof(state->bound_ctlsi.name), "%s", v);
8
i++;
9
}
10
state->num_bind_ctls = i;
11
12
if (opened) {
13
snd_ctl_close(state->ctl);
14
state->ctl = NULL;
15
- goto error;
16
}
17
+
18
+ goto error;
19
}
20
21
snd_ctl_elem_value_set_integer(state->pitch_elem, 0, 1000000);
22
23
} else {
24
CHECK(snd_pcm_hw_params_get_buffer_size_max(params, &state->buffer_frames), "get_buffer_size_max");
25
26
- state->buffer_frames = SPA_MIN(state->buffer_frames, state->quantum_limit * 4)* state->frame_scale;
27
+ state->buffer_frames = SPA_MIN(state->buffer_frames, state->quantum_limit * 4 * state->frame_scale);
28
29
CHECK(snd_pcm_hw_params_set_buffer_size_min(hndl, params, &state->buffer_frames), "set_buffer_size_min");
30
CHECK(snd_pcm_hw_params_set_buffer_size_near(hndl, params, &state->buffer_frames), "set_buffer_size_near");
31
32
/* start the transfer */
33
CHECK(snd_pcm_sw_params_set_start_threshold(hndl, params, LONG_MAX), "set_start_threshold");
34
35
- CHECK(snd_pcm_sw_params_set_period_event(hndl, params, state->disable_tsched), "set_period_event");
36
-
37
if (state->disable_tsched) {
38
snd_pcm_uframes_t avail_min;
39
40
41
return 0;
42
}
43
44
-
45
-static uint64_t get_time_ns(struct state *state)
46
-{
47
- struct timespec now;
48
- if (spa_system_clock_gettime(state->data_system, CLOCK_MONOTONIC, &now) < 0)
49
- return 0;
50
- return SPA_TIMESPEC_TO_NSEC(&now);
51
-}
52
-
53
static int update_time(struct state *state, uint64_t current_time, snd_pcm_sframes_t delay,
54
snd_pcm_sframes_t target, bool follower)
55
{
56
57
int32_t diff;
58
59
if (state->disable_tsched && !follower) {
60
- uint64_t now = get_time_ns(state);
61
-
62
- if (SPA_UNLIKELY(state->dll.bw == 0.0)) {
63
- current_time = now;
64
- err = 0.0;
65
- } else {
66
- err = (int64_t)(now - current_time);
67
- err = err / 1e9 * state->rate;
68
- }
69
+ err = (int64_t)(current_time - state->next_time);
70
+ err = err / 1e9 * state->rate;
71
} else {
72
if (state->stream == SND_PCM_STREAM_PLAYBACK)
73
err = delay - target;
74
75
return 0;
76
}
77
78
+static uint64_t get_time_ns(struct state *state)
79
+{
80
+ struct timespec now;
81
+ if (spa_system_clock_gettime(state->data_system, CLOCK_MONOTONIC, &now) < 0)
82
+ return 0;
83
+ return SPA_TIMESPEC_TO_NSEC(&now);
84
+}
85
+
86
static void alsa_wakeup_event(struct spa_source *source)
87
{
88
struct state *state = source->data, *follower;
89
90
int err;
91
unsigned short revents;
92
93
+ current_time = get_time_ns(state);
94
+
95
for (int i = 0; i < state->n_fds; i++) {
96
state->pfdsi.revents = state->sourcei.rmask;
97
/* Reset so that we only handle all our sources' events once */
98
99
return;
100
}
101
}
102
+ current_time = state->next_time;
103
}
104
- current_time = state->next_time;
105
106
/* first do all the sync */
107
if (state->stream == SND_PCM_STREAM_CAPTURE)
108
pipewire-1.0.0.tar.gz/spa/plugins/alsa/alsa-seq-bridge.c -> pipewire-1.0.1.tar.bz2/spa/plugins/alsa/alsa-seq-bridge.c
Changed
10
1
2
{
3
struct seq_state *this = object;
4
struct seq_port *port;
5
- int res;
6
+ int res = 0;
7
8
spa_return_val_if_fail(this != NULL, -EINVAL);
9
10
pipewire-1.0.0.tar.gz/spa/plugins/alsa/alsa-seq.c -> pipewire-1.0.1.tar.bz2/spa/plugins/alsa/alsa-seq.c
Changed
108
1
2
const snd_seq_real_time_t* queue_time;
3
uint64_t queue_real;
4
double err, corr;
5
- uint64_t queue_elapsed;
6
-
7
- corr = 1.0 - (state->dll.z2 + state->dll.z3);
8
+ uint64_t q1, q2;
9
10
/* take queue time */
11
snd_seq_queue_status_alloca(&status);
12
13
queue_time = snd_seq_queue_status_get_real_time(status);
14
queue_real = SPA_TIMESPEC_TO_NSEC(queue_time);
15
16
- if (state->queue_time == 0)
17
- queue_elapsed = 0;
18
- else
19
- queue_elapsed = (queue_real - state->queue_time) / corr;
20
-
21
- state->queue_time = queue_real;
22
-
23
- queue_elapsed = NSEC_TO_CLOCK(&state->rate, queue_elapsed);
24
-
25
- err = ((int64_t)state->threshold - (int64_t) queue_elapsed);
26
- err = SPA_CLAMP(err, -64, 64);
27
-
28
if (state->dll.bw == 0.0) {
29
spa_dll_set_bw(&state->dll, SPA_DLL_BW_MAX, state->threshold,
30
state->rate.denom);
31
state->next_time = nsec;
32
state->base_time = nsec;
33
+ state->queue_next = queue_real;
34
}
35
+
36
+ /* track our estimated elapsed time against the real elapsed queue time */
37
+ q1 = NSEC_TO_CLOCK(&state->rate, state->queue_next);
38
+ q2 = NSEC_TO_CLOCK(&state->rate, queue_real);
39
+ err = ((int64_t)q1 - (int64_t) q2);
40
+
41
+ if (fabs(err) > state->threshold)
42
+ spa_dll_init(&state->dll);
43
+
44
+ err = SPA_CLAMP(err, -64, 64);
45
corr = spa_dll_update(&state->dll, err);
46
47
+ /* this is our current estimated queue time and rate */
48
+ state->queue_time = state->queue_next;
49
+ state->queue_corr = corr;
50
+
51
+ /* make a new estimated queue time with the current quantum, if we are following,
52
+ * use the rate correction, else we will use the rate correction only for the new
53
+ * timeout. */
54
+ if (state->following)
55
+ state->queue_next += state->threshold * corr * 1e9 / state->rate.denom;
56
+ else
57
+ state->queue_next += state->threshold * 1e9 / state->rate.denom;
58
+
59
if ((state->next_time - state->base_time) > BW_PERIOD) {
60
state->base_time = state->next_time;
61
spa_log_debug(state->log, "%p: follower:%d rate:%f bw:%f err:%f (%f %f %f)",
62
state, follower, corr, state->dll.bw, err,
63
state->dll.z1, state->dll.z2, state->dll.z3);
64
}
65
-
66
state->next_time += state->threshold / corr * 1e9 / state->rate.denom;
67
68
if (!follower && state->clock) {
69
70
int res;
71
72
if ((res = spa_system_clock_gettime(state->data_system, CLOCK_MONOTONIC, &now)) < 0)
73
- return res;
74
+ return res;
75
76
+ state->queue_time = 0;
77
+ state->queue_corr = 1.0;
78
+ spa_dll_init(&state->dll);
79
state->next_time = SPA_TIMESPEC_TO_NSEC(&now);
80
if (state->following) {
81
set_timeout(state, 0);
82
83
state->source.rmask = 0;
84
spa_loop_add_source(state->data_loop, &state->source);
85
86
- state->queue_time = 0;
87
- spa_dll_init(&state->dll);
88
- set_timers(state);
89
+ res = set_timers(state);
90
91
- return 0;
92
+ return res;
93
}
94
95
static int do_reassign_follower(struct spa_loop *loop,
96
97
void *user_data)
98
{
99
struct seq_state *state = user_data;
100
- set_timers(state);
101
+ int res;
102
+
103
+ if ((res = set_timers(state)) < 0)
104
+ spa_log_error(state->log, "can't set timers: %s", spa_strerror(res));
105
return 0;
106
}
107
108
pipewire-1.0.0.tar.gz/spa/plugins/alsa/alsa-seq.h -> pipewire-1.0.1.tar.bz2/spa/plugins/alsa/alsa-seq.h
Changed
10
1
2
uint64_t next_time;
3
uint64_t base_time;
4
uint64_t queue_time;
5
+ uint64_t queue_next;
6
+ double queue_corr;
7
8
unsigned int opened:1;
9
unsigned int started:1;
10
pipewire-1.0.0.tar.gz/spa/plugins/audioconvert/audioadapter.c -> pipewire-1.0.1.tar.bz2/spa/plugins/audioconvert/audioadapter.c
Changed
59
1
2
unsigned int add_listener:1;
3
unsigned int have_format:1;
4
unsigned int started:1;
5
- unsigned int warned:1;
6
unsigned int ready:1;
7
- unsigned int driver:1;
8
unsigned int async:1;
9
unsigned int passthrough:1;
10
unsigned int follower_removing:1;
11
unsigned int in_recalc;
12
+
13
+ unsigned int warned:1;
14
+ unsigned int driver:1;
15
};
16
17
/** \endcond */
18
19
this->warned = false;
20
break;
21
case SPA_NODE_COMMAND_Suspend:
22
- this->started = false;
23
- this->ready = false;
24
- this->warned = false;
25
spa_log_debug(this->log, "%p: suspending", this);
26
break;
27
case SPA_NODE_COMMAND_Pause:
28
- this->started = false;
29
- this->ready = false;
30
- this->warned = false;
31
spa_log_debug(this->log, "%p: pausing", this);
32
break;
33
case SPA_NODE_COMMAND_Flush:
34
35
break;
36
case SPA_NODE_COMMAND_Suspend:
37
configure_format(this, 0, NULL);
38
+ this->started = false;
39
+ this->warned = false;
40
+ this->ready = false;
41
spa_log_debug(this->log, "%p: suspended", this);
42
break;
43
case SPA_NODE_COMMAND_Pause:
44
+ this->started = false;
45
+ this->warned = false;
46
+ this->ready = false;
47
spa_log_debug(this->log, "%p: paused", this);
48
break;
49
case SPA_NODE_COMMAND_Flush:
50
51
struct impl *this = object;
52
int status = 0, fstatus, retry = 8;
53
54
- if (!this->started) {
55
+ if (!this->ready) {
56
if (!this->warned)
57
spa_log_warn(this->log, "%p: scheduling stopped node", this);
58
this->warned = true;
59
pipewire-1.0.0.tar.gz/spa/plugins/bluez5/bluez-hardware.conf -> pipewire-1.0.1.tar.bz2/spa/plugins/bluez5/bluez-hardware.conf
Changed
9
1
2
{ name = "JBL LIVE650BTNC" },
3
{ name = "Motorola DC800", no-features = sbc-xq }, # #pipewire-1590
4
{ name = "Motorola S305", no-features = sbc-xq }, # #pipewire-1590
5
+ { name = "PMK True Wireless Earbuds" no-features = sbc-xq }, # Primark earbud
6
{ name = "Soundcore Life P2-L", no-features = msbc-alt1, msbc-alt1-rtl },
7
{ name = "Soundcore Motion B", no-features = hw-volume },
8
{ name = "SoundCore mini", no-features = hw-volume }, # #pipewire-1686
9
pipewire-1.0.0.tar.gz/spa/plugins/support/node-driver.c -> pipewire-1.0.1.tar.bz2/spa/plugins/support/node-driver.c
Changed
58
1
2
#define NAME "driver"
3
4
#define DEFAULT_FREEWHEEL false
5
+#define DEFAULT_FREEWHEEL_WAIT 10
6
#define DEFAULT_CLOCK_PREFIX "clock.system"
7
#define DEFAULT_CLOCK_ID CLOCK_MONOTONIC
8
9
10
bool freewheel;
11
char clock_name64;
12
clockid_t clock_id;
13
+ uint32_t freewheel_wait;
14
};
15
16
struct impl {
17
18
props->freewheel = DEFAULT_FREEWHEEL;
19
spa_zero(props->clock_name);
20
props->clock_id = CLOCK_MONOTONIC;
21
+ props->freewheel_wait = DEFAULT_FREEWHEEL_WAIT;
22
}
23
24
static const struct clock_info {
25
26
duration = 1024;
27
rate = 48000;
28
}
29
- nsec = this->next_time;
30
+ if (this->props.freewheel)
31
+ nsec = gettime_nsec(this, this->props.clock_id);
32
+ else
33
+ nsec = this->next_time;
34
35
if (this->tracking)
36
/* we are actually following another clock */
37
38
39
this->last_time = current_time;
40
41
- if (this->tracking) {
42
+ if (this->props.freewheel) {
43
+ corr = 1.0;
44
+ this->next_time = nsec + this->props.freewheel_wait * SPA_NSEC_PER_SEC;
45
+ } else if (this->tracking) {
46
corr = spa_dll_update(&this->dll, err);
47
this->next_time = nsec + duration / corr * 1e9 / rate;
48
} else {
49
50
} else {
51
this->props.clock_id = FD_TO_CLOCKID(this->clock_fd);
52
}
53
+ } else if (spa_streq(k, "freewheel.wait")) {
54
+ this->props.freewheel_wait = atoi(s);
55
}
56
}
57
if (this->props.clock_name0 == '\0') {
58
pipewire-1.0.0.tar.gz/src/daemon/minimal.conf.in -> pipewire-1.0.1.tar.bz2/src/daemon/minimal.conf.in
Changed
10
1
2
}
3
}
4
5
- # A default dummy driver. This handles nodes marked with the "node.always-driver"
6
+ # A default dummy driver. This handles nodes marked with the "node.always-process"
7
# property when no other driver is currently active. JACK clients need this.
8
{ factory = spa-node-factory
9
args = {
10
pipewire-1.0.0.tar.gz/src/daemon/pipewire-aes67.conf.in -> pipewire-1.0.1.tar.bz2/src/daemon/pipewire-aes67.conf.in
Changed
10
1
2
node.name = PTP0-Driver
3
node.group = pipewire.ptp0
4
# This driver should only be used for network nodes marked with group
5
- priority.driver = 0
6
+ priority.driver = 100000
7
clock.name = "clock.system.ptp0"
8
#clock.id = tai
9
clock.device = "/dev/ptp0"
10
pipewire-1.0.0.tar.gz/src/daemon/pipewire.conf.in -> pipewire-1.0.1.tar.bz2/src/daemon/pipewire.conf.in
Changed
10
1
2
#{ factory = adapter args = { factory.name = audiotestsrc node.name = my-test node.description = audiotestsrc } }
3
#{ factory = spa-node-factory args = { factory.name = api.vulkan.compute.source node.name = my-compute-source } }
4
5
- # A default dummy driver. This handles nodes marked with the "node.always-driver"
6
+ # A default dummy driver. This handles nodes marked with the "node.always-process"
7
# property when no other driver is currently active. JACK clients need this.
8
{ factory = spa-node-factory
9
args = {
10
pipewire-1.0.0.tar.gz/src/examples/meson.build -> pipewire-1.0.1.tar.bz2/src/examples/meson.build
Changed
12
1
2
'local-v4l2',
3
4
5
+if not get_option('examples').allowed()
6
+ subdir_done()
7
+endif
8
+
9
examples_extra_deps = {
10
'video-src-fixate': drm_dep,
11
'video-play': sdl_dep,
12
pipewire-1.0.0.tar.gz/src/gst/gstpipewiredeviceprovider.c -> pipewire-1.0.1.tar.bz2/src/gst/gstpipewiredeviceprovider.c
Changed
91
1
2
struct pw_node_info *info;
3
GstCaps *caps;
4
GstDevice *dev;
5
+ struct spa_list ports;
6
};
7
8
struct port_data {
9
+ struct spa_list link;
10
struct node_data *node_data;
11
struct pw_port *proxy;
12
struct spa_hook proxy_listener;
13
14
15
pw_log_debug("%p", port_data);
16
17
+ if (node_data == NULL)
18
+ return;
19
+
20
if (info->change_mask & PW_PORT_CHANGE_MASK_PARAMS) {
21
for (i = 0; i < info->n_params; i++) {
22
uint32_t id = info->paramsi.id;
23
24
struct node_data *node_data = port_data->node_data;
25
GstCaps *c1;
26
27
+ if (node_data == NULL)
28
+ return;
29
+
30
c1 = gst_caps_from_format (param);
31
if (c1 && node_data->caps)
32
gst_caps_append (node_data->caps, c1);
33
34
destroy_node (void *data)
35
{
36
struct node_data *nd = data;
37
+ struct port_data *pd;
38
GstPipeWireDeviceProvider *self = nd->self;
39
GstDeviceProvider *provider = GST_DEVICE_PROVIDER (self);
40
41
pw_log_debug("destroy %p", nd);
42
43
+ spa_list_consume(pd, &nd->ports, link) {
44
+ spa_list_remove(&pd->link);
45
+ pd->node_data = NULL;
46
+ }
47
+
48
if (nd->dev != NULL) {
49
gst_device_provider_device_remove (provider, GST_DEVICE (nd->dev));
50
}
51
52
{
53
struct port_data *pd = data;
54
pw_log_debug("destroy %p", pd);
55
+ spa_list_remove(&pd->link);
56
}
57
58
static const struct pw_proxy_events proxy_port_events = {
59
60
nd->id = id;
61
if (!props || !spa_atou64(spa_dict_lookup(props, PW_KEY_OBJECT_SERIAL), &nd->serial, 0))
62
nd->serial = SPA_ID_INVALID;
63
+ spa_list_init(&nd->ports);
64
spa_list_append(&self->nodes, &nd->link);
65
pw_node_add_listener(node, &nd->node_listener, &node_events, nd);
66
pw_proxy_add_listener((struct pw_proxy*)node, &nd->proxy_listener, &proxy_node_events, nd);
67
68
pd->id = id;
69
if (!props || !spa_atou64(spa_dict_lookup(props, PW_KEY_OBJECT_SERIAL), &pd->serial, 0))
70
pd->serial = SPA_ID_INVALID;
71
+ spa_list_append(&nd->ports, &pd->link);
72
pw_port_add_listener(port, &pd->port_listener, &port_events, pd);
73
pw_proxy_add_listener((struct pw_proxy*)port, &pd->proxy_listener, &proxy_port_events, pd);
74
resync(self);
75
76
pw_thread_loop_lock (self->core->loop);
77
78
spa_list_init(&self->nodes);
79
- spa_list_init(&self->pending);
80
self->end = FALSE;
81
self->error = 0;
82
self->list_only = TRUE;
83
84
pw_thread_loop_lock (self->core->loop);
85
86
spa_list_init(&self->nodes);
87
- spa_list_init(&self->pending);
88
self->end = FALSE;
89
self->error = 0;
90
self->list_only = FALSE;
91
pipewire-1.0.0.tar.gz/src/gst/gstpipewiredeviceprovider.h -> pipewire-1.0.1.tar.bz2/src/gst/gstpipewiredeviceprovider.h
Changed
9
1
2
struct pw_registry *registry;
3
struct spa_hook registry_listener;
4
struct spa_list nodes;
5
- struct spa_list pending;
6
int seq;
7
8
int error;
9
pipewire-1.0.0.tar.gz/src/gst/gstpipewiresink.c -> pipewire-1.0.1.tar.bz2/src/gst/gstpipewiresink.c
Changed
13
1
2
if (data->header) {
3
data->header->seq = GST_BUFFER_OFFSET (buffer);
4
data->header->pts = GST_BUFFER_PTS (buffer);
5
- data->header->dts_offset = GST_BUFFER_DTS (buffer);
6
+ if (GST_BUFFER_DTS(buffer) != GST_CLOCK_TIME_NONE)
7
+ data->header->dts_offset = GST_BUFFER_DTS (buffer) - GST_BUFFER_PTS (buffer);
8
+ else
9
+ data->header->dts_offset = 0;
10
}
11
if (data->crop) {
12
GstVideoCropMeta *meta = gst_buffer_get_video_crop_meta (buffer);
13
pipewire-1.0.0.tar.gz/src/gst/gstpipewiresrc.c -> pipewire-1.0.1.tar.bz2/src/gst/gstpipewiresrc.c
Changed
33
1
2
static enum pw_stream_state
3
wait_started (GstPipeWireSrc *this)
4
{
5
- enum pw_stream_state state;
6
+ enum pw_stream_state state, prev_state = PW_STREAM_STATE_UNCONNECTED;
7
const char *error = NULL;
8
struct timespec abstime;
9
10
11
GST_DEBUG_OBJECT (this, "waiting for started signal, state now %s",
12
pw_stream_state_as_string (state));
13
14
- if (state == PW_STREAM_STATE_ERROR)
15
- break;
16
-
17
- if (this->flushing) {
18
+ if (state == PW_STREAM_STATE_ERROR ||
19
+ (state == PW_STREAM_STATE_UNCONNECTED && prev_state > PW_STREAM_STATE_UNCONNECTED) ||
20
+ this->flushing) {
21
state = PW_STREAM_STATE_ERROR;
22
break;
23
}
24
25
state = PW_STREAM_STATE_ERROR;
26
break;
27
}
28
+
29
+ prev_state = state;
30
}
31
GST_DEBUG_OBJECT (this, "got started signal: %s",
32
pw_stream_state_as_string (state));
33
pipewire-1.0.0.tar.gz/src/meson.build -> pipewire-1.0.1.tar.bz2/src/meson.build
Changed
12
1
2
subdir('daemon')
3
subdir('tools')
4
subdir('modules')
5
-if get_option('examples').allowed()
6
- subdir('examples')
7
-endif
8
+subdir('examples')
9
if get_option('tests').allowed()
10
subdir('tests')
11
endif
12
pipewire-1.0.0.tar.gz/src/modules/module-access.c -> pipewire-1.0.1.tar.bz2/src/modules/module-access.c
Changed
30
1
2
* - If `access.legacy` is enabled, the value is:
3
*
4
* - `"flatpak"`: if client is a Flatpak client
5
+ * - `"unrestricted"`: if \ref PW_KEY_CLIENT_ACCESS client property is set to `"allowed"`
6
* - Value of \ref PW_KEY_CLIENT_ACCESS client property, if set
7
* - `"unrestricted"`: otherwise
8
*
9
10
else
11
access = ACCESS_DEFAULT;
12
} else {
13
- if (sandbox_flatpak)
14
+ if (sandbox_flatpak) {
15
access = ACCESS_FLATPAK;
16
- else if ((str = pw_properties_get(props, PW_KEY_CLIENT_ACCESS)) != NULL)
17
- access = str;
18
- else
19
+ } else if ((str = pw_properties_get(props, PW_KEY_CLIENT_ACCESS)) != NULL) {
20
+ if (spa_streq(str, "allowed"))
21
+ access = ACCESS_UNRESTRICTED;
22
+ else
23
+ access = str;
24
+ } else {
25
access = ACCESS_UNRESTRICTED;
26
+ }
27
}
28
29
/* Handle resolution */
30
pipewire-1.0.0.tar.gz/src/modules/module-client-node/protocol-native.c -> pipewire-1.0.1.tar.bz2/src/modules/module-client-node/protocol-native.c
Changed
31
1
2
SPA_POD_PodObject(&event)) < 0)
3
return -EINVAL;
4
5
+ if (event == NULL)
6
+ return -EINVAL;
7
+
8
pw_proxy_notify(proxy, struct pw_client_node_events, event, 0, event);
9
return 0;
10
}
11
12
SPA_POD_PodObject(&command)) < 0)
13
return -EINVAL;
14
15
+ if (command == NULL)
16
+ return -EINVAL;
17
+
18
pw_proxy_notify(proxy, struct pw_client_node_events, command, 0, command);
19
return 0;
20
}
21
22
SPA_POD_PodObject(&event)) < 0)
23
return -EINVAL;
24
25
+ if (event == NULL)
26
+ return -EINVAL;
27
+
28
pw_resource_notify(resource, struct pw_client_node_methods, event, 0, event);
29
return 0;
30
}
31
pipewire-1.0.0.tar.gz/src/modules/module-filter-chain/builtin_plugin.c -> pipewire-1.0.1.tar.bz2/src/modules/module-filter-chain/builtin_plugin.c
Changed
31
1
2
{
3
struct convolver_impl *impl;
4
float *samples;
5
- int offset = 0, length = 0, channel = index, n_samples, len;
6
+ int offset = 0, length = 0, channel = index, n_samples = 0, len;
7
uint32_t i = 0;
8
struct spa_json it3;
9
const char *val;
10
11
samples = resample_buffer(samples, &n_samples,
12
rate, SampleRate, resample_quality);
13
}
14
- if (samples == NULL) {
15
- errno = ENOENT;
16
- return NULL;
17
- }
18
19
for (i = 0; i < MAX_RATES; i++)
20
if (filenamesi)
21
free(filenamesi);
22
23
+ if (samples == NULL) {
24
+ errno = ENOENT;
25
+ return NULL;
26
+ }
27
+
28
if (blocksize <= 0)
29
blocksize = SPA_CLAMP(n_samples, 64, 256);
30
if (tailsize <= 0)
31
pipewire-1.0.0.tar.gz/src/modules/module-loopback.c -> pipewire-1.0.1.tar.bz2/src/modules/module-loopback.c
Changed
9
1
2
3
pw_properties_free(impl->capture_props);
4
pw_properties_free(impl->playback_props);
5
+ free(impl->buffer_data);
6
free(impl);
7
}
8
9
pipewire-1.0.0.tar.gz/src/modules/module-pipe-tunnel.c -> pipewire-1.0.1.tar.bz2/src/modules/module-pipe-tunnel.c
Changed
17
1
2
3
unsigned int do_disconnect:1;
4
unsigned int driving:1;
5
- unsigned int have_sync:1;
6
unsigned int may_pause:1;
7
unsigned int paused:1;
8
9
10
float corr;
11
12
uint64_t next_time;
13
+ unsigned int have_sync:1;
14
};
15
16
static uint64_t get_time_ns(struct impl *impl)
17
pipewire-1.0.0.tar.gz/src/modules/module-protocol-native/protocol-native.c -> pipewire-1.0.1.tar.bz2/src/modules/module-protocol-native/protocol-native.c
Changed
11
1
2
SPA_POD_Pod(&command)) < 0)
3
return -EINVAL;
4
5
+ if (command == NULL)
6
+ return -EINVAL;
7
+
8
return pw_resource_notify(resource, struct pw_node_methods, send_command, 0, command);
9
}
10
11
pipewire-1.0.0.tar.gz/src/modules/module-protocol-pulse/collect.c -> pipewire-1.0.1.tar.bz2/src/modules/module-protocol-pulse/collect.c
Changed
19
1
2
{
3
struct pw_manager_param *p;
4
5
- if (card && !monitor) {
6
+ if (card) {
7
spa_list_for_each(p, &card->param_list, link) {
8
uint32_t index, dev;
9
struct spa_pod *props;
10
11
if (dev != dev_info->device)
12
continue;
13
dev_info->active_port = index;
14
- if (props) {
15
+ if (props && !monitor) {
16
volume_parse_param(props, &dev_info->volume_info, monitor);
17
dev_info->have_volume = true;
18
}
19
pipewire-1.0.0.tar.gz/src/modules/module-protocol-pulse/manager.c -> pipewire-1.0.1.tar.bz2/src/modules/module-protocol-pulse/manager.c
Changed
55
1
2
{
3
struct object *o = data;
4
uint32_t i, changed = 0;
5
+ bool enumerate = false;
6
7
pw_log_debug("object %p: id:%d change-mask:%08"PRIx64, o, o->this.id, info->change_mask);
8
9
10
default:
11
break;
12
}
13
+
14
+ enumerate = true;
15
+
16
add_param(&o->pending_list, info->paramsi.seq, id, NULL);
17
if (!(info->paramsi.flags & SPA_PARAM_INFO_READ))
18
continue;
19
20
info->paramsi.seq = res;
21
}
22
}
23
- if (changed) {
24
+ if (changed || enumerate) {
25
o->changed += changed;
26
core_sync(o->manager);
27
}
28
29
{
30
struct object *o = data;
31
uint32_t i, changed = 0;
32
+ bool enumerate = false;
33
34
pw_log_debug("object %p: id:%d change-mask:%08"PRIx64, o, o->this.id, info->change_mask);
35
36
37
default:
38
break;
39
}
40
+
41
+ enumerate = true;
42
+
43
add_param(&o->pending_list, info->paramsi.seq, id, NULL);
44
if (!(info->paramsi.flags & SPA_PARAM_INFO_READ))
45
continue;
46
47
info->paramsi.seq = res;
48
}
49
}
50
- if (changed) {
51
+ if (changed || enumerate) {
52
o->changed += changed;
53
core_sync(o->manager);
54
}
55
pipewire-1.0.0.tar.gz/src/modules/module-protocol-pulse/modules/module-zeroconf-publish.c -> pipewire-1.0.1.tar.bz2/src/modules/module-protocol-pulse/modules/module-zeroconf-publish.c
Changed
21
1
2
{
3
struct service *s;
4
struct pw_node_info *info;
5
+ struct module_zeroconf_publish_data *data = d;
6
+ struct impl *impl = data->module->impl;
7
8
if (!pw_manager_object_is_sink(o) && !pw_manager_object_is_source(o))
9
return;
10
11
if (pw_manager_object_is_network(o))
12
return;
13
14
- s = create_service(d, o);
15
+ update_object_info(data->manager, o, &impl->defs);
16
+
17
+ s = create_service(data, o);
18
if (s == NULL)
19
return;
20
21
pipewire-1.0.0.tar.gz/src/modules/module-raop-sink.c -> pipewire-1.0.1.tar.bz2/src/modules/module-raop-sink.c
Changed
28
1
2
#define RAOP_STRIDE (2*DEFAULT_CHANNELS)
3
#define RAOP_RATE 44100
4
#define RAOP_LATENCY_MS 250
5
+#define DEFAULT_LATENCY_MS 1500
6
7
#define VOLUME_MAX 0.0
8
#define VOLUME_MIN -30.0
9
10
"( raop.encryption.type=<encryption, default:none> ) " \
11
"( raop.audio.codec=PCM ) " \
12
"( raop.password=<password for auth> ) " \
13
+ "( raop.latency.ms=<min latency in ms, default:"SPA_STRINGIFY(DEFAULT_LATENCY_MS)"> ) " \
14
"( node.latency=<latency as fraction> ) " \
15
"( node.name=<name of the nodes> ) " \
16
"( node.description=<description of the nodes> ) " \
17
18
impl->mtu = impl->stride * impl->psamples;
19
impl->sync_period = impl->rate / impl->psamples;
20
21
+ if ((str = pw_properties_get(props, "raop.latency.ms")) == NULL)
22
+ str = SPA_STRINGIFY(DEFAULT_LATENCY_MS);
23
+ impl->latency = SPA_MAX(impl->latency, msec_to_samples(impl, atoi(str)));
24
+
25
if (pw_properties_get(props, PW_KEY_AUDIO_FORMAT) == NULL)
26
pw_properties_setf(props, PW_KEY_AUDIO_FORMAT, "%s", RAOP_FORMAT);
27
if (pw_properties_get(props, PW_KEY_AUDIO_RATE) == NULL)
28
pipewire-1.0.0.tar.gz/src/modules/module-rt/25-pw-rlimits.conf.in -> pipewire-1.0.1.tar.bz2/src/modules/module-rt/25-pw-rlimits.conf.in
Changed
17
1
2
# This file was installed by PipeWire project for its libpipewire-module-rt.so
3
4
-# It's believed to be acceptable to have match rules that will never be true
5
-# i.e. a group that does not exist.
6
+# It is up to the distribution/user to create the @MATCH@ group and to add the
7
+# relevant users to the group.
8
+#
9
+# PipeWire will fall back to the RTKit DBus service when the user is not able to
10
+# acquire RT priorities with rlimits.
11
+#
12
+# If the group is not automatically created, the match rule will never be true
13
+# and this file will have no effect.
14
#
15
@MATCH@ - rtprio @RTPRIO@
16
@MATCH@ - nice @NICE@
17
pipewire-1.0.0.tar.gz/src/modules/module-x11-bell.c -> pipewire-1.0.1.tar.bz2/src/modules/module-x11-bell.c
Changed
13
1
2
res = -EIO;
3
goto exit;
4
}
5
+ if ((res = ca_context_set_driver(ca, "pulse")) < 0) {
6
+ pw_log_error("canberra context set backend error: %s", ca_strerror(res));
7
+ res = -EIO;
8
+ goto exit_destroy;
9
+ }
10
if ((res = ca_context_open(ca)) < 0) {
11
pw_log_error("canberra context open error: %s", ca_strerror(res));
12
res = -EIO;
13
pipewire-1.0.0.tar.gz/src/pipewire/data-loop.c -> pipewire-1.0.1.tar.bz2/src/pipewire/data-loop.c
Changed
15
1
2
3
if ((utils = loop->thread_utils) == NULL)
4
utils = pw_thread_utils_get();
5
- thr = spa_thread_utils_create(utils, NULL, do_loop, loop);
6
+
7
+ static const struct spa_dict_item items = {
8
+ { SPA_KEY_THREAD_NAME, "pw-data-loop" },
9
+ };
10
+
11
+ thr = spa_thread_utils_create(utils, &SPA_DICT_INIT_ARRAY(items), do_loop, loop);
12
loop->thread = (pthread_t)thr;
13
if (thr == NULL) {
14
pw_log_error("%p: can't create thread: %m", loop);
15