Commit graph

2154 commits

Author SHA1 Message Date
Wim Taymans
9caccb6125 pw-cli: quit when we quit 2020-07-16 12:49:17 +02:00
Wim Taymans
5afdd507c3 access: document and improve arguments
Add option to force flatpak security
When a check is inconclusive, go to the next check instead.
2020-07-16 11:45:44 +02:00
Wim Taymans
7ddc32a113 meson: place full path in the config 2020-07-16 11:44:10 +02:00
Wim Taymans
f306cbde0b command: pass right arguments to execvp
The first argument is the command (exec) and the next is the
actual command we executed.
2020-07-16 11:42:55 +02:00
Wim Taymans
02be602f97 policy-node: route to the default sink/source when found 2020-07-15 15:53:54 +02:00
Wim Taymans
61e2d5cb54 policy-node: track default sink/source and move streams
Keep track of the default source and sink and move all streams linked
to the old default to the new default when it changes.
2020-07-15 14:26:16 +02:00
Wim Taymans
b1293d9f6e policy-node: only track stream peers
Only track the peer of streams. We only care about where we linked
this stream to. There is only one target per stream but the device
we link to can have many peer streams.
2020-07-15 14:22:56 +02:00
Wim Taymans
5f2c4c70ec media-session: expose metadata 2020-07-15 14:21:35 +02:00
Wim Taymans
2d5a404244 media-session: add method to remove links 2020-07-15 14:20:46 +02:00
Wim Taymans
035fb26d71 media-session: keep track of links
Also keep track of links when not tracked in the endpoint link.
2020-07-15 14:19:25 +02:00
Wim Taymans
5194c8a92f media-session: start metadata first 2020-07-15 14:17:00 +02:00
Wim Taymans
583e450efd example: add more debug 2020-07-15 14:14:23 +02:00
Wim Taymans
77274b3ab0 node: use intermediate pending state
Use an intermediate pending state that contains the state currently
in progress and use this to decide if we need to issue start/stop
commands.

Otherwise we might be in the running state, issue a Stop command,
issue a Start command (ignored because already running), then the
Stop completes and the node is stopped.
2020-07-15 14:11:01 +02:00
Wim Taymans
6dcb19bbdf pipewiresrc: use more accurate timeout 2020-07-14 17:25:13 +02:00
Wim Taymans
a6d221f18a thread_loop: add more accurate timed_wait
Add get_time() to calculate a timespec timeout value.
Add timed_wait_full() to wait for a timespec
2020-07-14 17:13:59 +02:00
Wim Taymans
36511a5d8e gst: measure keepalive-time in milliseconds
And round up to the next integer for now.
2020-07-14 14:29:45 +02:00
Wim Taymans
0344e09905 gst: add some more debug 2020-07-14 14:15:55 +02:00
Wim Taymans
993aa89030 gst: add keepalive-time property
Add a property to periodically send the last buffer to keep the
stream alive. Useful for sparse streams that need to keep the
encoder busy every once and a while.
2020-07-14 13:54:21 +02:00
Wim Taymans
70652d1a37 gst: share the core between connections
Make all sources in the same process with the same fd share the
connection to the server. This makes it possible to set the same
fd on multiple sources/sinks and have them all use the same
connection, like when capturing multiple monitors from screencast
with the portal.

Fixes #241
2020-07-13 18:38:19 +02:00
Wim Taymans
be7ff66d0b examples: clean up proxy 2020-07-13 13:12:20 +02:00
Wim Taymans
c173b23ac4 gst: use object_path to hide providers
Don't use the core info to manage the hiden providers, that info
can't be put there anymore because the session manager manages
the devices now.
Look at the object path instead and hide those with well known
prefixes.
2020-07-13 12:31:16 +02:00
Wim Taymans
8e9bbaf3dc pipewiresrc: add option to resend last buffer on EOS
Add an option to resend the last buffer on EOS with an updated
timestamp. This can be used to make sure encoders fill up the
gap between last buffer and EOS, like with sparse streams from
screen capture.
2020-07-13 12:11:34 +02:00
Wim Taymans
a596cdbf2e gst: return NULL for unknown format 2020-07-13 11:50:06 +02:00
Wim Taymans
031a8ea799 client-node: also unref the activation memblock 2020-07-10 16:11:16 +02:00
Wim Taymans
e58fcb95d0 client-node: remove the tag from the right pool 2020-07-10 16:10:45 +02:00
Wim Taymans
5cd495c93c client-node: free old mapping only after importing the new
Keep the old mapping around until we manage to successfully import
the new mapping.
2020-07-10 12:57:55 +02:00
Wim Taymans
0430e7b8dc client-node: clean up our memory mappings
Loop over our memory mappings and clean them up when we are destroyed.
2020-07-10 12:46:48 +02:00
Wim Taymans
ff8aaf9e62 node: set node io after registering
So that we have the right node_id in the position.clock field.
2020-07-10 12:45:44 +02:00
Wim Taymans
8a0a9c8094 mem: add some more debug 2020-07-10 12:44:50 +02:00
Wim Taymans
69cfc8e08c policy-node: use the DONT_RECONNECT flag with a target
When a target is given and it doesn't exist, look at the
DONT_RECONNECT flag and error when we are not allowed to connect
to something else.
2020-07-09 13:03:02 +02:00
Julian Bouzas
f75dfde89c remote-node: process the mixer if io status have HAVE_DATA flag
Needed for audio sources created locally
2020-07-06 12:08:27 -04:00
Wim Taymans
8e6b276d51 alsa-monitor: parse device events
Parse the device events and set the Props from the ObjectConfig
as the Props param on the node.
This propagates the software volume from the device to the
node.
2020-07-06 17:26:01 +02:00
Wim Taymans
4db6e0e2b3 client-device: fix event marshall 2020-07-06 17:13:50 +02:00
Wim Taymans
0bbc25e3e2 media-session: add option to enable acp device 2020-07-06 12:51:38 +02:00
Wim Taymans
1612f5e4d2 alsa-acp: Add libacp based card device
libacp is a port and wrapper around the pulseaudio card profile code.
It uses a set of templates for construct a card profile and mixer port
settings. It also has support for UCM when available for the hardware.
2020-07-06 12:20:09 +02:00
Wim Taymans
c28ca320d1 Fix bluez node destroy
We create a ClientNode but monitor the resulting Node.
Destroy the object when removing a node.
2020-07-03 16:28:10 +02:00
Wim Taymans
471c1a071c policy: improve debug 2020-07-03 16:25:28 +02:00
Wim Taymans
a607174033 node: Pause when Suspend is not implemented 2020-07-03 16:24:55 +02:00
Wim Taymans
1e2ad41d94 remote-node: fix user_data
Pass the node_data around instead of the proxy. Get the proxy from
the node data.
Allocate user_data before the node_data so that the caller can
use the proxy user_data without overwriting the node_data.
2020-07-03 15:19:40 +02:00
Wim Taymans
21fc163c49 stream: fix some more leaks in error paths 2020-07-02 16:22:49 +02:00
Wim Taymans
f353042460 client: send an error to all bound resources
When we need to send an error to a global, send the error to
all resources bound to that global. This can also be resources
that implement the global (like client-node)
2020-07-02 15:39:23 +02:00
Wim Taymans
d3ab5bc3b8 stream: only unconnect when core unconnects
Ignore all other core errors, only make the stream unconnected
when the core is unconnected.
2020-07-02 15:39:15 +02:00
Wim Taymans
82a83afd6b policy: activate Unknown stream media type
And try to link them using the media.type property
2020-07-02 15:39:11 +02:00
Wim Taymans
9eb9fe4fbe stream: handle missing EnumFormat params
When we don't have an EnumFormat param, don't fail but fall back to
the MEDIA_TYPE property to calculate the media class.

Fixes things like:

  gst-launch-1.0 -v pipewiresrc stream-properties="props,media.type=Video" ! fakesink
2020-07-02 12:56:26 +02:00
Wim Taymans
fc49c1697a context: improve negotiation
When a port doesn't implement the EnumFormat param, use NULL as
the filter or the filter as the result.
2020-07-02 12:55:39 +02:00
Wim Taymans
591244c53e module-device: remove useless assign 2020-07-02 10:58:35 +02:00
Wim Taymans
3df8139f4e spa-node: unload handle in failure case 2020-07-02 10:57:10 +02:00
Wim Taymans
d871adbd4d spa-device: fix leak of properties in error case 2020-07-02 10:52:15 +02:00
Wim Taymans
dfd3bd84b4 buffers: increase max datas and metadata in buffers 2020-07-01 11:43:18 +02:00
Wim Taymans
f678f4371d state: always update state variables
Or else we might leak the error string.
2020-06-29 10:03:58 +02:00