Commit graph

862 commits

Author SHA1 Message Date
Wim Taymans
c386eda653 volume: mark input busy while processing output 2017-10-16 18:13:11 +02:00
Wim Taymans
630dbd2c90 jack: Use latency of sink as buffer size 2017-10-16 18:12:20 +02:00
Wim Taymans
ce6b75cf63 Small cleanups 2017-10-16 18:09:59 +02:00
Wim Taymans
574c6d4b90 v4l2: only produce data when needed
We should only produce data when the io area status is NEED_BUFFER.
2017-10-16 13:23:20 +02:00
Wim Taymans
9706c191b9 client-node: don't misuse ASYNC flag
When the client is explicitly going to send reuse_buffer messages,
set the consumed buffer to INVALID so it doesn't automatically get
reused.
ASYNC is for when the node emits events to signal input and output it
has nothing to do with reuse_buffer
Remove weird PROCESS_INPUT code.
2017-10-13 18:12:06 +02:00
David Svensson Fors
28bf6137d3 Support for "client-reuse" streams
Add a PW property "pipewire.client.reuse". If set, the client-node
doesn't immediately reuse a buffer after sending
PW_CLIENT_NODE_MESSAGE_PROCESS_INPUT to the client. Instead, it waits
for reuse-buffer from the client. The SPA_GRAPH_NODE_FLAG_ASYNC is
used for this, together with adapted logic in process_input().

In stream.c, if the property is set, the handling of incoming buffers
for PW_DIRECTION_INPUT streams is changed. Each buffer has to be
recycled, so we make sure new_buffer is emitted for each intermediate
buffer, if buffer_id in the IO area has moved past some buffers.

Change-Id: I137a12b702b857cc73369930d7029ecbd69d63ff
2017-10-13 17:47:29 +02:00
David Svensson Fors
de8e0c8f8c stream: let recycle_buffer() have effect for input streams
For PW_DIRECTION_INPUT streams, set the used flag for buffers before
emitting new_buffer. This makes recycle_buffer() effective.

Change-Id: I869c2bd303e19974de79e8ada334a485c58f6592
2017-10-13 16:39:06 +02:00
David Svensson Fors
46b738282c pipewiresrc: recycle each buffer
Change-Id: Id0d415d830c6e7a27245102db6eb1068aa3c5f41
2017-10-13 16:36:16 +02:00
Wim Taymans
caca6dffd0 port: optimize tee reuse_buffer a bit 2017-10-13 16:35:31 +02:00
David Svensson Fors
ed9851ab0f port: schedule reuse-buffer
Handle reuse-buffer in output-port tee nodes and input-port mix
nodes. In both cases, reuse-buffer is forwarded to the input ports of
the tee/mix node.

Change-Id: Ifbe8bcf07f0adc6400accc64a9bfb63a5c70e215
2017-10-13 16:31:37 +02:00
Wim Taymans
d96d40e30a Add set_active method on node
Require that nodes need to be activated before they are scheduled.
Make method to activate remote node.
Add method to pause/resume stream.
2017-10-13 16:18:42 +02:00
Wim Taymans
acfdc63f26 don't include stdio 2017-09-29 13:39:26 +02:00
Wim Taymans
4fb97f78f7 Fix compilation with older SDL2 2017-09-29 13:35:37 +02:00
Wim Taymans
93bd18ccc5 fix build of test 2017-09-29 12:18:38 +02:00
Wim Taymans
d65012ff21 remove json stuff
using JSON for formats or properties is not a good idea because we can't
add more types like pointers, fd, rectangles without weird hacks. Our
PODs are more easy to parse and extend and now there is an easy way
to parse and create them as well.
2017-09-28 17:07:43 +02:00
Wim Taymans
81e5708442 move type remap to native protocol 2017-09-28 17:01:01 +02:00
Wim Taymans
24d80e5c00 Add new pod parser and builder
Add a new pod builder and parser that is less verbose and
a little more powerful.
2017-09-28 17:00:51 +02:00
Wim Taymans
3e49aec61b json tests: add properties and 2017-09-21 18:03:48 +02:00
Wim Taymans
b93ecb70fc more experiments: add json pattern matcher 2017-09-20 20:33:15 +02:00
Wim Taymans
86c8955c3a more json tests 2017-09-20 13:06:52 +02:00
Wim Taymans
ac382c052a Work on JSON based format descriptions 2017-09-20 08:03:56 +02:00
Wim Taymans
8432039ee5 meson: require jack2 to build 2017-09-19 18:19:54 +02:00
Piotr Drąg
aa2a189ac9 Update POTFILES.in 2017-09-19 17:42:12 +02:00
Wim Taymans
14dbc9c687 Makefile.in: use right build command
Use ninja instead of ninja-build, which does not seem to exist on
debian.
2017-09-19 16:04:41 +02:00
Wim Taymans
8f67aa2c38 deviceprovide: only signal when there is a loop 2017-09-19 13:16:22 +02:00
Wim Taymans
2e379d5f8f back to development 2017-09-19 12:17:36 +02:00
Wim Taymans
0d44a34b4c Release 0.1.5 2017-09-19 11:25:38 +02:00
Wim Taymans
807af5b983 man: update man pages
Add man page for pipewire-cli
2017-09-19 10:19:53 +02:00
Wim Taymans
6af4f08c6e cli: small cleanups
Add make cli to start the cli
Only print changes once
Notify of changed objects
2017-09-18 22:23:18 +02:00
Wim Taymans
3b0eec4bf8 Use PIPEWIRE_DAEMON env var to start a server
Check the PIPEWIRE_DAEMON environment variable and start a server
if it is set.
2017-09-18 21:48:02 +02:00
Wim Taymans
2f6c4544fe Small cleanups and additions 2017-09-18 21:47:44 +02:00
Wim Taymans
93a52f4837 Simplify node activation
Don't directly expose the state change methods. Only expose an activate
method for nodes that indicates if the node should be scheduled or not.
Let the link automatically negotiate two active nodes.
Make some defines for properties.
Use link property to make passive links. Passive links don't activate
the nodes.
Make sure the mainloop quits when quit is called before run.
2017-09-18 20:42:55 +02:00
Wim Taymans
304a6d1796 alsa-source: fix class 2017-09-18 19:15:09 +02:00
Wim Taymans
82129a65b9 flatpak: use new way to check for flatpak 2017-09-18 13:25:15 +02:00
Wim Taymans
f64c28c091 Cleanups
Make separate _register function so that we can first configure the
object before making it publicly visible.
2017-09-18 11:54:25 +02:00
Wim Taymans
67d4dd8656 factory: add introspection 2017-09-18 09:35:00 +02:00
Wim Taymans
7f20e04803 node_factory -> factory
Rename the node-factory to a more generic object factory.
Add type and version to create objects from a factory
Start on factory introspection
2017-09-17 16:47:03 +02:00
Wim Taymans
3c1957fd9d remote: make extra nodes for scheduler
Add an extra input and output node for remote nodes. We link this
node to all remote inputs and outputs to make it easier to use
the scheduler.
Improve scheduler debug
2017-09-16 09:20:04 +02:00
Wim Taymans
4d03224141 scheduler: fix push 2017-09-15 16:04:46 +02:00
Wim Taymans
f744b7fb1b pipewire-cli: add new tool
Add new tool to interactively interface with PipeWire instances.
2017-09-15 15:03:21 +02:00
Wim Taymans
63723cd15e core: only keep the first core resource
The resource with id 0 is always the core resource. If the client
later binds to the core again, don't override the core resource.
2017-09-15 15:02:15 +02:00
Wim Taymans
389781e3d5 core: implement create-link 2017-09-15 15:01:55 +02:00
Wim Taymans
2f9c57ec01 core: do a bind to a new node
If a create-node creates a new node, do a bind to the global of
the node to make sure the client gets the node-info.
2017-09-15 14:59:42 +02:00
Wim Taymans
d9bae8f38b introspect: add id to info again
The global is created first, with the global id in the info, it's
possible to easily link a new object to a global.
2017-09-15 14:57:43 +02:00
Wim Taymans
4bef583b75 command: clean up a little 2017-09-15 14:54:52 +02:00
Wim Taymans
d26d7a8040 flatpak: fix resource override
Make sure we chain up to the same resource that we override, for this
keep a per resource info that we pass around.
2017-09-15 14:52:17 +02:00
Wim Taymans
8a45fd4f31 remote: add user data 2017-09-15 14:51:39 +02:00
Wim Taymans
2ca25e5bf4 Small cleanups
Improve debug
Fix core info event, pass the copied info around in remote.
2017-09-15 14:47:54 +02:00
Wim Taymans
26e9daf6b7 graph: provide in and out counters
Make it possible to have input and output counters to see when a
node can be scheduled.
2017-09-15 13:37:33 +02:00
Wim Taymans
e641914c2f volume: improve negotiation and params 2017-09-15 13:29:53 +02:00