Commit graph

951 commits

Author SHA1 Message Date
Wim Taymans
f1345f91a8 spa-node: pass properties to plugin init func 2018-01-16 16:51:24 +01:00
Wim Taymans
21aad20f94 node-factory: activate elements 2018-01-16 16:50:53 +01:00
Wim Taymans
7d5f302f93 Add bluez5 plugins 2018-01-16 15:19:55 +01:00
Wim Taymans
4a57f88345 link: fix param enumeration
When we have no input parameter we always need to use NULL as the
filter for the output parameter.
2018-01-11 10:16:40 +01:00
Wim Taymans
79129f81a7 export-source: allow more formats and channels 2018-01-11 10:15:51 +01:00
Wim Taymans
f24ee7fd02 debug: print to stderr 2018-01-11 10:14:26 +01:00
Wim Taymans
690f6ca372 module: improve error reporting 2017-12-18 13:17:02 +01:00
Wim Taymans
82ea32bcdf flatpak: use support dbus connection 2017-12-18 13:16:42 +01:00
Wim Taymans
0b7c3e7407 fix spa_support_find 2017-12-18 13:14:18 +01:00
Wim Taymans
f7b6fea43d Add dbus support interface
Add an interface that can manager a dbus connection.
Make a dbus interface in the core that can create connections running
in the core main loop. Keep this as support for spa plugins.
2017-12-18 12:41:47 +01:00
Wim Taymans
4d6ac37398 Use int instead of bool as result
Prefer to use an int return from a function instead of bool because
it can contain more info about failures.
2017-12-18 11:38:30 +01:00
Wim Taymans
e5e360d5df props: improve property introspection
Make a new PropInfo parameter that allows us to iterate all
properties. Make some new fields to set labels and names for
properties. We will be able to add more things to describe the
properties this way.
Use the Props param to simply query or set properties.
We can now make int enum properties and describe all possible
values with labels, we don't need to register types anymore.
This then makes it possible to enumerate the v4l2 controls and make
them available as control params.
2017-12-15 16:30:56 +01:00
Wim Taymans
1c19342487 pod: add info property flag
Add an info property flag that should not be taken into account
when intersecting. We use this for docs and labels.
Improve builder, make it possible to make struct properties with
flags.
Add some docs to the property flags and ranges.
2017-12-15 16:25:46 +01:00
Wim Taymans
a9ece1df91 export-sink: add an example permission call 2017-12-14 18:53:05 +01:00
Wim Taymans
e42fd9301b client: warn for invalid global ids 2017-12-14 18:45:55 +01:00
Wim Taymans
d5643e8472 core: add permissions call
Add a permissions call that can be used to update the permissions
of global objects. This can be used to set specific permissions
on certain objects, hide objects and define the permissions on new
objects. The system is quite generic so that we can extend it later
with more complicated match rules or so.
2017-12-14 18:37:05 +01:00
Wim Taymans
ef800581f0 core: make pw_core_for_each_global more powerful
Make the for_each function more powerful by allowing more than just
a bool return value.
2017-12-14 18:32:02 +01:00
Wim Taymans
1f4d1d071c modules: make events structure static
They are only used locally and otherwise we might get symbol clashes.
2017-12-14 18:28:03 +01:00
Wim Taymans
3743c88a6e inspect: Improve introspection
List the factory interfaces that are provided.
The interface id of the typemap is always 0 to avoid the chicken and
the egg problem.
Check debug env variable
2017-12-14 18:24:48 +01:00
Wim Taymans
ee0c77994e monitor: fix return values 2017-12-14 18:24:27 +01:00
Wim Taymans
1ace2a5daf make systemd dependency optional
Don't recurse into the directory of systemd when it was not found.
There are still some issues because libudev is actually provided
by systemd these days and we still need that for building the v4l2 and
alsa monitors.
2017-12-14 09:30:34 +01:00
Wim Taymans
52d193b3e3 builder: fix format parsing
We completely parse the format for props, make sure we read the next
format string in the next iteration.
2017-12-06 13:37:38 +01:00
Wim Taymans
8aa12e6b62 examples: use main_loop 2017-12-04 15:17:01 +01:00
Wim Taymans
e747fb2224 port: fix mixer status
When the mixer has no input ports, return OK
Don't increment required inputs for optional ports.
2017-12-04 15:05:56 +01:00
David Svensson Fors
6503351a0d graph: don't let required number of ports become negative
Add a check against letting the required number of ports become
negative for a node. With certain timing between the main and data
thread, this can otherwise happen.

For nodes where links are unlinked and relinked, a negative number may
mean that the scheduler skips the node and doesn't call
process_output().
2017-12-04 12:15:34 +01:00
Wim Taymans
c1aa3b4625 client-node: move to per node memory
Remove the per-port memory and only use per-node memory. This will
make it possible to share memory between ports in the future.
Keep refs to memory on the buffers and free (close) the memory
when no longer used.
2017-12-01 17:24:03 +01:00
Wim Taymans
4019da39c1 remote: use mmap helpers
Use the mmap helpers to only map the data that is needed.
2017-12-01 12:42:18 +01:00
Wim Taymans
a8cbffac7f core: get page size 2017-12-01 12:41:48 +01:00
Wim Taymans
ccd19f1e49 mem: add mmap helper
Add function and structure to help with mmap and mlock
2017-12-01 12:40:32 +01:00
Wim Taymans
3a9070ee10 don't check contents of control values
The control values do not have to contain valid values when they
are set so don't try to parse them. Instead just do a simple sanity
check on the size.
Handle the case where we clear the io area, go back to the default
node properties.
2017-12-01 10:13:53 +01:00
Wim Taymans
d2516398ed audiomixer: reset input in use_buffer
When we get new buffers, reset the info that could potentially contain
info about old buffers.
2017-12-01 10:12:43 +01:00
Wim Taymans
08814bd808 data: clean up fd and data management
Do not send the offset and size in the add_mem call, just send the
fd and the flags. The area that we need to map from this to find the
meta, chunk and data are sent in a separate call. This should make
it possible to truncate the memory to a larger size to dynamically
allocate more shared memory for a client.
Remove the Id data type, it's not needed.
Don't automatically map memory in remote.c
Pass the original memory type from server to client.
Handle DmaBuf mem in video-play now that the server passed it on.
2017-12-01 09:34:53 +01:00
Wim Taymans
541553be1c control: add control objects
Add control objects for all controllable properties on ports.
Try to link compatible control properties in autolink.
Allocate shared memory for the output property memory and configure
the io area on the ports when the controls are linked.
Send the shared memfd to clients when the io area is configured.
Add port_set_io support in remote.c, mmap the control io area and
set on the port.
Add some param helpers
Add volume control to export-source update the volume before
sending each buffer.
2017-11-30 16:36:29 +01:00
Wim Taymans
91a3670610 node: make port for_each more powerful
Make an int return from pw_node_for_each_port() so that we can return
errors or early exit.
Add pw_port_for_each_param() to iterate params. And use this to collect
the formats.
2017-11-29 16:58:17 +01:00
Wim Taymans
425073afd8 param-io: work on IO parameters
Reorganize the io parameter ids and objects. Make separate enumerations
for buffer, control, input and output properties.
Add a volume output property to export-source. This is still unused
but will eventually be routed to a PropsIn io area where it can
control the volume of a mixer, for example.
2017-11-29 13:25:56 +01:00
Wim Taymans
ada3698355 pod-iter: remove broken _FOREACH_SAFE 2017-11-29 13:22:25 +01:00
Wim Taymans
140c3959ab meta: remove shared meta data
Make a method to find the memory block for the given ptr. We can
use this to find the memfd of the memory if there is any. We can
then remove the Shared metadata on buffers.
2017-11-28 18:30:29 +01:00
Wim Taymans
75cdd20207 client-node: cleanup names, remove useless proxy_prefix 2017-11-28 18:26:37 +01:00
Wim Taymans
f019d984e9 type: add param_io mappings 2017-11-28 18:26:33 +01:00
Wim Taymans
77838fd734 mem: fix for memfd_create check 2017-11-27 11:58:33 +01:00
Wim Taymans
d7c26c4b59 link: emit info_changed event
Small cleanups
2017-11-27 11:29:12 +01:00
Wim Taymans
f902a34290 build: make sure memfd_create is found 2017-11-24 18:58:22 +01:00
Wim Taymans
4516fcecc4 remove stray commit 2017-11-24 18:03:22 +01:00
Wim Taymans
2a86814bb8 Only define memfd_create when not already defined 2017-11-24 17:36:27 +01:00
Wim Taymans
bde1012c5c Back to development 2017-11-24 17:03:58 +01:00
Wim Taymans
58f086b165 Release 0.1.7 2017-11-24 17:02:04 +01:00
Wim Taymans
f623556d9b spa-node: cleanup when the module unloads 2017-11-24 17:02:04 +01:00
Wim Taymans
e2c49199f6 link: fix param enumeration
When the input port param enumeration has no result, use the NULL
filter to still enumerate the output port parameters instead of
returning nothing.
Fix the offset in the gst element.
2017-11-24 16:48:13 +01:00
Wim Taymans
263a017c4b spa: close devices after enum
Fix error reporting and close the devices after enumerating
formats.
2017-11-24 12:40:56 +01:00
Wim Taymans
f5f9acf84e pod: add sequence
A sequence is a list of timed events.
2017-11-24 12:39:39 +01:00