Commit graph

15 commits

Author SHA1 Message Date
Wim Taymans
620b34cd6b null-audio-sink: only start timers when driving
Check if we are driving or following and only start the timers when we
are the driver of the graph.

Ready events from non-drivers are not really a problem because they are
ignored. They only cause unnecessary wakeups in the graph.
2021-07-01 11:33:21 +02:00
George Kiagiadakis
c633004bf3 null-sink: make the timerfd non-blocking
Fixes #1377
2021-07-01 11:37:01 +03:00
Wim Taymans
46ef88e520 spa: save the old change_mask and restore when emitting full
When we add a new listener to an object, it will emit the full state
of the object. For this it temporarily sets the change_mask to all
changes. Restore the previous state after this or else we might not
emit the right change_mask for the next listener.

Consider the case where one there are two listeners on an object.
The object emits a change and the first listener wants to enumerate the
changed params. For this is adds a new listener and then triggers the
enumeration. If we set the change_mask to 0 after adding the listener,
the second listener would get a 0 change_mask and fail to update
its state.
2021-05-27 15:21:44 +02:00
Peter Hutterer
95a84e797a treewide: replace !strcmp() with spa_streq()
This change is only done in source files for now, header files will be done
separately.
2021-05-18 22:10:27 +10:00
Peter Hutterer
7697ed0757 treewide: replace strcmp() == 0 with spa_streq()
This change is only done in source files for now, header files will be done
separately.
2021-05-18 22:10:27 +10:00
Wim Taymans
b318a9e1d3 support: add right property id 2021-04-01 10:08:47 +02:00
Wim Taymans
fc9a6d6b1e spa: spa_json_get_string does not return the length
The returned string is null terminated.
2021-03-18 18:57:26 +01:00
Wim Taymans
8e590df92f spa: improve info parsing
Make info parsing a bit easier to read by assigning the key and
value to temporary variables.
Improve the parsing of channelmap using json parser to make it
support more cases.
Add a unit test for channelmap parsing options.
2021-03-18 18:40:56 +01:00
Wim Taymans
9662bc96ab null-audio-sink: support and prefer planar F32P
It's easier to convert to and also the native format for the converter
so that it can operate in passthrough mode without any copies.
2021-02-26 21:15:14 +01:00
Wim Taymans
c6f94def08 null-sink: fix null sink scheduling
The null sink pulls in data and provides data after it got the
data in _process.

See #472 #442
2020-12-14 10:21:13 +01:00
Wim Taymans
57886c1198 spa: add audio.position support in null sink 2020-12-02 12:59:50 +01:00
Wim Taymans
4c486c7ae3 spa: remove media.class from null-audio-sink
We can use it with othe media.class values as well
2020-12-02 11:47:08 +01:00
Wim Taymans
d77c563ae8 null-audio-sink: return fixed values for rate/channels when set 2020-11-26 10:21:36 +01:00
Wim Taymans
c3138a9bac spa: make null-sink rate and channels configurable 2020-11-25 21:05:21 +01:00
Wim Taymans
e8640683bb support: add null audio sink 2020-08-20 18:00:00 +02:00